Skip to content

Commit

Permalink
Merge pull request #3 from twogee/master
Browse files Browse the repository at this point in the history
Create a replacement for 0.7.2 that runs on macOS, Linux and Windows
  • Loading branch information
twogee authored Oct 19, 2016
2 parents 83a504a + e706b38 commit cc4e0e6
Show file tree
Hide file tree
Showing 159 changed files with 1,150 additions and 517 deletions.
12 changes: 6 additions & 6 deletions .classpath
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src/main"/>
<classpathentry kind="src" output="bin/launcher" path="src/launcher"/>
<classpathentry kind="src" path="etc"/>
<classpathentry kind="src" path="src/main/java"/>
<classpathentry kind="src" path="src/test/java"/>
<classpathentry kind="src" path="src/main/resources"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="src" path="/Grand"/>
<classpathentry kind="lib" path="deps/commons-logging.jar"/>
<classpathentry kind="lib" path="deps/jzgraph.jar"/>
<classpathentry kind="src" path="src/test"/>
<classpathentry kind="lib" path="deps/ant.jar"/>
<classpathentry kind="lib" path="deps/blacksun-util.jar"/>
<classpathentry kind="lib" path="deps/swt.jar"/>
Expand All @@ -16,6 +15,7 @@
<classpathentry kind="lib" path="deps/org.eclipse.draw2d_3.10.100.201606061308.jar"/>
<classpathentry kind="lib" path="deps/org.eclipse.equinox.common_3.8.0.v20160509-1230.jar"/>
<classpathentry kind="lib" path="deps/org.eclipse.jface_3.12.0.v20160518-1929.jar"/>
<classpathentry kind="lib" path="deps/org.eclipse.osgi_3.11.0.v20160603-1336.jar"/>
<classpathentry kind="output" path="bin/main"/>
<classpathentry kind="lib" path="deps/oro.jar"/>
<classpathentry kind="lib" path="deps/org.eclipse.osgi_3.11.1.v20160708-1632.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ deps/
dist/
lib/
tmp/
jnlp/*.jar
jnlp/*/
.settings/
.idea/
*.iml
Expand Down
1 change: 0 additions & 1 deletion .project
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>com.atlassw.tools.eclipse.checkstyle.CheckstyleNature</nature>
<nature>net.sf.eclipsecs.core.CheckstyleNature</nature>
</natures>
</projectDescription>
3 changes: 0 additions & 3 deletions .settings/org.eclipse.core.resources.prefs

This file was deleted.

10 changes: 10 additions & 0 deletions ChangeLog-Ui.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
$Id$
Release 0.8.1 (build number 300):

* Upgraded to Eclipse 4.6.1,
* Provide macOS bundle for Oracle Java,
* Adjusted menus and accelerators to macOS,
* Use spinner fields in preference menus,
* Stop using Ant script for launch (cf 0.7.2 distribution).


Release 0.8 (build number 296):

* Upgraded to Ant 1.9.7,
* Upgraded to Grand core 1.9,
* Upgraded to Eclipse 4.6,
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
15 changes: 9 additions & 6 deletions build.properties
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
product.version=0.8
product.version=0.8.1
grand-core.version=1.9.2

eclipse.version=4.6
eclipse.timestamp=201606061100
eclipse.version=4.6.1
eclipse.timestamp=201609071200
eclipse.core.version=3.10.2
eclipse.gef.version=4.0.0
eclipse.gef.timestamp=201606061308
eclipse.equinox.version=3.8.0
eclipse.commands.version=3.8.0
eclipse.draw2d.version=3.10.100
eclipse.jface.version=3.12.0
eclipse.osgi.version=3.11.0
eclipse.workbench.version=3.108.0
swt.version=3.105.0.v20160603-0902
eclipse.osgi.version=3.11.1
eclipse.workbench.version=3.108.1
swt.version=3.105.1.v20160907-0248
icu.version=56.1.0

# Configuration for downloads
Expand Down Expand Up @@ -51,3 +51,6 @@ url.oro.jar=http://repo1.maven.org/maven2/oro/oro/2.0.8/oro-2.0.8.jar

# Commons logging
url.commons-logging.jar=http://repo1.maven.org/maven2/commons-logging/commons-logging/1.2/commons-logging-1.2.jar

# AppBundler
url.appbundler.jar=https://java.net/downloads/appbundler/appbundler-1.0.jar
115 changes: 76 additions & 39 deletions build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,20 @@
<property name="libdir" value="lib"/>
<property name="extlibdir" value="deps"/>
<property name="dlcachedir" value="cache"/>
<property name="classdir.main" value="bin/main"/>
<property name="srcdir.main" value="src/main"/>
<property name="classdir" value="bin"/>
<property name="srcdir" value="src/main/java"/>
<property name="confdir" value="src/main/resources"/>
<property name="scriptdir" value="src/main/scripts"/>
<property name="buildnum-file" value="${confdir}/net/ggtools/grand/ui/buildnum.properties"/>
<property name="distdir" value="dist"/>
<property name="confdir" value="etc"/>
<property name="buildnum-file" value="etc/net/ggtools/grand/ui/buildnum.properties"/>
<property name="classdir.launcher" value="bin/launcher"/>
<property name="srcdir.launcher" value="src/launcher"/>
<property name="javadocdir" value="tmp/docs/api"/>
<property name="java.target" value="1.6"/>
<property name="bundle.name" value="GrandUI.app"/>
<property name="bundle.launcher.name" value="JavaAppLauncher"/>

<property name="verbose-get" value="false"/>

<macrodef name="getjar" description="Download a jar to a the extlib directory">
<macrodef name="getjar" description="Download a jar to the extlib directory">
<attribute name="dest"/>
<attribute name="url"/>
<sequential>
Expand Down Expand Up @@ -69,14 +70,14 @@

<selector id="src-dist-selector">
<or>
<filename name="src/**"/>
<filename name="etc/**"/>
<filename name="${srcdir}/**"/>
<filename name="${confdir}/**"/>
<filename name="${scriptdir}/**"/>
<filename name="README.txt"/>
<filename name="LICENSE"/>
<filename name="COPYING"/>
<filename name="LICENSE-Graphviz.txt"/>
<filename name="cpl-v10.html"/>
<filename name="scripts/**"/>
<filename name="build.xml"/>
<filename name="build.properties"/>
</or>
Expand Down Expand Up @@ -106,7 +107,7 @@
</tstamp>
<property name="copyright" value="Copyright &amp;copy; ggTools. All Rights Reserved."/>
<property name="title" value="Grand UI"/>
<javadoc use="true" private="true" destdir="${javadocdir}" author="true" version="true" sourcepath="src/main" packagenames="net.ggtools.grand.*">
<javadoc use="true" private="true" destdir="${javadocdir}" author="true" version="true" sourcepath="${srcdir}" packagenames="net.ggtools.grand.*">
<classpath>
<fileset dir="${libdir}">
<include name="*.jar"/>
Expand Down Expand Up @@ -139,13 +140,25 @@
<!-- Prepare for bin distribution -->
<delete dir="tmp"/>
<mkdir dir="tmp/${product.fullname}"/>
<!-- Java libraries -->
<copy tofile="tmp/${product.fullname}/lib/grand-ui.jar" file="${libdir}/${product.fullname}.jar"/>
<copy todir="tmp/${product.fullname}/lib">
<fileset dir="${extlibdir}" excludes="org.eclipse.swt.*.jar,swt.jar"/>
<fileset dir="${extlibdir}" excludes="org.eclipse.swt.*.jar,swt.jar,appbundler.jar"/>
</copy>
<copy todir="tmp/${product.fullname}/lib/swt">
<fileset dir="${extlibdir}" includes="org.eclipse.swt.*.jar"/>
<!-- SWT platform-specific libraries -->
<copy todir="tmp/${product.fullname}/lib/gtk/x86">
<fileset dir="${extlibdir}" includes="org.eclipse.swt.gtk.*.x86_*.jar" excludes="org.eclipse.swt.gtk.*.x86_64*.jar"/>
</copy>
<copy todir="tmp/${product.fullname}/lib/gtk/x86_64">
<fileset dir="${extlibdir}" includes="org.eclipse.swt.gtk.*.x86_64*.jar"/>
</copy>
<copy todir="tmp/${product.fullname}/lib/win32/x86">
<fileset dir="${extlibdir}" includes="org.eclipse.swt.win32.*.x86_*.jar" excludes="org.eclipse.swt.win32.*.x86_64*.jar"/>
</copy>
<copy todir="tmp/${product.fullname}/lib/win32/x86_64">
<fileset dir="${extlibdir}" includes="org.eclipse.swt.win32.*.x86_64*.jar"/>
</copy>
<!-- Licenses -->
<copy todir="tmp/${product.fullname}" flatten="true">
<fileset dir=".">
<include name="README.txt"/>
Expand All @@ -156,16 +169,47 @@
</fileset>
</copy>
<copy todir="tmp/${product.fullname}">
<fileset dir="scripts" includes="**/*"/>
<fileset dir="${scriptdir}" includes="**/*.sh"/>
<globmapper from="*.sh" to="*"/>
</copy>
<chmod perm="755">
<fileset dir="tmp/${product.fullname}">
<include name="*.jar"/>
<include name="grand-ui"/>
<fileset dir="tmp/${product.fullname}" includes="grand-ui"/>
</chmod>
<copy todir="tmp/${product.fullname}">
<fileset dir="${scriptdir}" includes="**/*.bat"/>
</copy>
<fixcrlf srcdir="tmp/${product.fullname}" includes="*.bat" eol="dos"/>

