Commit af622682 authored by Matija Obreza's avatar Matija Obreza

Merge branch 'eclipse-swt' into 'master'

Eclipse SWT

See merge request !27
parents 958e3be5 8a363b73
......@@ -15,9 +15,15 @@
<version>2.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.eclipse.swt</groupId>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt.cocoa.macosx.x86_64</artifactId>
<version>4.3</version>
<version>3.114.100</version>
<exclusions>
<exclusion>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt</artifactId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
......
<assembly
xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>linux-gtk-x86</id>
<formats>
<format>zip</format>
</formats>
<baseDirectory>${project.build.finalName}-i386</baseDirectory>
<files>
<file>
<source>bin/genesysmagic.sh</source>
<destName>genesysmagic.sh</destName>
<fileMode>0755</fileMode>
</file>
</files>
<dependencySets>
<dependencySet>
<outputDirectory>/lib</outputDirectory>
<useProjectArtifact>true</useProjectArtifact>
<unpack>false</unpack>
<scope>runtime</scope>
<excludes>
<exclude>org.eclipse.swt:org.eclipse.swt.win32.win32.x86:jar:4.3</exclude>
<exclude>org.eclipse.swt:org.eclipse.swt.win32.win32.x86_64:jar:4.3</exclude>
<exclude>org.eclipse.swt:org.eclipse.swt.gtk.linux.x86_64:jar:4.3</exclude>
</excludes>
</dependencySet>
</dependencySets>
</assembly>
......@@ -21,9 +21,7 @@
<unpack>false</unpack>
<scope>runtime</scope>
<excludes>
<exclude>org.eclipse.swt:org.eclipse.swt.win32.win32.x86:jar:4.3</exclude>
<exclude>org.eclipse.swt:org.eclipse.swt.win32.win32.x86_64:jar:4.3</exclude>
<exclude>org.eclipse.swt:org.eclipse.swt.gtk.linux.x86:jar:4.3</exclude>
<exclude>org.eclipse.platform:org.eclipse.swt.win32.win32.x86_64:jar:4.3</exclude>
</excludes>
</dependencySet>
</dependencySets>
......
<assembly
xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>win-x86</id>
<formats>
<format>zip</format>
</formats>
<baseDirectory>${project.build.finalName}-i386</baseDirectory>
<files>
<file>
<source>bin/Genesys Magic 32.exe</source>
<destName>Genesys Magic.exe</destName>
<fileMode>0777</fileMode>
</file>
<file>
<source>bin/Genesys Magic.ini</source>
<fileMode>0444</fileMode>
</file>
</files>
<dependencySets>
<dependencySet>
<outputDirectory>/lib</outputDirectory>
<useProjectArtifact>true</useProjectArtifact>
<unpack>false</unpack>
<scope>runtime</scope>
<excludes>
<exclude>org.eclipse.swt:org.eclipse.swt.win32.win32.x86_64:jar:4.3</exclude>
<exclude>org.eclipse.swt:org.eclipse.swt.gtk.linux.x86:jar:4.3</exclude>
<exclude>org.eclipse.swt:org.eclipse.swt.gtk.linux.x86_64:jar:4.3</exclude>
</excludes>
</dependencySet>
</dependencySets>
</assembly>
......@@ -25,9 +25,7 @@
<unpack>false</unpack>
<scope>runtime</scope>
<excludes>
<exclude>org.eclipse.swt:org.eclipse.swt.win32.win32.x86:jar:4.3</exclude>
<exclude>org.eclipse.swt:org.eclipse.swt.gtk.linux.x86:jar:4.3</exclude>
<exclude>org.eclipse.swt:org.eclipse.swt.gtk.linux.x86_64:jar:4.3</exclude>
<exclude>org.eclipse.platform:org.eclipse.swt.gtk.linux.x86_64:jar:4.3</exclude>
</excludes>
</dependencySet>
</dependencySets>
......
......@@ -13,9 +13,7 @@
<version>2.4</version>
<configuration>
<descriptors>
<descriptor>bin/assembly-win32.xml</descriptor>
<descriptor>bin/assembly-win64.xml</descriptor>
<descriptor>bin/assembly-linux-gtk32.xml</descriptor>
<descriptor>bin/assembly-linux-gtk64.xml</descriptor>
</descriptors>
<archive>
......@@ -36,15 +34,7 @@
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>thirdparty</id>
<name>3rd Party Eclipse</name>
<url>http://maven.thingml.org/thirdparty/</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>org.genesys-pgr</groupId>
......@@ -52,24 +42,26 @@
<version>2.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.eclipse.swt</groupId>
<artifactId>org.eclipse.swt.win32.win32.x86</artifactId>
<version>4.3</version>
</dependency>
<dependency>
<groupId>org.eclipse.swt</groupId>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt.win32.win32.x86_64</artifactId>
<version>4.3</version>
<version>3.114.100</version>
<exclusions>
<exclusion>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.eclipse.swt</groupId>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt.gtk.linux.x86_64</artifactId>
<version>4.3</version>
</dependency>
<dependency>
<groupId>org.eclipse.swt</groupId>
<artifactId>org.eclipse.swt.gtk.linux.x86</artifactId>
<version>4.3</version>
<version>3.114.100</version>
<exclusions>
<exclusion>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt</artifactId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
<name>Anno for Windows, Linux</name>
......
......@@ -15,13 +15,12 @@
<repositories>
<repository>
<id>my-local-repo</id>
<url>file://${basedir}/lib</url>
<id>central</id>
<url>https://repo.maven.apache.org/maven2</url>
</repository>
<repository>
<id>thingml</id>
<name>3rd Party Eclipse</name>
<url>http://maven.thingml.org/thirdparty/</url>
<id>my-local-repo</id>
<url>file://${basedir}/lib</url>
</repository>
</repositories>
......@@ -52,24 +51,6 @@
<artifactId>commons-lang3</artifactId>
<version>3.3.2</version>
</dependency>
<dependency>
<groupId>org.eclipse.swt</groupId>
<artifactId>swing2swt</artifactId>
<version>1.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.swt</groupId>
<artifactId>org.eclipse.swt.cocoa.macosx.x86_64</artifactId>
<version>4.3</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.swt.gtk.linux</groupId>
<artifactId>x86_64</artifactId>
<version>3.3.0-v3346</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>net.sf.supercsv</groupId>
<artifactId>super-csv</artifactId>
......@@ -80,53 +61,6 @@
<artifactId>commons-io</artifactId>
<version>1.3.2</version>
</dependency>
<dependency>
<groupId>org.eclipse.maven</groupId>
<artifactId>org.eclipse.core.databinding.beans</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.maven</groupId>
<artifactId>org.eclipse.core.databinding</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.maven</groupId>
<artifactId>
org.eclipse.core.databinding.observable
</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.maven</groupId>
<artifactId>org.eclipse.core.databinding.property</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.maven</groupId>
<artifactId>org.eclipse.jface.databinding</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.maven</groupId>
<artifactId>org.eclipse.equinox.common</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.maven</groupId>
<artifactId>org.eclipse.core.commands</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.maven</groupId>
<artifactId>com.ibm.icu</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.maven</groupId>
<artifactId>org.eclipse.jface</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
......@@ -172,5 +106,90 @@
<artifactId>hsqldb</artifactId>
<version>2.3.4</version>
</dependency>
<!-- Eclipse SWT -->
<dependency>
<groupId>org.eclipse.swt</groupId>
<artifactId>swing2swt</artifactId>
<version>1.0</version>
</dependency>
<!-- <dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt</artifactId>
<version>3.114.100</version>
</dependency> -->
<!-- To run on Linux: Comment out the macOS SWT dependency -->
<!-- Enable including dependencies with "Provided" scope inside the run configurations of your IDE-->
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt.cocoa.macosx.x86_64</artifactId>
<version>3.114.100</version>
<scope>provided</scope>
<exclusions>
<exclusion>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt.gtk.linux.x86_64</artifactId>
<version>3.114.100</version>
<scope>provided</scope>
<exclusions>
<exclusion>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.core.databinding</artifactId>
<version>1.9.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.core.databinding.observable</artifactId>
<version>1.9.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.core.databinding.beans</artifactId>
<version>1.6.100</version>
</dependency>
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.core.databinding.property</artifactId>
<version>1.8.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.jface.databinding</artifactId>
<version>1.11.100</version>
<exclusions>
<exclusion>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.swt</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.equinox.common</artifactId>
<version>3.12.0</version>
</dependency>
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.core.commands</artifactId>
<version>3.9.700</version>
</dependency>
<dependency>
<groupId>org.eclipse.platform</groupId>
<artifactId>org.eclipse.jface</artifactId>
<version>3.20.0</version>
</dependency>
</dependencies>
</project>
......@@ -482,7 +482,7 @@ public class AppWindow {
});
tabFolder = new CTabFolder(sashForm, SWT.NONE);
tabFolder.setBackground(SWTResourceManager.getColor(SWT.COLOR_WIDGET_NORMAL_SHADOW));
tabFolder.setBackground(SWTResourceManager.getColor(SWT.COLOR_WIDGET_BACKGROUND));
tabFolder.setSelectionBackground(Display.getCurrent().getSystemColor(SWT.COLOR_TITLE_INACTIVE_BACKGROUND_GRADIENT));
tableViewer = new TableViewer(sashForm, SWT.BORDER | SWT.FULL_SELECTION);
......
......@@ -27,7 +27,7 @@ import org.apache.log4j.Logger;
import org.eclipse.core.databinding.DataBindingContext;
import org.eclipse.core.databinding.beans.BeanProperties;
import org.eclipse.core.databinding.observable.value.IObservableValue;
import org.eclipse.jface.databinding.swt.WidgetProperties;
import org.eclipse.jface.databinding.swt.typed.WidgetProperties;
import org.eclipse.jface.viewers.TreeViewer;
import org.eclipse.swt.SWT;
import org.eclipse.swt.custom.ScrolledComposite;
......
......@@ -395,6 +395,8 @@ public class PushDialog extends Dialog {
});
tltmRadioItemDebug.setText("DEBUG");
// Set info log level
LogManager.getRootLogger().setLevel(Level.INFO);
ToolItem tltmRadioItemInfo = new ToolItem(toolBar, SWT.RADIO);
tltmRadioItemInfo.setSelection(true);
tltmRadioItemInfo.addSelectionListener(new SelectionAdapter() {
......@@ -499,7 +501,7 @@ public class PushDialog extends Dialog {
protected void doPush(final GenesysOp operation) {
OAuthSettings oauthSettings = settings.getOauthSettings();
_log.info("Starting push to " + oauthSettings.getServerUrl());
_log.warn("Starting push to " + oauthSettings.getServerUrl());
final GenesysClient genesysClient = SpringConfig.createGenesysClient(oauthSettings);
this.pushProgress.sourceRowCount = 0;
......
......@@ -107,9 +107,11 @@ public class SheetDisplay extends Composite {
private ObjectMapper mapper;
final Color listBackgroundColor = SWTResourceManager.getColor(SWT.COLOR_LIST_BACKGROUND);
final Color unmappedColumnSelectedColor = SWTResourceManager.getColor(239, 239, 210);
final Color mappedColumnUnselectedColor = SWTResourceManager.getColor(199, 213, 235);
final Color mappedColumnSelectedColor = SWTResourceManager.getColor(117, 152, 206);
final Color listForegroundColor = SWTResourceManager.getColor(SWT.COLOR_LIST_FOREGROUND);
final Color unmappedColumnSelectedColor = SWTResourceManager.getColor(100, 50, 50);
final Color mappedColumnUnselectedColor = SWTResourceManager.getColor(50, 50, 100);
final Color mappedColumnSelectedColor = SWTResourceManager.getColor(50, 100, 50);
final Color mappedSelectedForegroundColor = SWTResourceManager.getColor(SWT.COLOR_WHITE);
private static class ContentProvider implements IStructuredContentProvider {
@Override
......@@ -149,14 +151,18 @@ public class SheetDisplay extends Composite {
if (currentColumn.getRdfTerm() != null && !currentColumn.getRdfTerm().isEmpty()) {
if (currentColumn == selectedColumn) {
cell.setBackground(mappedColumnSelectedColor); // pink
cell.setForeground(mappedSelectedForegroundColor);
} else {
cell.setBackground(mappedColumnUnselectedColor); // light blue
cell.setForeground(mappedSelectedForegroundColor);
}
} else {
if (currentColumn == selectedColumn) {
cell.setBackground(unmappedColumnSelectedColor); // yellow
cell.setForeground(mappedSelectedForegroundColor);
} else {
cell.setBackground(listBackgroundColor); // default
cell.setForeground(listForegroundColor);
}
}
}
......@@ -250,6 +256,7 @@ public class SheetDisplay extends Composite {
tbtmQuery.setText("SQL Query");
Composite compositeQuery = new Composite(tabFolder, SWT.NONE);
compositeQuery.setBackground(SWTResourceManager.getColor(SWT.COLOR_WIDGET_BACKGROUND));
compositeQuery.setLayout(new GridLayout(4, false));
tbtmQuery.setControl(compositeQuery);
......@@ -293,7 +300,7 @@ public class SheetDisplay extends Composite {
tbtmColumnProperties.setText("Column");
ScrolledComposite scrolledComposite = new ScrolledComposite(tabFolder, SWT.V_SCROLL);
scrolledComposite.setBackground(SWTResourceManager.getColor(SWT.COLOR_WIDGET_LIGHT_SHADOW));
scrolledComposite.setBackground(SWTResourceManager.getColor(SWT.COLOR_WIDGET_BACKGROUND));
scrolledComposite.setExpandVertical(true);
scrolledComposite.setExpandHorizontal(true);
tbtmColumnProperties.setControl(scrolledComposite);
......@@ -421,7 +428,7 @@ public class SheetDisplay extends Composite {
tbtmSheet.setText("Headers");
Composite compoHeaders = new Composite(tabFolder, SWT.NONE);
compoHeaders.setBackground(SWTResourceManager.getColor(SWT.COLOR_WIDGET_LIGHT_SHADOW));
compoHeaders.setBackground(SWTResourceManager.getColor(SWT.COLOR_WIDGET_BACKGROUND));
tbtmSheet.setControl(compoHeaders);
compoHeaders.setLayout(new GridLayout(2, false));
new Label(compoHeaders, SWT.NONE);
......@@ -472,7 +479,7 @@ public class SheetDisplay extends Composite {
tbtmCSV.setText("CSV");
ScrolledComposite scrolledComposite2 = new ScrolledComposite(tabFolder, SWT.V_SCROLL);
scrolledComposite2.setBackground(SWTResourceManager.getColor(SWT.COLOR_WIDGET_LIGHT_SHADOW));
scrolledComposite2.setBackground(SWTResourceManager.getColor(SWT.COLOR_WIDGET_BACKGROUND));
scrolledComposite2.setExpandVertical(true);
scrolledComposite2.setExpandHorizontal(true);
tbtmCSV.setControl(scrolledComposite2);
......
......@@ -39,6 +39,7 @@ import org.eclipse.wb.swt.SWTResourceManager;
import swing2swt.layout.BorderLayout;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.graphics.Point;
public class WorkspaceDialog extends Dialog {
......@@ -102,7 +103,8 @@ public class WorkspaceDialog extends Dialog {
*/
private void createContents() {
shlWorkspaceLauncher = new Shell(getParent(), SWT.CLOSE | SWT.RESIZE | SWT.TITLE);
shlWorkspaceLauncher.setSize(650, 194);
shlWorkspaceLauncher.setMinimumSize(new Point(600, 200));
shlWorkspaceLauncher.setSize(600, 200);
shlWorkspaceLauncher.setText("Workspace Launcher");
shlWorkspaceLauncher.setLayout(new BorderLayout(0, 0));
......
......@@ -61,7 +61,7 @@
<plugin>
<inherited>true</inherited>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.6.1</version>
<version>3.8.1</version>
<configuration>
<source>${jdk.source}</source>
<target>${jdk.target}</target>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment