summary refs log tree commit diff stats
path: root/Four Puzzle Editor
diff options
context:
space:
mode:
Diffstat (limited to 'Four Puzzle Editor')
-rw-r--r--Four Puzzle Editor/build.xml69
-rw-r--r--Four Puzzle Editor/manifest.mf3
-rw-r--r--Four Puzzle Editor/nbproject/build-impl.xml629
-rw-r--r--Four Puzzle Editor/nbproject/genfiles.properties8
-rw-r--r--Four Puzzle Editor/nbproject/project.properties64
-rw-r--r--Four Puzzle Editor/nbproject/project.xml19
-rw-r--r--Four Puzzle Editor/src/META-INF/services/org.jdesktop.application.Application1
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorAboutBox.form203
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorAboutBox.java137
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorApp.java44
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorView.form168
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorView.java208
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorAboutBox.properties14
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorApp.properties11
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorView.properties32
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/about.pngbin0 -> 8187 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon0.pngbin0 -> 3588 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon1.pngbin0 -> 3585 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon10.pngbin0 -> 3568 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon11.pngbin0 -> 3581 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon12.pngbin0 -> 3589 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon13.pngbin0 -> 3586 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon14.pngbin0 -> 3586 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon2.pngbin0 -> 3585 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon3.pngbin0 -> 3572 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon4.pngbin0 -> 3576 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon5.pngbin0 -> 3580 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon6.pngbin0 -> 3581 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon7.pngbin0 -> 3598 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon8.pngbin0 -> 3594 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon9.pngbin0 -> 3581 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/idle-icon.pngbin0 -> 3360 bytes
-rw-r--r--Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/splash.pngbin0 -> 21747 bytes
33 files changed, 1610 insertions, 0 deletions
diff --git a/Four Puzzle Editor/build.xml b/Four Puzzle Editor/build.xml new file mode 100644 index 0000000..e6a0d30 --- /dev/null +++ b/Four Puzzle Editor/build.xml
@@ -0,0 +1,69 @@
1<?xml version="1.0" encoding="UTF-8"?>
2<!-- You may freely edit this file. See commented blocks below for -->
3<!-- some examples of how to customize the build. -->
4<!-- (If you delete it and reopen the project it will be recreated.) -->
5<project name="Four_Puzzle_Editor" default="default" basedir=".">
6 <description>Builds, tests, and runs the project Four Puzzle Editor.</description>
7 <import file="nbproject/build-impl.xml"/>
8 <!--
9
10 There exist several targets which are by default empty and which can be
11 used for execution of your tasks. These targets are usually executed
12 before and after some main targets. They are:
13
14 -pre-init: called before initialization of project properties
15 -post-init: called after initialization of project properties
16 -pre-compile: called before javac compilation
17 -post-compile: called after javac compilation
18 -pre-compile-single: called before javac compilation of single file
19 -post-compile-single: called after javac compilation of single file
20 -pre-compile-test: called before javac compilation of JUnit tests
21 -post-compile-test: called after javac compilation of JUnit tests
22 -pre-compile-test-single: called before javac compilation of single JUnit test
23 -post-compile-test-single: called after javac compilation of single JUunit test
24 -pre-jar: called before JAR building
25 -post-jar: called after JAR building
26 -post-clean: called after cleaning build products
27
28 (Targets beginning with '-' are not intended to be called on their own.)
29
30 Example of inserting an obfuscator after compilation could look like this:
31
32 <target name="-post-compile">
33 <obfuscate>
34 <fileset dir="${build.classes.dir}"/>
35 </obfuscate>
36 </target>
37
38 For list of available properties check the imported
39 nbproject/build-impl.xml file.
40
41
42 Another way to customize the build is by overriding existing main targets.
43 The targets of interest are:
44
45 -init-macrodef-javac: defines macro for javac compilation
46 -init-macrodef-junit: defines macro for junit execution
47 -init-macrodef-debug: defines macro for class debugging
48 -init-macrodef-java: defines macro for class execution
49 -do-jar-with-manifest: JAR building (if you are using a manifest)
50 -do-jar-without-manifest: JAR building (if you are not using a manifest)
51 run: execution of project
52 -javadoc-build: Javadoc generation
53 test-report: JUnit report generation
54
55 An example of overriding the target for project execution could look like this:
56
57 <target name="run" depends="Four_Puzzle_Editor-impl.jar">
58 <exec dir="bin" executable="launcher.exe">
59 <arg file="${dist.jar}"/>
60 </exec>
61 </target>
62
63 Notice that the overridden target depends on the jar target and not only on
64 the compile target as the regular run target does. Again, for a list of available
65 properties which you can use, check the target you are overriding in the
66 nbproject/build-impl.xml file.
67
68 -->
69</project>
diff --git a/Four Puzzle Editor/manifest.mf b/Four Puzzle Editor/manifest.mf new file mode 100644 index 0000000..328e8e5 --- /dev/null +++ b/Four Puzzle Editor/manifest.mf
@@ -0,0 +1,3 @@
1Manifest-Version: 1.0
2X-COMMENT: Main-Class will be added automatically by build
3
diff --git a/Four Puzzle Editor/nbproject/build-impl.xml b/Four Puzzle Editor/nbproject/build-impl.xml new file mode 100644 index 0000000..1de50c6 --- /dev/null +++ b/Four Puzzle Editor/nbproject/build-impl.xml
@@ -0,0 +1,629 @@
1<?xml version="1.0" encoding="UTF-8"?>
2<!--
3*** GENERATED FROM project.xml - DO NOT EDIT ***
4*** EDIT ../build.xml INSTEAD ***
5
6For the purpose of easier reading the script
7is divided into following sections:
8
9 - initialization
10 - compilation
11 - jar
12 - execution
13 - debugging
14 - javadoc
15 - junit compilation
16 - junit execution
17 - junit debugging
18 - applet
19 - cleanup
20
21 -->
22<project xmlns:j2seproject1="http://www.netbeans.org/ns/j2se-project/1" xmlns:j2seproject3="http://www.netbeans.org/ns/j2se-project/3" xmlns:jaxrpc="http://www.netbeans.org/ns/j2se-project/jax-rpc" basedir=".." default="default" name="Four_Puzzle_Editor-impl">
23 <target depends="test,jar,javadoc" description="Build and test whole project." name="default"/>
24 <!--
25 ======================
26 INITIALIZATION SECTION
27 ======================
28 -->
29 <target name="-pre-init">
30 <!-- Empty placeholder for easier customization. -->
31 <!-- You can override this target in the ../build.xml file. -->
32 </target>
33 <target depends="-pre-init" name="-init-private">
34 <property file="nbproject/private/config.properties"/>
35 <property file="nbproject/private/configs/${config}.properties"/>
36 <property file="nbproject/private/private.properties"/>
37 </target>
38 <target depends="-pre-init,-init-private" name="-init-user">
39 <property file="${user.properties.file}"/>
40 <!-- The two properties below are usually overridden -->
41 <!-- by the active platform. Just a fallback. -->
42 <property name="default.javac.source" value="1.4"/>
43 <property name="default.javac.target" value="1.4"/>
44 </target>
45 <target depends="-pre-init,-init-private,-init-user" name="-init-project">
46 <property file="nbproject/configs/${config}.properties"/>
47 <property file="nbproject/project.properties"/>
48 </target>
49 <target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init">
50 <available file="${manifest.file}" property="manifest.available"/>
51 <condition property="manifest.available+main.class">
52 <and>
53 <isset property="manifest.available"/>
54 <isset property="main.class"/>
55 <not>
56 <equals arg1="${main.class}" arg2="" trim="true"/>
57 </not>
58 </and>
59 </condition>
60 <condition property="manifest.available+main.class+mkdist.available">
61 <and>
62 <istrue value="${manifest.available+main.class}"/>
63 <isset property="libs.CopyLibs.classpath"/>
64 </and>
65 </condition>
66 <condition property="have.tests">
67 <or>
68 <available file="${test.src.dir}"/>
69 </or>
70 </condition>
71 <condition property="have.sources">
72 <or>
73 <available file="${src.dir}"/>
74 </or>
75 </condition>
76 <condition property="netbeans.home+have.tests">
77 <and>
78 <isset property="netbeans.home"/>
79 <isset property="have.tests"/>
80 </and>
81 </condition>
82 <condition property="no.javadoc.preview">
83 <and>
84 <isset property="javadoc.preview"/>
85 <isfalse value="${javadoc.preview}"/>
86 </and>
87 </condition>
88 <property name="run.jvmargs" value=""/>
89 <property name="javac.compilerargs" value=""/>
90 <property name="work.dir" value="${basedir}"/>
91 <condition property="no.deps">
92 <and>
93 <istrue value="${no.dependencies}"/>
94 </and>
95 </condition>
96 <property name="javac.debug" value="true"/>
97 <property name="javadoc.preview" value="true"/>
98 <property name="application.args" value=""/>
99 <property name="source.encoding" value="${file.encoding}"/>
100 <condition property="javadoc.encoding.used" value="${javadoc.encoding}">
101 <and>
102 <isset property="javadoc.encoding"/>
103 <not>
104 <equals arg1="${javadoc.encoding}" arg2=""/>
105 </not>
106 </and>
107 </condition>
108 <property name="javadoc.encoding.used" value="${source.encoding}"/>
109 <property name="includes" value="**"/>
110 <property name="excludes" value=""/>
111 <property name="do.depend" value="false"/>
112 <condition property="do.depend.true">
113 <istrue value="${do.depend}"/>
114 </condition>
115 <condition else="" property="javac.compilerargs.jaxws" value="-Djava.endorsed.dirs='${jaxws.endorsed.dir}'">
116 <and>
117 <isset property="jaxws.endorsed.dir"/>
118 <available file="nbproject/jaxws-build.xml"/>
119 </and>
120 </condition>
121 </target>
122 <target name="-post-init">
123 <!-- Empty placeholder for easier customization. -->
124 <!-- You can override this target in the ../build.xml file. -->
125 </target>
126 <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check">
127 <fail unless="src.dir">Must set src.dir</fail>
128 <fail unless="test.src.dir">Must set test.src.dir</fail>
129 <fail unless="build.dir">Must set build.dir</fail>
130 <fail unless="dist.dir">Must set dist.dir</fail>
131 <fail unless="build.classes.dir">Must set build.classes.dir</fail>
132 <fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail>
133 <fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail>
134 <fail unless="build.test.results.dir">Must set build.test.results.dir</fail>
135 <fail unless="build.classes.excludes">Must set build.classes.excludes</fail>
136 <fail unless="dist.jar">Must set dist.jar</fail>
137 </target>
138 <target name="-init-macrodef-property">
139 <macrodef name="property" uri="http://www.netbeans.org/ns/j2se-project/1">
140 <attribute name="name"/>
141 <attribute name="value"/>
142 <sequential>
143 <property name="@{name}" value="${@{value}}"/>
144 </sequential>
145 </macrodef>
146 </target>
147 <target name="-init-macrodef-javac">
148 <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
149 <attribute default="${src.dir}" name="srcdir"/>
150 <attribute default="${build.classes.dir}" name="destdir"/>
151 <attribute default="${javac.classpath}" name="classpath"/>
152 <attribute default="${includes}" name="includes"/>
153 <attribute default="${excludes}" name="excludes"/>
154 <attribute default="${javac.debug}" name="debug"/>
155 <attribute default="" name="sourcepath"/>
156 <element name="customize" optional="true"/>
157 <sequential>
158 <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}">
159 <classpath>
160 <path path="@{classpath}"/>
161 </classpath>
162 <compilerarg line="${javac.compilerargs} ${javac.compilerargs.jaxws}"/>
163 <customize/>
164 </javac>
165 </sequential>
166 </macrodef>
167 <macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3">
168 <attribute default="${src.dir}" name="srcdir"/>
169 <attribute default="${build.classes.dir}" name="destdir"/>
170 <attribute default="${javac.classpath}" name="classpath"/>
171 <sequential>
172 <depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}">
173 <classpath>
174 <path path="@{classpath}"/>
175 </classpath>
176 </depend>
177 </sequential>
178 </macrodef>
179 <macrodef name="force-recompile" uri="http://www.netbeans.org/ns/j2se-project/3">
180 <attribute default="${build.classes.dir}" name="destdir"/>
181 <sequential>
182 <fail unless="javac.includes">Must set javac.includes</fail>
183 <pathconvert pathsep="," property="javac.includes.binary">
184 <path>
185 <filelist dir="@{destdir}" files="${javac.includes}"/>
186 </path>
187 <globmapper from="*.java" to="*.class"/>
188 </pathconvert>
189 <delete>
190 <files includes="${javac.includes.binary}"/>
191 </delete>
192 </sequential>
193 </macrodef>
194 </target>
195 <target name="-init-macrodef-junit">
196 <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
197 <attribute default="${includes}" name="includes"/>
198 <attribute default="${excludes}" name="excludes"/>
199 <attribute default="**" name="testincludes"/>
200 <sequential>
201 <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true">
202 <batchtest todir="${build.test.results.dir}">
203 <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
204 <filename name="@{testincludes}"/>
205 </fileset>
206 </batchtest>
207 <classpath>
208 <path path="${run.test.classpath}"/>
209 </classpath>
210 <syspropertyset>
211 <propertyref prefix="test-sys-prop."/>
212 <mapper from="test-sys-prop.*" to="*" type="glob"/>
213 </syspropertyset>
214 <formatter type="brief" usefile="false"/>
215 <formatter type="xml"/>
216 <jvmarg line="${run.jvmargs}"/>
217 </junit>
218 </sequential>
219 </macrodef>
220 </target>
221 <target name="-init-macrodef-nbjpda">
222 <macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1">
223 <attribute default="${main.class}" name="name"/>
224 <attribute default="${debug.classpath}" name="classpath"/>
225 <attribute default="" name="stopclassname"/>
226 <sequential>
227 <nbjpdastart addressproperty="jpda.address" name="@{name}" stopclassname="@{stopclassname}" transport="dt_socket">
228 <classpath>
229 <path path="@{classpath}"/>
230 </classpath>
231 </nbjpdastart>
232 </sequential>
233 </macrodef>
234 <macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/j2se-project/1">
235 <attribute default="${build.classes.dir}" name="dir"/>
236 <sequential>
237 <nbjpdareload>
238 <fileset dir="@{dir}" includes="${fix.classes}">
239 <include name="${fix.includes}*.class"/>
240 </fileset>
241 </nbjpdareload>
242 </sequential>
243 </macrodef>
244 </target>
245 <target name="-init-debug-args">
246 <property name="version-output" value="java version &quot;${ant.java.version}"/>
247 <condition property="have-jdk-older-than-1.4">
248 <or>
249 <contains string="${version-output}" substring="java version &quot;1.0"/>
250 <contains string="${version-output}" substring="java version &quot;1.1"/>
251 <contains string="${version-output}" substring="java version &quot;1.2"/>
252 <contains string="${version-output}" substring="java version &quot;1.3"/>
253 </or>
254 </condition>
255 <condition else="-Xdebug" property="debug-args-line" value="-Xdebug -Xnoagent -Djava.compiler=none">
256 <istrue value="${have-jdk-older-than-1.4}"/>
257 </condition>
258 </target>
259 <target depends="-init-debug-args" name="-init-macrodef-debug">
260 <macrodef name="debug" uri="http://www.netbeans.org/ns/j2se-project/3">
261 <attribute default="${main.class}" name="classname"/>
262 <attribute default="${debug.classpath}" name="classpath"/>
263 <element name="customize" optional="true"/>
264 <sequential>
265 <java classname="@{classname}" dir="${work.dir}" fork="true">
266 <jvmarg line="${debug-args-line}"/>
267 <jvmarg value="-Xrunjdwp:transport=dt_socket,address=${jpda.address}"/>
268 <jvmarg line="${run.jvmargs}"/>
269 <classpath>
270 <path path="@{classpath}"/>
271 </classpath>
272 <syspropertyset>
273 <propertyref prefix="run-sys-prop."/>
274 <mapper from="run-sys-prop.*" to="*" type="glob"/>
275 </syspropertyset>
276 <customize/>
277 </java>
278 </sequential>
279 </macrodef>
280 </target>
281 <target name="-init-macrodef-java">
282 <macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1">
283 <attribute default="${main.class}" name="classname"/>
284 <element name="customize" optional="true"/>
285 <sequential>
286 <java classname="@{classname}" dir="${work.dir}" fork="true">
287 <jvmarg line="${run.jvmargs}"/>
288 <classpath>
289 <path path="${run.classpath}"/>
290 </classpath>
291 <syspropertyset>
292 <propertyref prefix="run-sys-prop."/>
293 <mapper from="run-sys-prop.*" to="*" type="glob"/>
294 </syspropertyset>
295 <customize/>
296 </java>
297 </sequential>
298 </macrodef>
299 </target>
300 <target name="-init-presetdef-jar">
301 <presetdef name="jar" uri="http://www.netbeans.org/ns/j2se-project/1">
302 <jar compress="${jar.compress}" jarfile="${dist.jar}">
303 <j2seproject1:fileset dir="${build.classes.dir}"/>
304 </jar>
305 </presetdef>
306 </target>
307 <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-junit,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar" name="init"/>
308 <!--
309 ===================
310 COMPILATION SECTION
311 ===================
312 -->
313 <target depends="init" name="deps-jar" unless="no.deps"/>
314 <target depends="init,deps-jar" name="-pre-pre-compile">
315 <mkdir dir="${build.classes.dir}"/>
316 </target>
317 <target name="-pre-compile">
318 <!-- Empty placeholder for easier customization. -->
319 <!-- You can override this target in the ../build.xml file. -->
320 </target>
321 <target if="do.depend.true" name="-compile-depend">
322 <j2seproject3:depend/>
323 </target>
324 <target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-compile-depend" if="have.sources" name="-do-compile">
325 <j2seproject3:javac/>
326 <copy todir="${build.classes.dir}">
327 <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
328 </copy>
329 </target>
330 <target name="-post-compile">
331 <!-- Empty placeholder for easier customization. -->
332 <!-- You can override this target in the ../build.xml file. -->
333 </target>
334 <target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/>
335 <target name="-pre-compile-single">
336 <!-- Empty placeholder for easier customization. -->
337 <!-- You can override this target in the ../build.xml file. -->
338 </target>
339 <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">
340 <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
341 <j2seproject3:force-recompile/>
342 <j2seproject3:javac excludes="" includes="${javac.includes}" sourcepath="${src.dir}"/>
343 </target>
344 <target name="-post-compile-single">
345 <!-- Empty placeholder for easier customization. -->
346 <!-- You can override this target in the ../build.xml file. -->
347 </target>
348 <target depends="init,deps-jar,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/>
349 <!--
350 ====================
351 JAR BUILDING SECTION
352 ====================
353 -->
354 <target depends="init" name="-pre-pre-jar">
355 <dirname file="${dist.jar}" property="dist.jar.dir"/>
356 <mkdir dir="${dist.jar.dir}"/>
357 </target>
358 <target name="-pre-jar">
359 <!-- Empty placeholder for easier customization. -->
360 <!-- You can override this target in the ../build.xml file. -->
361 </target>
362 <target depends="init,compile,-pre-pre-jar,-pre-jar" name="-do-jar-without-manifest" unless="manifest.available">
363 <j2seproject1:jar/>
364 </target>
365 <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available" name="-do-jar-with-manifest" unless="manifest.available+main.class">
366 <j2seproject1:jar manifest="${manifest.file}"/>
367 </target>
368 <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class" name="-do-jar-with-mainclass" unless="manifest.available+main.class+mkdist.available">
369 <j2seproject1:jar manifest="${manifest.file}">
370 <j2seproject1:manifest>
371 <j2seproject1:attribute name="Main-Class" value="${main.class}"/>
372 </j2seproject1:manifest>
373 </j2seproject1:jar>
374 <echo>To run this application from the command line without Ant, try:</echo>
375 <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
376 <property location="${dist.jar}" name="dist.jar.resolved"/>
377 <pathconvert property="run.classpath.with.dist.jar">
378 <path path="${run.classpath}"/>
379 <map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>
380 </pathconvert>
381 <echo>java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
382 </target>
383 <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class+mkdist.available" name="-do-jar-with-libraries">
384 <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
385 <pathconvert property="run.classpath.without.build.classes.dir">
386 <path path="${run.classpath}"/>
387 <map from="${build.classes.dir.resolved}" to=""/>
388 </pathconvert>
389 <pathconvert pathsep=" " property="jar.classpath">
390 <path path="${run.classpath.without.build.classes.dir}"/>
391 <chainedmapper>
392 <flattenmapper/>
393 <globmapper from="*" to="lib/*"/>
394 </chainedmapper>
395 </pathconvert>
396 <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>
397 <copylibs compress="${jar.compress}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}">
398 <fileset dir="${build.classes.dir}"/>
399 <manifest>
400 <attribute name="Main-Class" value="${main.class}"/>
401 <attribute name="Class-Path" value="${jar.classpath}"/>
402 </manifest>
403 </copylibs>
404 <echo>To run this application from the command line without Ant, try:</echo>
405 <property location="${dist.jar}" name="dist.jar.resolved"/>
406 <echo>java -jar "${dist.jar.resolved}"</echo>
407 </target>
408 <target name="-post-jar">
409 <!-- Empty placeholder for easier customization. -->
410 <!-- You can override this target in the ../build.xml file. -->
411 </target>
412 <target depends="init,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-post-jar" description="Build JAR." name="jar"/>
413 <!--
414 =================
415 EXECUTION SECTION
416 =================
417 -->
418 <target depends="init,compile" description="Run a main class." name="run">
419 <j2seproject1:java>
420 <customize>
421 <arg line="${application.args}"/>
422 </customize>
423 </j2seproject1:java>
424 </target>
425 <target name="-do-not-recompile">
426 <property name="javac.includes.binary" value=""/>
427 </target>
428 <target depends="init,-do-not-recompile,compile-single" name="run-single">
429 <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
430 <j2seproject1:java classname="${run.class}"/>
431 </target>
432 <!--
433 =================
434 DEBUGGING SECTION
435 =================
436 -->
437 <target depends="init" if="netbeans.home" name="-debug-start-debugger">
438 <j2seproject1:nbjpdastart name="${debug.class}"/>
439 </target>
440 <target depends="init,compile" name="-debug-start-debuggee">
441 <j2seproject3:debug>
442 <customize>
443 <arg line="${application.args}"/>
444 </customize>
445 </j2seproject3:debug>
446 </target>
447 <target depends="init,compile,-debug-start-debugger,-debug-start-debuggee" description="Debug project in IDE." if="netbeans.home" name="debug"/>
448 <target depends="init" if="netbeans.home" name="-debug-start-debugger-stepinto">
449 <j2seproject1:nbjpdastart stopclassname="${main.class}"/>
450 </target>
451 <target depends="init,compile,-debug-start-debugger-stepinto,-debug-start-debuggee" if="netbeans.home" name="debug-stepinto"/>
452 <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single">
453 <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
454 <j2seproject3:debug classname="${debug.class}"/>
455 </target>
456 <target depends="init,-do-not-recompile,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single"/>
457 <target depends="init" name="-pre-debug-fix">
458 <fail unless="fix.includes">Must set fix.includes</fail>
459 <property name="javac.includes" value="${fix.includes}.java"/>
460 </target>
461 <target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix">
462 <j2seproject1:nbjpdareload/>
463 </target>
464 <target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/>
465 <!--
466 ===============
467 JAVADOC SECTION
468 ===============
469 -->
470 <target depends="init" name="-javadoc-build">
471 <mkdir dir="${dist.javadoc.dir}"/>
472 <javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
473 <classpath>
474 <path path="${javac.classpath}"/>
475 </classpath>
476 <fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">
477 <filename name="**/*.java"/>
478 </fileset>
479 </javadoc>
480 </target>
481 <target depends="init,-javadoc-build" if="netbeans.home" name="-javadoc-browse" unless="no.javadoc.preview">
482 <nbbrowse file="${dist.javadoc.dir}/index.html"/>
483 </target>
484 <target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/>
485 <!--
486 =========================
487 JUNIT COMPILATION SECTION
488 =========================
489 -->
490 <target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">
491 <mkdir dir="${build.test.classes.dir}"/>
492 </target>
493 <target name="-pre-compile-test">
494 <!-- Empty placeholder for easier customization. -->
495 <!-- You can override this target in the ../build.xml file. -->
496 </target>
497 <target if="do.depend.true" name="-compile-test-depend">
498 <j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>
499 </target>
500 <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test">
501 <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>
502 <copy todir="${build.test.classes.dir}">
503 <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
504 </copy>
505 </target>
506 <target name="-post-compile-test">
507 <!-- Empty placeholder for easier customization. -->
508 <!-- You can override this target in the ../build.xml file. -->
509 </target>
510 <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/>
511 <target name="-pre-compile-test-single">
512 <!-- Empty placeholder for easier customization. -->
513 <!-- You can override this target in the ../build.xml file. -->
514 </target>
515 <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single">
516 <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
517 <j2seproject3:force-recompile destdir="${build.test.classes.dir}"/>
518 <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" sourcepath="${test.src.dir}" srcdir="${test.src.dir}"/>
519 <copy todir="${build.test.classes.dir}">
520 <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
521 </copy>
522 </target>
523 <target name="-post-compile-test-single">
524 <!-- Empty placeholder for easier customization. -->
525 <!-- You can override this target in the ../build.xml file. -->
526 </target>
527 <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/>
528 <!--
529 =======================
530 JUNIT EXECUTION SECTION
531 =======================
532 -->
533 <target depends="init" if="have.tests" name="-pre-test-run">
534 <mkdir dir="${build.test.results.dir}"/>
535 </target>
536 <target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">
537 <j2seproject3:junit testincludes="**/*Test.java"/>
538 </target>
539 <target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">
540 <fail if="tests.failed">Some tests failed; see details above.</fail>
541 </target>
542 <target depends="init" if="have.tests" name="test-report"/>
543 <target depends="init" if="netbeans.home+have.tests" name="-test-browse"/>
544 <target depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests." name="test"/>
545 <target depends="init" if="have.tests" name="-pre-test-run-single">
546 <mkdir dir="${build.test.results.dir}"/>
547 </target>
548 <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">
549 <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
550 <j2seproject3:junit excludes="" includes="${test.includes}"/>
551 </target>
552 <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">
553 <fail if="tests.failed">Some tests failed; see details above.</fail>
554 </target>
555 <target depends="init,-do-not-recompile,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/>
556 <!--
557 =======================
558 JUNIT DEBUGGING SECTION
559 =======================
560 -->
561 <target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test">
562 <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
563 <property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/>
564 <delete file="${test.report.file}"/>
565 <mkdir dir="${build.test.results.dir}"/>
566 <j2seproject3:debug classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner" classpath="${ant.home}/lib/ant.jar:${ant.home}/lib/ant-junit.jar:${debug.test.classpath}">
567 <customize>
568 <syspropertyset>
569 <propertyref prefix="test-sys-prop."/>
570 <mapper from="test-sys-prop.*" to="*" type="glob"/>
571 </syspropertyset>
572 <arg value="${test.class}"/>
573 <arg value="showoutput=true"/>
574 <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/>
575 <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/>
576 </customize>
577 </j2seproject3:debug>
578 </target>
579 <target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">
580 <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>
581 </target>
582 <target depends="init,-do-not-recompile,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>
583 <target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">
584 <j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/>
585 </target>
586 <target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/>
587 <!--
588 =========================
589 APPLET EXECUTION SECTION
590 =========================
591 -->
592 <target depends="init,compile-single" name="run-applet">
593 <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
594 <j2seproject1:java classname="sun.applet.AppletViewer">
595 <customize>
596 <arg value="${applet.url}"/>
597 </customize>
598 </j2seproject1:java>
599 </target>
600 <!--
601 =========================
602 APPLET DEBUGGING SECTION
603 =========================
604 -->
605 <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-applet">
606 <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
607 <j2seproject3:debug classname="sun.applet.AppletViewer">
608 <customize>
609 <arg value="${applet.url}"/>
610 </customize>
611 </j2seproject3:debug>
612 </target>
613 <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-applet" if="netbeans.home" name="debug-applet"/>
614 <!--
615 ===============
616 CLEANUP SECTION
617 ===============
618 -->
619 <target depends="init" name="deps-clean" unless="no.deps"/>
620 <target depends="init" name="-do-clean">
621 <delete dir="${build.dir}"/>
622 <delete dir="${dist.dir}"/>
623 </target>
624 <target name="-post-clean">
625 <!-- Empty placeholder for easier customization. -->
626 <!-- You can override this target in the ../build.xml file. -->
627 </target>
628 <target depends="init,deps-clean,-do-clean,-post-clean" description="Clean build products." name="clean"/>
629</project>
diff --git a/Four Puzzle Editor/nbproject/genfiles.properties b/Four Puzzle Editor/nbproject/genfiles.properties new file mode 100644 index 0000000..a655b80 --- /dev/null +++ b/Four Puzzle Editor/nbproject/genfiles.properties
@@ -0,0 +1,8 @@
1build.xml.data.CRC32=72b6fb06
2build.xml.script.CRC32=4dee7bef
3build.xml.stylesheet.CRC32=be360661
4# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
5# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
6nbproject/build-impl.xml.data.CRC32=72b6fb06
7nbproject/build-impl.xml.script.CRC32=5c7307d7
8nbproject/build-impl.xml.stylesheet.CRC32=487672f9
diff --git a/Four Puzzle Editor/nbproject/project.properties b/Four Puzzle Editor/nbproject/project.properties new file mode 100644 index 0000000..fa1b9b4 --- /dev/null +++ b/Four Puzzle Editor/nbproject/project.properties
@@ -0,0 +1,64 @@
1application.desc=A simple java desktop application based on Swing Application Framework
2application.homepage=http://appframework.dev.java.net
3application.title=Basic Application Example
4application.vendor=Sun Microsystems Inc.
5build.classes.dir=${build.dir}/classes
6build.classes.excludes=**/*.java,**/*.form
7# This directory is removed when the project is cleaned:
8build.dir=build
9build.generated.dir=${build.dir}/generated
10# Only compile against the classpath explicitly listed here:
11build.sysclasspath=ignore
12build.test.classes.dir=${build.dir}/test/classes
13build.test.results.dir=${build.dir}/test/results
14debug.classpath=\
15 ${run.classpath}
16debug.test.classpath=\
17 ${run.test.classpath}
18# This directory is removed when the project is cleaned:
19dist.dir=dist
20dist.jar=${dist.dir}/Four Puzzle Editor.jar
21dist.javadoc.dir=${dist.dir}/javadoc
22excludes=
23includes=**
24jar.compress=false
25javac.classpath=\
26 ${libs.swing-app-framework.classpath}
27# Space-separated list of extra javac options
28javac.compilerargs=
29javac.deprecation=false
30javac.source=1.5
31javac.target=1.5
32javac.test.classpath=\
33 ${javac.classpath}:\
34 ${build.classes.dir}:\
35 ${libs.junit.classpath}:\
36 ${libs.junit_4.classpath}
37javadoc.additionalparam=
38javadoc.author=false
39javadoc.encoding=${source.encoding}
40javadoc.noindex=false
41javadoc.nonavbar=false
42javadoc.notree=false
43javadoc.private=false
44javadoc.splitindex=true
45javadoc.use=true
46javadoc.version=false
47javadoc.windowtitle=
48main.class=com.fourisland.fourpuzzle.editor.FourPuzzleEditorApp
49manifest.file=manifest.mf
50meta.inf.dir=${src.dir}/META-INF
51platform.active=default_platform
52run.classpath=\
53 ${javac.classpath}:\
54 ${build.classes.dir}
55# Space-separated list of JVM arguments used when running the project
56# (you may also define separate properties like run-sys-prop.name=value instead of -Dname=value
57# or test-sys-prop.name=value to set system properties for unit tests):
58run.jvmargs=
59run.test.classpath=\
60 ${javac.test.classpath}:\
61 ${build.test.classes.dir}
62source.encoding=UTF-8
63src.dir=src
64test.src.dir=test
diff --git a/Four Puzzle Editor/nbproject/project.xml b/Four Puzzle Editor/nbproject/project.xml new file mode 100644 index 0000000..1656d14 --- /dev/null +++ b/Four Puzzle Editor/nbproject/project.xml
@@ -0,0 +1,19 @@
1<?xml version="1.0" encoding="UTF-8"?>
2<project xmlns="http://www.netbeans.org/ns/project/1">
3 <type>org.netbeans.modules.java.j2seproject</type>
4 <configuration>
5 <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
6 <name>Four Puzzle Editor</name>
7 <minimum-ant-version>1.6.5</minimum-ant-version>
8 <source-roots>
9 <root id="src.dir"/>
10 </source-roots>
11 <test-roots>
12 <root id="test.src.dir"/>
13 </test-roots>
14 </data>
15 <swingapp xmlns="http://www.netbeans.org/ns/form-swingapp/1">
16 <application-class name="com.fourisland.fourpuzzle.editor.FourPuzzleEditorApp"/>
17 </swingapp>
18 </configuration>
19</project>
diff --git a/Four Puzzle Editor/src/META-INF/services/org.jdesktop.application.Application b/Four Puzzle Editor/src/META-INF/services/org.jdesktop.application.Application new file mode 100644 index 0000000..5a8f48f --- /dev/null +++ b/Four Puzzle Editor/src/META-INF/services/org.jdesktop.application.Application
@@ -0,0 +1 @@
com.fourisland.fourpuzzle.editor.FourPuzzleEditorApp \ No newline at end of file
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorAboutBox.form b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorAboutBox.form new file mode 100644 index 0000000..2e00c7b --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorAboutBox.form
@@ -0,0 +1,203 @@
1<?xml version="1.0" encoding="UTF-8" ?>
2
3<Form version="1.5" maxVersion="1.6" type="org.netbeans.modules.form.forminfo.JDialogFormInfo">
4 <Properties>
5 <Property name="defaultCloseOperation" type="int" value="2"/>
6 <Property name="title" type="java.lang.String" resourceKey="title"/>
7 <Property name="modal" type="boolean" value="true"/>
8 <Property name="name" type="java.lang.String" value="aboutBox" noResource="true"/>
9 <Property name="resizable" type="boolean" value="false"/>
10 </Properties>
11 <SyntheticProperties>
12 <SyntheticProperty name="formSizePolicy" type="int" value="1"/>
13 </SyntheticProperties>
14 <AuxValues>
15 <AuxValue name="FormSettings_autoResourcing" type="java.lang.Integer" value="2"/>
16 <AuxValue name="FormSettings_autoSetComponentName" type="java.lang.Boolean" value="true"/>
17 <AuxValue name="FormSettings_generateMnemonicsCode" type="java.lang.Boolean" value="false"/>
18 <AuxValue name="FormSettings_i18nAutoMode" type="java.lang.Boolean" value="false"/>
19 <AuxValue name="FormSettings_layoutCodeTarget" type="java.lang.Integer" value="1"/>
20 <AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
21 <AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
22 <AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
23 </AuxValues>
24
25 <Layout>
26 <DimensionLayout dim="0">
27 <Group type="103" groupAlignment="0" attributes="0">
28 <Group type="102" alignment="0" attributes="0">
29 <Component id="imageLabel" min="-2" max="-2" attributes="0"/>
30 <EmptySpace type="separate" min="-2" max="-2" attributes="0"/>
31 <Group type="103" groupAlignment="1" attributes="0">
32 <Group type="102" alignment="0" attributes="0">
33 <Group type="103" groupAlignment="0" attributes="0">
34 <Component id="versionLabel" alignment="0" min="-2" max="-2" attributes="0"/>
35 <Component id="vendorLabel" alignment="0" min="-2" max="-2" attributes="0"/>
36 <Component id="homepageLabel" alignment="0" min="-2" max="-2" attributes="0"/>
37 </Group>
38 <EmptySpace min="-2" max="-2" attributes="0"/>
39 <Group type="103" groupAlignment="0" attributes="0">
40 <Component id="appVersionLabel" alignment="0" min="-2" max="-2" attributes="0"/>
41 <Component id="appVendorLabel" alignment="0" min="-2" max="-2" attributes="0"/>
42 <Component id="appHomepageLabel" alignment="0" min="-2" max="-2" attributes="0"/>
43 </Group>
44 </Group>
45 <Component id="appTitleLabel" alignment="0" min="-2" max="-2" attributes="0"/>
46 <Component id="appDescLabel" alignment="0" pref="266" max="32767" attributes="0"/>
47 <Component id="closeButton" alignment="1" min="-2" max="-2" attributes="0"/>
48 </Group>
49 <EmptySpace min="-2" max="-2" attributes="0"/>
50 </Group>
51 </Group>
52 </DimensionLayout>
53 <DimensionLayout dim="1">
54 <Group type="103" groupAlignment="0" attributes="0">
55 <Component id="imageLabel" min="-2" max="32767" attributes="0"/>
56 <Group type="102" alignment="0" attributes="0">
57 <EmptySpace max="-2" attributes="0"/>
58 <Component id="appTitleLabel" min="-2" max="-2" attributes="0"/>
59 <EmptySpace min="-2" max="-2" attributes="0"/>
60 <Component id="appDescLabel" min="-2" max="-2" attributes="0"/>
61 <EmptySpace min="-2" max="-2" attributes="0"/>
62 <Group type="103" groupAlignment="3" attributes="0">
63 <Component id="versionLabel" alignment="3" min="-2" max="-2" attributes="0"/>
64 <Component id="appVersionLabel" alignment="3" min="-2" max="-2" attributes="0"/>
65 </Group>
66 <EmptySpace min="-2" max="-2" attributes="0"/>
67 <Group type="103" groupAlignment="3" attributes="0">
68 <Component id="vendorLabel" alignment="3" min="-2" max="-2" attributes="0"/>
69 <Component id="appVendorLabel" alignment="3" min="-2" max="-2" attributes="0"/>
70 </Group>
71 <EmptySpace max="-2" attributes="0"/>
72 <Group type="103" groupAlignment="3" attributes="0">
73 <Component id="homepageLabel" alignment="3" min="-2" max="-2" attributes="0"/>
74 <Component id="appHomepageLabel" alignment="3" min="-2" max="-2" attributes="0"/>
75 </Group>
76 <EmptySpace min="-2" pref="19" max="32767" attributes="0"/>
77 <Component id="closeButton" min="-2" max="-2" attributes="0"/>
78 <EmptySpace max="-2" attributes="0"/>
79 </Group>
80 </Group>
81 </DimensionLayout>
82 </Layout>
83 <SubComponents>
84 <Component class="javax.swing.JButton" name="closeButton">
85 <Properties>
86 <Property name="action" type="javax.swing.Action" editor="org.netbeans.modules.swingapp.ActionEditor">
87 <action class="com.fourisland.fourpuzzle.editor.FourPuzzleEditorAboutBox" id="closeAboutBox" methodName="closeAboutBox"/>
88 </Property>
89 <Property name="name" type="java.lang.String" value="closeButton" noResource="true"/>
90 </Properties>
91 </Component>
92 <Component class="javax.swing.JLabel" name="appTitleLabel">
93 <Properties>
94 <Property name="font" type="java.awt.Font" noResource="true" editor="org.netbeans.modules.form.editors2.FontEditor">
95 <FontInfo relative="true">
96 <Font bold="true" component="appTitleLabel" property="font" relativeSize="true" size="4"/>
97 </FontInfo>
98 </Property>
99 <Property name="text" type="java.lang.String" resourceKey="Application.title"/>
100 <Property name="name" type="java.lang.String" value="appTitleLabel" noResource="true"/>
101 </Properties>
102 <AuxValues>
103 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
104 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
105 </AuxValues>
106 </Component>
107 <Component class="javax.swing.JLabel" name="versionLabel">
108 <Properties>
109 <Property name="font" type="java.awt.Font" noResource="true" editor="org.netbeans.modules.form.editors2.FontEditor">
110 <FontInfo relative="true">
111 <Font bold="true" component="versionLabel" property="font" relativeSize="true" size="0"/>
112 </FontInfo>
113 </Property>
114 <Property name="text" type="java.lang.String" resourceKey="versionLabel.text"/>
115 <Property name="name" type="java.lang.String" value="versionLabel" noResource="true"/>
116 </Properties>
117 <AuxValues>
118 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
119 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
120 </AuxValues>
121 </Component>
122 <Component class="javax.swing.JLabel" name="appVersionLabel">
123 <Properties>
124 <Property name="text" type="java.lang.String" resourceKey="Application.version"/>
125 <Property name="name" type="java.lang.String" value="appVersionLabel" noResource="true"/>
126 </Properties>
127 <AuxValues>
128 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
129 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
130 </AuxValues>
131 </Component>
132 <Component class="javax.swing.JLabel" name="vendorLabel">
133 <Properties>
134 <Property name="font" type="java.awt.Font" noResource="true" editor="org.netbeans.modules.form.editors2.FontEditor">
135 <FontInfo relative="true">
136 <Font bold="true" component="vendorLabel" property="font" relativeSize="true" size="0"/>
137 </FontInfo>
138 </Property>
139 <Property name="text" type="java.lang.String" resourceKey="vendorLabel.text"/>
140 <Property name="name" type="java.lang.String" value="vendorLabel" noResource="true"/>
141 </Properties>
142 <AuxValues>
143 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
144 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
145 </AuxValues>
146 </Component>
147 <Component class="javax.swing.JLabel" name="appVendorLabel">
148 <Properties>
149 <Property name="text" type="java.lang.String" resourceKey="Application.vendor"/>
150 <Property name="name" type="java.lang.String" value="appVendorLabel" noResource="true"/>
151 </Properties>
152 <AuxValues>
153 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
154 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
155 </AuxValues>
156 </Component>
157 <Component class="javax.swing.JLabel" name="homepageLabel">
158 <Properties>
159 <Property name="font" type="java.awt.Font" noResource="true" editor="org.netbeans.modules.form.editors2.FontEditor">
160 <FontInfo relative="true">
161 <Font bold="true" component="homepageLabel" property="font" relativeSize="true" size="0"/>
162 </FontInfo>
163 </Property>
164 <Property name="text" type="java.lang.String" resourceKey="homepageLabel.text"/>
165 <Property name="name" type="java.lang.String" value="homepageLabel" noResource="true"/>
166 </Properties>
167 <AuxValues>
168 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
169 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
170 </AuxValues>
171 </Component>
172 <Component class="javax.swing.JLabel" name="appHomepageLabel">
173 <Properties>
174 <Property name="text" type="java.lang.String" resourceKey="Application.homepage"/>
175 <Property name="name" type="java.lang.String" value="appHomepageLabel" noResource="true"/>
176 </Properties>
177 <AuxValues>
178 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
179 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
180 </AuxValues>
181 </Component>
182 <Component class="javax.swing.JLabel" name="appDescLabel">
183 <Properties>
184 <Property name="text" type="java.lang.String" resourceKey="appDescLabel.text"/>
185 <Property name="name" type="java.lang.String" value="appDescLabel" noResource="true"/>
186 </Properties>
187 <AuxValues>
188 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
189 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
190 </AuxValues>
191 </Component>
192 <Component class="javax.swing.JLabel" name="imageLabel">
193 <Properties>
194 <Property name="icon" type="javax.swing.Icon" resourceKey="imageLabel.icon"/>
195 <Property name="name" type="java.lang.String" value="imageLabel" noResource="true"/>
196 </Properties>
197 <AuxValues>
198 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
199 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
200 </AuxValues>
201 </Component>
202 </SubComponents>
203</Form>
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorAboutBox.java b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorAboutBox.java new file mode 100644 index 0000000..2162365 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorAboutBox.java
@@ -0,0 +1,137 @@
1/*
2 * FourPuzzleEditorAboutBox.java
3 */
4
5package com.fourisland.fourpuzzle.editor;
6
7import org.jdesktop.application.Action;
8
9public class FourPuzzleEditorAboutBox extends javax.swing.JDialog {
10
11 public FourPuzzleEditorAboutBox(java.awt.Frame parent) {
12 super(parent);
13 initComponents();
14 getRootPane().setDefaultButton(closeButton);
15 }
16
17 @Action public void closeAboutBox() {
18 setVisible(false);
19 }
20
21 /** This method is called from within the constructor to
22 * initialize the form.
23 * WARNING: Do NOT modify this code. The content of this method is
24 * always regenerated by the Form Editor.
25 */
26 // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
27 private void initComponents() {
28
29 closeButton = new javax.swing.JButton();
30 javax.swing.JLabel appTitleLabel = new javax.swing.JLabel();
31 javax.swing.JLabel versionLabel = new javax.swing.JLabel();
32 javax.swing.JLabel appVersionLabel = new javax.swing.JLabel();
33 javax.swing.JLabel vendorLabel = new javax.swing.JLabel();
34 javax.swing.JLabel appVendorLabel = new javax.swing.JLabel();
35 javax.swing.JLabel homepageLabel = new javax.swing.JLabel();
36 javax.swing.JLabel appHomepageLabel = new javax.swing.JLabel();
37 javax.swing.JLabel appDescLabel = new javax.swing.JLabel();
38 javax.swing.JLabel imageLabel = new javax.swing.JLabel();
39
40 setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
41 org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(com.fourisland.fourpuzzle.editor.FourPuzzleEditorApp.class).getContext().getResourceMap(FourPuzzleEditorAboutBox.class);
42 setTitle(resourceMap.getString("title")); // NOI18N
43 setModal(true);
44 setName("aboutBox"); // NOI18N
45 setResizable(false);
46
47 javax.swing.ActionMap actionMap = org.jdesktop.application.Application.getInstance(com.fourisland.fourpuzzle.editor.FourPuzzleEditorApp.class).getContext().getActionMap(FourPuzzleEditorAboutBox.class, this);
48 closeButton.setAction(actionMap.get("closeAboutBox")); // NOI18N
49 closeButton.setName("closeButton"); // NOI18N
50
51 appTitleLabel.setFont(appTitleLabel.getFont().deriveFont(appTitleLabel.getFont().getStyle() | java.awt.Font.BOLD, appTitleLabel.getFont().getSize()+4));
52 appTitleLabel.setText(resourceMap.getString("Application.title")); // NOI18N
53 appTitleLabel.setName("appTitleLabel"); // NOI18N
54
55 versionLabel.setFont(versionLabel.getFont().deriveFont(versionLabel.getFont().getStyle() | java.awt.Font.BOLD));
56 versionLabel.setText(resourceMap.getString("versionLabel.text")); // NOI18N
57 versionLabel.setName("versionLabel"); // NOI18N
58
59 appVersionLabel.setText(resourceMap.getString("Application.version")); // NOI18N
60 appVersionLabel.setName("appVersionLabel"); // NOI18N
61
62 vendorLabel.setFont(vendorLabel.getFont().deriveFont(vendorLabel.getFont().getStyle() | java.awt.Font.BOLD));
63 vendorLabel.setText(resourceMap.getString("vendorLabel.text")); // NOI18N
64 vendorLabel.setName("vendorLabel"); // NOI18N
65
66 appVendorLabel.setText(resourceMap.getString("Application.vendor")); // NOI18N
67 appVendorLabel.setName("appVendorLabel"); // NOI18N
68
69 homepageLabel.setFont(homepageLabel.getFont().deriveFont(homepageLabel.getFont().getStyle() | java.awt.Font.BOLD));
70 homepageLabel.setText(resourceMap.getString("homepageLabel.text")); // NOI18N
71 homepageLabel.setName("homepageLabel"); // NOI18N
72
73 appHomepageLabel.setText(resourceMap.getString("Application.homepage")); // NOI18N
74 appHomepageLabel.setName("appHomepageLabel"); // NOI18N
75
76 appDescLabel.setText(resourceMap.getString("appDescLabel.text")); // NOI18N
77 appDescLabel.setName("appDescLabel"); // NOI18N
78
79 imageLabel.setIcon(resourceMap.getIcon("imageLabel.icon")); // NOI18N
80 imageLabel.setName("imageLabel"); // NOI18N
81
82 javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
83 getContentPane().setLayout(layout);
84 layout.setHorizontalGroup(
85 layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
86 .addGroup(layout.createSequentialGroup()
87 .addComponent(imageLabel)
88 .addGap(18, 18, 18)
89 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
90 .addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createSequentialGroup()
91 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
92 .addComponent(versionLabel)
93 .addComponent(vendorLabel)
94 .addComponent(homepageLabel))
95 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
96 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
97 .addComponent(appVersionLabel)
98 .addComponent(appVendorLabel)
99 .addComponent(appHomepageLabel)))
100 .addComponent(appTitleLabel, javax.swing.GroupLayout.Alignment.LEADING)
101 .addComponent(appDescLabel, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 266, Short.MAX_VALUE)
102 .addComponent(closeButton))
103 .addContainerGap())
104 );
105 layout.setVerticalGroup(
106 layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
107 .addComponent(imageLabel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
108 .addGroup(layout.createSequentialGroup()
109 .addContainerGap()
110 .addComponent(appTitleLabel)
111 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
112 .addComponent(appDescLabel)
113 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
114 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
115 .addComponent(versionLabel)
116 .addComponent(appVersionLabel))
117 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
118 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
119 .addComponent(vendorLabel)
120 .addComponent(appVendorLabel))
121 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
122 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
123 .addComponent(homepageLabel)
124 .addComponent(appHomepageLabel))
125 .addGap(19, 19, Short.MAX_VALUE)
126 .addComponent(closeButton)
127 .addContainerGap())
128 );
129
130 pack();
131 }// </editor-fold>//GEN-END:initComponents
132
133 // Variables declaration - do not modify//GEN-BEGIN:variables
134 private javax.swing.JButton closeButton;
135 // End of variables declaration//GEN-END:variables
136
137}
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorApp.java b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorApp.java new file mode 100644 index 0000000..a2b7e19 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorApp.java
@@ -0,0 +1,44 @@
1/*
2 * FourPuzzleEditorApp.java
3 */
4
5package com.fourisland.fourpuzzle.editor;
6
7import org.jdesktop.application.Application;
8import org.jdesktop.application.SingleFrameApplication;
9
10/**
11 * The main class of the application.
12 */
13public class FourPuzzleEditorApp extends SingleFrameApplication {
14
15 /**
16 * At startup create and show the main frame of the application.
17 */
18 @Override protected void startup() {
19 show(new FourPuzzleEditorView(this));
20 }
21
22 /**
23 * This method is to initialize the specified window by injecting resources.
24 * Windows shown in our application come fully initialized from the GUI
25 * builder, so this additional configuration is not needed.
26 */
27 @Override protected void configureWindow(java.awt.Window root) {
28 }
29
30 /**
31 * A convenient static getter for the application instance.
32 * @return the instance of FourPuzzleEditorApp
33 */
34 public static FourPuzzleEditorApp getApplication() {
35 return Application.getInstance(FourPuzzleEditorApp.class);
36 }
37
38 /**
39 * Main method launching the application.
40 */
41 public static void main(String[] args) {
42 launch(FourPuzzleEditorApp.class, args);
43 }
44}
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorView.form b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorView.form new file mode 100644 index 0000000..d26c88d --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorView.form
@@ -0,0 +1,168 @@
1<?xml version="1.0" encoding="UTF-8" ?>
2
3<Form version="1.5" maxVersion="1.6">
4 <NonVisualComponents>
5 <Container class="javax.swing.JPanel" name="mainPanel">
6 <Properties>
7 <Property name="name" type="java.lang.String" value="mainPanel" noResource="true"/>
8 </Properties>
9
10 <Layout>
11 <DimensionLayout dim="0">
12 <Group type="103" groupAlignment="0" attributes="0">
13 <EmptySpace min="0" pref="400" max="32767" attributes="0"/>
14 </Group>
15 </DimensionLayout>
16 <DimensionLayout dim="1">
17 <Group type="103" groupAlignment="0" attributes="0">
18 <EmptySpace min="0" pref="252" max="32767" attributes="0"/>
19 </Group>
20 </DimensionLayout>
21 </Layout>
22 </Container>
23 <Container class="javax.swing.JMenuBar" name="menuBar">
24 <Properties>
25 <Property name="name" type="java.lang.String" value="menuBar" noResource="true"/>
26 </Properties>
27
28 <Layout class="org.netbeans.modules.form.compat2.layouts.DesignAbsoluteLayout">
29 <Property name="useNullLayout" type="boolean" value="true"/>
30 </Layout>
31 <SubComponents>
32 <Menu class="javax.swing.JMenu" name="fileMenu">
33 <Properties>
34 <Property name="text" type="java.lang.String" resourceKey="fileMenu.text"/>
35 <Property name="name" type="java.lang.String" value="fileMenu" noResource="true"/>
36 </Properties>
37 <AuxValues>
38 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
39 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
40 </AuxValues>
41 <SubComponents>
42 <MenuItem class="javax.swing.JMenuItem" name="exitMenuItem">
43 <Properties>
44 <Property name="action" type="javax.swing.Action" editor="org.netbeans.modules.swingapp.ActionEditor">
45 <action class="org.jdesktop.application.Application" id="quit" methodName="quit"/>
46 </Property>
47 <Property name="name" type="java.lang.String" value="exitMenuItem" noResource="true"/>
48 </Properties>
49 <AuxValues>
50 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
51 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
52 </AuxValues>
53 </MenuItem>
54 </SubComponents>
55 </Menu>
56 <Menu class="javax.swing.JMenu" name="helpMenu">
57 <Properties>
58 <Property name="text" type="java.lang.String" resourceKey="helpMenu.text"/>
59 <Property name="name" type="java.lang.String" value="helpMenu" noResource="true"/>
60 </Properties>
61 <AuxValues>
62 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
63 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
64 </AuxValues>
65 <SubComponents>
66 <MenuItem class="javax.swing.JMenuItem" name="aboutMenuItem">
67 <Properties>
68 <Property name="action" type="javax.swing.Action" editor="org.netbeans.modules.swingapp.ActionEditor">
69 <action class="com.fourisland.fourpuzzle.editor.FourPuzzleEditorView" id="showAboutBox" methodName="showAboutBox"/>
70 </Property>
71 <Property name="name" type="java.lang.String" value="aboutMenuItem" noResource="true"/>
72 </Properties>
73 <AuxValues>
74 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
75 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
76 </AuxValues>
77 </MenuItem>
78 </SubComponents>
79 </Menu>
80 </SubComponents>
81 </Container>
82 <Container class="javax.swing.JPanel" name="statusPanel">
83 <Properties>
84 <Property name="name" type="java.lang.String" value="statusPanel" noResource="true"/>
85 </Properties>
86
87 <Layout>
88 <DimensionLayout dim="0">
89 <Group type="103" groupAlignment="0" attributes="0">
90 <Component id="statusPanelSeparator" alignment="0" pref="400" max="32767" attributes="0"/>
91 <Group type="102" alignment="0" attributes="0">
92 <EmptySpace max="-2" attributes="0"/>
93 <Component id="statusMessageLabel" min="-2" max="-2" attributes="0"/>
94 <EmptySpace pref="226" max="32767" attributes="0"/>
95 <Component id="progressBar" min="-2" max="-2" attributes="0"/>
96 <EmptySpace max="-2" attributes="0"/>
97 <Component id="statusAnimationLabel" min="-2" max="-2" attributes="0"/>
98 <EmptySpace max="-2" attributes="0"/>
99 </Group>
100 </Group>
101 </DimensionLayout>
102 <DimensionLayout dim="1">
103 <Group type="103" groupAlignment="0" attributes="0">
104 <Group type="102" alignment="0" attributes="0">
105 <Component id="statusPanelSeparator" min="-2" pref="2" max="-2" attributes="0"/>
106 <EmptySpace max="32767" attributes="0"/>
107 <Group type="103" groupAlignment="3" attributes="0">
108 <Component id="statusMessageLabel" alignment="3" min="-2" max="-2" attributes="0"/>
109 <Component id="statusAnimationLabel" alignment="3" min="-2" max="-2" attributes="0"/>
110 <Component id="progressBar" alignment="3" min="-2" max="-2" attributes="0"/>
111 </Group>
112 <EmptySpace min="-2" pref="3" max="-2" attributes="0"/>
113 </Group>
114 </Group>
115 </DimensionLayout>
116 </Layout>
117 <SubComponents>
118 <Component class="javax.swing.JSeparator" name="statusPanelSeparator">
119 <Properties>
120 <Property name="name" type="java.lang.String" value="statusPanelSeparator" noResource="true"/>
121 </Properties>
122 <AuxValues>
123 <AuxValue name="JavaCodeGenerator_VariableLocal" type="java.lang.Boolean" value="true"/>
124 <AuxValue name="JavaCodeGenerator_VariableModifier" type="java.lang.Integer" value="0"/>
125 </AuxValues>
126 </Component>
127 <Component class="javax.swing.JLabel" name="statusMessageLabel">
128 <Properties>
129 <Property name="name" type="java.lang.String" value="statusMessageLabel" noResource="true"/>
130 </Properties>
131 </Component>
132 <Component class="javax.swing.JLabel" name="statusAnimationLabel">
133 <Properties>
134 <Property name="horizontalAlignment" type="int" value="2"/>
135 <Property name="name" type="java.lang.String" value="statusAnimationLabel" noResource="true"/>
136 </Properties>
137 </Component>
138 <Component class="javax.swing.JProgressBar" name="progressBar">
139 <Properties>
140 <Property name="name" type="java.lang.String" value="progressBar" noResource="true"/>
141 </Properties>
142 </Component>
143 </SubComponents>
144 </Container>
145 </NonVisualComponents>
146 <Properties>
147 <Property name="component" type="javax.swing.JComponent" editor="org.netbeans.modules.form.ComponentChooserEditor">
148 <ComponentRef name="mainPanel"/>
149 </Property>
150 <Property name="menuBar" type="javax.swing.JMenuBar" editor="org.netbeans.modules.form.ComponentChooserEditor">
151 <ComponentRef name="menuBar"/>
152 </Property>
153 <Property name="statusBar" type="javax.swing.JComponent" editor="org.netbeans.modules.form.ComponentChooserEditor">
154 <ComponentRef name="statusPanel"/>
155 </Property>
156 </Properties>
157 <AuxValues>
158 <AuxValue name="FormSettings_autoResourcing" type="java.lang.Integer" value="2"/>
159 <AuxValue name="FormSettings_autoSetComponentName" type="java.lang.Boolean" value="true"/>
160 <AuxValue name="FormSettings_generateMnemonicsCode" type="java.lang.Boolean" value="false"/>
161 <AuxValue name="FormSettings_i18nAutoMode" type="java.lang.Boolean" value="false"/>
162 <AuxValue name="FormSettings_layoutCodeTarget" type="java.lang.Integer" value="1"/>
163 <AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
164 <AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
165 <AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
166 <AuxValue name="designerSize" type="java.awt.Dimension" value="-84,-19,0,5,115,114,0,18,106,97,118,97,46,97,119,116,46,68,105,109,101,110,115,105,111,110,65,-114,-39,-41,-84,95,68,20,2,0,2,73,0,6,104,101,105,103,104,116,73,0,5,119,105,100,116,104,120,112,0,0,1,44,0,0,1,-112"/>
167 </AuxValues>
168</Form>
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorView.java b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorView.java new file mode 100644 index 0000000..e32a4dc --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/FourPuzzleEditorView.java
@@ -0,0 +1,208 @@
1/*
2 * FourPuzzleEditorView.java
3 */
4
5package com.fourisland.fourpuzzle.editor;
6
7import org.jdesktop.application.Action;
8import org.jdesktop.application.ResourceMap;
9import org.jdesktop.application.SingleFrameApplication;
10import org.jdesktop.application.FrameView;
11import org.jdesktop.application.TaskMonitor;
12import java.awt.event.ActionEvent;
13import java.awt.event.ActionListener;
14import javax.swing.Timer;
15import javax.swing.Icon;
16import javax.swing.JDialog;
17import javax.swing.JFrame;
18
19/**
20 * The application's main frame.
21 */
22public class FourPuzzleEditorView extends FrameView {
23
24 public FourPuzzleEditorView(SingleFrameApplication app) {
25 super(app);
26
27 initComponents();
28
29 // status bar initialization - message timeout, idle icon and busy animation, etc
30 ResourceMap resourceMap = getResourceMap();
31 int messageTimeout = resourceMap.getInteger("StatusBar.messageTimeout");
32 messageTimer = new Timer(messageTimeout, new ActionListener() {
33 public void actionPerformed(ActionEvent e) {
34 statusMessageLabel.setText("");
35 }
36 });
37 messageTimer.setRepeats(false);
38 int busyAnimationRate = resourceMap.getInteger("StatusBar.busyAnimationRate");
39 for (int i = 0; i < busyIcons.length; i++) {
40 busyIcons[i] = resourceMap.getIcon("StatusBar.busyIcons[" + i + "]");
41 }
42 busyIconTimer = new Timer(busyAnimationRate, new ActionListener() {
43 public void actionPerformed(ActionEvent e) {
44 busyIconIndex = (busyIconIndex + 1) % busyIcons.length;
45 statusAnimationLabel.setIcon(busyIcons[busyIconIndex]);
46 }
47 });
48 idleIcon = resourceMap.getIcon("StatusBar.idleIcon");
49 statusAnimationLabel.setIcon(idleIcon);
50 progressBar.setVisible(false);
51
52 // connecting action tasks to status bar via TaskMonitor
53 TaskMonitor taskMonitor = new TaskMonitor(getApplication().getContext());
54 taskMonitor.addPropertyChangeListener(new java.beans.PropertyChangeListener() {
55 public void propertyChange(java.beans.PropertyChangeEvent evt) {
56 String propertyName = evt.getPropertyName();
57 if ("started".equals(propertyName)) {
58 if (!busyIconTimer.isRunning()) {
59 statusAnimationLabel.setIcon(busyIcons[0]);
60 busyIconIndex = 0;
61 busyIconTimer.start();
62 }
63 progressBar.setVisible(true);
64 progressBar.setIndeterminate(true);
65 } else if ("done".equals(propertyName)) {
66 busyIconTimer.stop();
67 statusAnimationLabel.setIcon(idleIcon);
68 progressBar.setVisible(false);
69 progressBar.setValue(0);
70 } else if ("message".equals(propertyName)) {
71 String text = (String)(evt.getNewValue());
72 statusMessageLabel.setText((text == null) ? "" : text);
73 messageTimer.restart();
74 } else if ("progress".equals(propertyName)) {
75 int value = (Integer)(evt.getNewValue());
76 progressBar.setVisible(true);
77 progressBar.setIndeterminate(false);
78 progressBar.setValue(value);
79 }
80 }
81 });
82 }
83
84 @Action
85 public void showAboutBox() {
86 if (aboutBox == null) {
87 JFrame mainFrame = FourPuzzleEditorApp.getApplication().getMainFrame();
88 aboutBox = new FourPuzzleEditorAboutBox(mainFrame);
89 aboutBox.setLocationRelativeTo(mainFrame);
90 }
91 FourPuzzleEditorApp.getApplication().show(aboutBox);
92 }
93
94 /** This method is called from within the constructor to
95 * initialize the form.
96 * WARNING: Do NOT modify this code. The content of this method is
97 * always regenerated by the Form Editor.
98 */
99 @SuppressWarnings("unchecked")
100 // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
101 private void initComponents() {
102
103 mainPanel = new javax.swing.JPanel();
104 menuBar = new javax.swing.JMenuBar();
105 javax.swing.JMenu fileMenu = new javax.swing.JMenu();
106 javax.swing.JMenuItem exitMenuItem = new javax.swing.JMenuItem();
107 javax.swing.JMenu helpMenu = new javax.swing.JMenu();
108 javax.swing.JMenuItem aboutMenuItem = new javax.swing.JMenuItem();
109 statusPanel = new javax.swing.JPanel();
110 javax.swing.JSeparator statusPanelSeparator = new javax.swing.JSeparator();
111 statusMessageLabel = new javax.swing.JLabel();
112 statusAnimationLabel = new javax.swing.JLabel();
113 progressBar = new javax.swing.JProgressBar();
114
115 mainPanel.setName("mainPanel"); // NOI18N
116
117 javax.swing.GroupLayout mainPanelLayout = new javax.swing.GroupLayout(mainPanel);
118 mainPanel.setLayout(mainPanelLayout);
119 mainPanelLayout.setHorizontalGroup(
120 mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
121 .addGap(0, 400, Short.MAX_VALUE)
122 );
123 mainPanelLayout.setVerticalGroup(
124 mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
125 .addGap(0, 252, Short.MAX_VALUE)
126 );
127
128 menuBar.setName("menuBar"); // NOI18N
129
130 org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(com.fourisland.fourpuzzle.editor.FourPuzzleEditorApp.class).getContext().getResourceMap(FourPuzzleEditorView.class);
131 fileMenu.setText(resourceMap.getString("fileMenu.text")); // NOI18N
132 fileMenu.setName("fileMenu"); // NOI18N
133
134 javax.swing.ActionMap actionMap = org.jdesktop.application.Application.getInstance(com.fourisland.fourpuzzle.editor.FourPuzzleEditorApp.class).getContext().getActionMap(FourPuzzleEditorView.class, this);
135 exitMenuItem.setAction(actionMap.get("quit")); // NOI18N
136 exitMenuItem.setName("exitMenuItem"); // NOI18N
137 fileMenu.add(exitMenuItem);
138
139 menuBar.add(fileMenu);
140
141 helpMenu.setText(resourceMap.getString("helpMenu.text")); // NOI18N
142 helpMenu.setName("helpMenu"); // NOI18N
143
144 aboutMenuItem.setAction(actionMap.get("showAboutBox")); // NOI18N
145 aboutMenuItem.setName("aboutMenuItem"); // NOI18N
146 helpMenu.add(aboutMenuItem);
147
148 menuBar.add(helpMenu);
149
150 statusPanel.setName("statusPanel"); // NOI18N
151
152 statusPanelSeparator.setName("statusPanelSeparator"); // NOI18N
153
154 statusMessageLabel.setName("statusMessageLabel"); // NOI18N
155
156 statusAnimationLabel.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
157 statusAnimationLabel.setName("statusAnimationLabel"); // NOI18N
158
159 progressBar.setName("progressBar"); // NOI18N
160
161 javax.swing.GroupLayout statusPanelLayout = new javax.swing.GroupLayout(statusPanel);
162 statusPanel.setLayout(statusPanelLayout);
163 statusPanelLayout.setHorizontalGroup(
164 statusPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
165 .addComponent(statusPanelSeparator, javax.swing.GroupLayout.DEFAULT_SIZE, 400, Short.MAX_VALUE)
166 .addGroup(statusPanelLayout.createSequentialGroup()
167 .addContainerGap()
168 .addComponent(statusMessageLabel)
169 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 226, Short.MAX_VALUE)
170 .addComponent(progressBar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
171 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
172 .addComponent(statusAnimationLabel)
173 .addContainerGap())
174 );
175 statusPanelLayout.setVerticalGroup(
176 statusPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
177 .addGroup(statusPanelLayout.createSequentialGroup()
178 .addComponent(statusPanelSeparator, javax.swing.GroupLayout.PREFERRED_SIZE, 2, javax.swing.GroupLayout.PREFERRED_SIZE)
179 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
180 .addGroup(statusPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
181 .addComponent(statusMessageLabel)
182 .addComponent(statusAnimationLabel)
183 .addComponent(progressBar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
184 .addGap(3, 3, 3))
185 );
186
187 setComponent(mainPanel);
188 setMenuBar(menuBar);
189 setStatusBar(statusPanel);
190 }// </editor-fold>//GEN-END:initComponents
191
192 // Variables declaration - do not modify//GEN-BEGIN:variables
193 private javax.swing.JPanel mainPanel;
194 private javax.swing.JMenuBar menuBar;
195 private javax.swing.JProgressBar progressBar;
196 private javax.swing.JLabel statusAnimationLabel;
197 private javax.swing.JLabel statusMessageLabel;
198 private javax.swing.JPanel statusPanel;
199 // End of variables declaration//GEN-END:variables
200
201 private final Timer messageTimer;
202 private final Timer busyIconTimer;
203 private final Icon idleIcon;
204 private final Icon[] busyIcons = new Icon[15];
205 private int busyIconIndex = 0;
206
207 private JDialog aboutBox;
208}
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorAboutBox.properties b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorAboutBox.properties new file mode 100644 index 0000000..b76ddd5 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorAboutBox.properties
@@ -0,0 +1,14 @@
1title = About: ${Application.title} ${Application.version}
2
3closeAboutBox.Action.text = &Close
4
5appDescLabel.text=<html>${Application.description}
6
7versionLabel.text=Product Version\:
8
9vendorLabel.text=Vendor\:
10
11homepageLabel.text=Homepage\:
12
13#NOI18N
14imageLabel.icon=about.png
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorApp.properties b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorApp.properties new file mode 100644 index 0000000..4d38449 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorApp.properties
@@ -0,0 +1,11 @@
1# Application global resources
2
3Application.name = Four Puzzle Editor
4Application.title = Basic Application Example
5Application.version = 1.0
6Application.vendor = Sun Microsystems Inc.
7Application.homepage = http\://appframework.dev.java.net/
8Application.description = A simple Java desktop application based on Swing Application Framework.
9Application.vendorId = Sun
10Application.id = ${Application.name}
11Application.lookAndFeel = system
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorView.properties b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorView.properties new file mode 100644 index 0000000..acfea1b --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/FourPuzzleEditorView.properties
@@ -0,0 +1,32 @@
1# Resources for the FourPuzzleEditorView class
2
3# top-level menus
4
5fileMenu.text = File
6helpMenu.text = Help
7
8# @Action resources
9
10showAboutBox.Action.text = &About...
11showAboutBox.Action.shortDescription = Show the application's information dialog
12
13# status bar resources
14
15StatusBar.messageTimeout = 5000
16StatusBar.busyAnimationRate = 30
17StatusBar.idleIcon = busyicons/idle-icon.png
18StatusBar.busyIcons[0] = busyicons/busy-icon0.png
19StatusBar.busyIcons[1] = busyicons/busy-icon1.png
20StatusBar.busyIcons[2] = busyicons/busy-icon2.png
21StatusBar.busyIcons[3] = busyicons/busy-icon3.png
22StatusBar.busyIcons[4] = busyicons/busy-icon4.png
23StatusBar.busyIcons[5] = busyicons/busy-icon5.png
24StatusBar.busyIcons[6] = busyicons/busy-icon6.png
25StatusBar.busyIcons[7] = busyicons/busy-icon7.png
26StatusBar.busyIcons[8] = busyicons/busy-icon8.png
27StatusBar.busyIcons[9] = busyicons/busy-icon9.png
28StatusBar.busyIcons[10] = busyicons/busy-icon10.png
29StatusBar.busyIcons[11] = busyicons/busy-icon11.png
30StatusBar.busyIcons[12] = busyicons/busy-icon12.png
31StatusBar.busyIcons[13] = busyicons/busy-icon13.png
32StatusBar.busyIcons[14] = busyicons/busy-icon14.png
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/about.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/about.png new file mode 100644 index 0000000..c6dfe0a --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/about.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon0.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon0.png new file mode 100644 index 0000000..242c0c8 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon0.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon1.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon1.png new file mode 100644 index 0000000..9f6f634 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon1.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon10.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon10.png new file mode 100644 index 0000000..c4ef4a1 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon10.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon11.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon11.png new file mode 100644 index 0000000..6eca1f5 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon11.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon12.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon12.png new file mode 100644 index 0000000..e447ee8 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon12.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon13.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon13.png new file mode 100644 index 0000000..848a6f1 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon13.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon14.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon14.png new file mode 100644 index 0000000..7b3561d --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon14.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon2.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon2.png new file mode 100644 index 0000000..c866e62 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon2.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon3.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon3.png new file mode 100644 index 0000000..9be22fa --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon3.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon4.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon4.png new file mode 100644 index 0000000..f07c20d --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon4.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon5.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon5.png new file mode 100644 index 0000000..653fc9c --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon5.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon6.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon6.png new file mode 100644 index 0000000..7035572 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon6.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon7.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon7.png new file mode 100644 index 0000000..49fbc6e --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon7.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon8.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon8.png new file mode 100644 index 0000000..e1a5a40 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon8.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon9.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon9.png new file mode 100644 index 0000000..8278012 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/busy-icon9.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/idle-icon.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/idle-icon.png new file mode 100644 index 0000000..50312f8 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/busyicons/idle-icon.png
Binary files differ
diff --git a/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/splash.png b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/splash.png new file mode 100644 index 0000000..a1fbdc1 --- /dev/null +++ b/Four Puzzle Editor/src/com/fourisland/fourpuzzle/editor/resources/splash.png
Binary files differ