<copy todir="tmp">
<fileset dir="${scriptdir}" includes="${bundle.name}/**"/>
<filterset>
<filter token="VERSION" value="${product.version}"/>
</filterset>
</copy>
<copy todir="tmp/${bundle.name}/Contents/Resources" flatten="true">
<fileset dir=".">
<include name="README.txt"/>
<include name="LICENSE"/>
<include name="COPYING"/>
<include name="LICENSE-Graphviz.txt"/>
<include name="cpl-v10.html"/>
</fileset>
</copy>
<mkdir dir="tmp/${bundle.name}/Contents/MacOS"/>
<copy todir="tmp/${bundle.name}/Contents/MacOS">
<mappedresources>
<zipfileset src="${extlibdir}/appbundler.jar" includes="**/${bundle.launcher.name}"/>
<flattenmapper/>
</mappedresources>
</copy>
<chmod perm="755">
<fileset dir="tmp/${bundle.name}/Contents/MacOS"/>
</chmod>
<mkdir dir="tmp/${product.fullname}/GrandUI.app/Contents/MacOS"/>
<symlink link="tmp/${product.fullname}/GrandUI.app/Contents/MacOS/grand-ui" resource="../../../grand-ui"/>
<mkdir dir="tmp/${bundle.name}/Contents/Java"/>
<copy todir="tmp/${bundle.name}/Contents/Java">
<fileset dir="${extlibdir}" includes="*.jar" excludes="org.eclipse.swt.gtk.*.jar,org.eclipse.swt.win32.*.jar,swt.jar,appbundler.jar"/>
</copy>
<copy tofile="tmp/${bundle.name}/Contents/Java/grand-ui.jar" file="${libdir}/${product.fullname}.jar"/>

<tar destfile="${distdir}/${product.fullname}.tar.gz" compression="gzip">
<tarfileset dir="tmp/${product.fullname}" prefix="${product.fullname}" mode="755">
Expand All @@ -176,38 +220,31 @@
<exclude name="grand-ui"/>
<exclude name="grand-ui.jar"/>
</tarfileset>
<tarfileset dir="tmp/${bundle.name}" prefix="${bundle.name}" mode="755">
<include name="${bundle.launcher.name}"/>
</tarfileset>
<tarfileset dir="tmp/${bundle.name}" prefix="${bundle.name}">
<exclude name="${bundle.launcher.name}"/>
</tarfileset>
</tar>

<zip destfile="${distdir}/${product.fullname}.zip" basedir="tmp" includes="${product.fullname}/**"/>
<zip destfile="${distdir}/${product.fullname}.zip" basedir="tmp" includes="${product.fullname}/**, ${bundle.name}/**"/>
</target>

<target name="jars" depends="compile.java,incbuildnum" description="Create the application jar(s)">
<mkdir dir="${libdir}"/>
<jar destfile="${libdir}/${product.fullname}.jar" index="true">
<fileset dir="${classdir.main}"/>
<fileset dir="${classdir}"/>
<fileset dir="${confdir}"/>
<manifest>
<attribute name="Main-Class" value="net.ggtools.grand.ui.Application"/>
</manifest>
</jar>
<jar destfile="${libdir}/${product.fullname}-launcher.jar" index="true">
<fileset dir="${classdir.launcher}"/>
<!--fileset dir="${confdir}" /-->
<manifest>
<attribute name="Main-Class" value="net.ggtools.grand.ui.launcher.Launcher"/>
</manifest>
</jar>
</target>

<target name="compile.java" depends="init" description="Compile the java source files">
<mkdir dir="${classdir.main}"/>
<javac srcdir="${srcdir.main}" destdir="${classdir.main}" debug="true" optimize="true" includeantruntime="false" source="${java.target}" target="${java.target}">
<classpath>
<path refid="ext-libs"/>
</classpath>
</javac>
<mkdir dir="${classdir.launcher}"/>
<javac srcdir="${srcdir.launcher}" destdir="${classdir.launcher}" debug="true" optimize="true" includeantruntime="false" source="${java.target}" target="${java.target}">
<mkdir dir="${classdir}"/>
<javac srcdir="${srcdir}" destdir="${classdir}" debug="true" optimize="true" includeantruntime="false" source="${java.target}" target="${java.target}">
<classpath>
<path refid="ext-libs"/>
</classpath>
Expand Down Expand Up @@ -235,8 +272,7 @@

<target name="clean" depends="clean.dist,clean.deps" description="Remove intermediate files but not external libs">
<delete dir="${libdir}"/>
<delete dir="${classdir.main}"/>
<delete dir="${classdir.launcher}"/>
<delete dir="${classdir}"/>
</target>

<target name="clean.deps" description="Clean the dependencies directory">
Expand All @@ -261,6 +297,7 @@
<getjar dest="jzgraph.jar" url="${url.jzgraph.jar}"/>
<getjar dest="oro.jar" url="${url.oro.jar}"/>
<getjar dest="grand.jar" url="${url.grand.jar}"/>
<getjar dest="appbundler.jar" url="${url.appbundler.jar}"/>
</target>

<target name="get-rcp-zip">
Expand Down
6 changes: 0 additions & 6 deletions etc/net/ggtools/grand/ui/buildnum.properties

This file was deleted.

28 changes: 0 additions & 28 deletions scripts/GrandUI.app/Contents/Info.plist

This file was deleted.

2 changes: 0 additions & 2 deletions scripts/grand-ui.bat

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@

package net.ggtools.grand.ui.actions;

import net.ggtools.grand.ui.graph.GraphControlerProvider;

import net.ggtools.grand.ui.graph.GraphControllerProvider;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

Expand All @@ -38,7 +37,7 @@
*
* @author Christophe Labouisse
*/
public class ClearFiltersAction extends GraphControlerAction {
public class ClearFiltersAction extends GraphControllerAction {
/**
* Field log.
*/
Expand All @@ -57,14 +56,14 @@ public class ClearFiltersAction extends GraphControlerAction {
*/
@Override
public final void run() {
getGraphControler().clearFilters();
getGraphController().clearFilters();
}

/**
* Constructor for ClearFiltersAction.
* @param parent GraphControlerProvider
* @param parent GraphControllerProvider
*/
public ClearFiltersAction(final GraphControlerProvider parent) {
public ClearFiltersAction(final GraphControllerProvider parent) {
super(parent, DEFAULT_ACTION_NAME);
}

Expand Down
Loading

0 comments on commit cc4e0e6

Please sign in to comment.