diff options
Diffstat (limited to 'Four Puzzle Editor/src')
27 files changed, 818 insertions, 0 deletions
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 | |||
5 | package com.fourisland.fourpuzzle.editor; | ||
6 | |||
7 | import org.jdesktop.application.Action; | ||
8 | |||
9 | public 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 | |||
5 | package com.fourisland.fourpuzzle.editor; | ||
6 | |||
7 | import org.jdesktop.application.Application; | ||
8 | import org.jdesktop.application.SingleFrameApplication; | ||
9 | |||
10 | /** | ||
11 | * The main class of the application. | ||
12 | */ | ||
13 | public 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 | |||
5 | package com.fourisland.fourpuzzle.editor; | ||
6 | |||
7 | import org.jdesktop.application.Action; | ||
8 | import org.jdesktop.application.ResourceMap; | ||
9 | import org.jdesktop.application.SingleFrameApplication; | ||
10 | import org.jdesktop.application.FrameView; | ||
11 | import org.jdesktop.application.TaskMonitor; | ||
12 | import java.awt.event.ActionEvent; | ||
13 | import java.awt.event.ActionListener; | ||
14 | import javax.swing.Timer; | ||
15 | import javax.swing.Icon; | ||
16 | import javax.swing.JDialog; | ||
17 | import javax.swing.JFrame; | ||
18 | |||
19 | /** | ||
20 | * The application's main frame. | ||
21 | */ | ||
22 | public 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 @@ | |||
1 | title = About: ${Application.title} ${Application.version} | ||
2 | |||
3 | closeAboutBox.Action.text = &Close | ||
4 | |||
5 | appDescLabel.text=<html>${Application.description} | ||
6 | |||
7 | versionLabel.text=Product Version\: | ||
8 | |||
9 | vendorLabel.text=Vendor\: | ||
10 | |||
11 | homepageLabel.text=Homepage\: | ||
12 | |||
13 | #NOI18N | ||
14 | imageLabel.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 | |||
3 | Application.name = Four Puzzle Editor | ||
4 | Application.title = Basic Application Example | ||
5 | Application.version = 1.0 | ||
6 | Application.vendor = Sun Microsystems Inc. | ||
7 | Application.homepage = http\://appframework.dev.java.net/ | ||
8 | Application.description = A simple Java desktop application based on Swing Application Framework. | ||
9 | Application.vendorId = Sun | ||
10 | Application.id = ${Application.name} | ||
11 | Application.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 | |||
5 | fileMenu.text = File | ||
6 | helpMenu.text = Help | ||
7 | |||
8 | # @Action resources | ||
9 | |||
10 | showAboutBox.Action.text = &About... | ||
11 | showAboutBox.Action.shortDescription = Show the application's information dialog | ||
12 | |||
13 | # status bar resources | ||
14 | |||
15 | StatusBar.messageTimeout = 5000 | ||
16 | StatusBar.busyAnimationRate = 30 | ||
17 | StatusBar.idleIcon = busyicons/idle-icon.png | ||
18 | StatusBar.busyIcons[0] = busyicons/busy-icon0.png | ||
19 | StatusBar.busyIcons[1] = busyicons/busy-icon1.png | ||
20 | StatusBar.busyIcons[2] = busyicons/busy-icon2.png | ||
21 | StatusBar.busyIcons[3] = busyicons/busy-icon3.png | ||
22 | StatusBar.busyIcons[4] = busyicons/busy-icon4.png | ||
23 | StatusBar.busyIcons[5] = busyicons/busy-icon5.png | ||
24 | StatusBar.busyIcons[6] = busyicons/busy-icon6.png | ||
25 | StatusBar.busyIcons[7] = busyicons/busy-icon7.png | ||
26 | StatusBar.busyIcons[8] = busyicons/busy-icon8.png | ||
27 | StatusBar.busyIcons[9] = busyicons/busy-icon9.png | ||
28 | StatusBar.busyIcons[10] = busyicons/busy-icon10.png | ||
29 | StatusBar.busyIcons[11] = busyicons/busy-icon11.png | ||
30 | StatusBar.busyIcons[12] = busyicons/busy-icon12.png | ||
31 | StatusBar.busyIcons[13] = busyicons/busy-icon13.png | ||
32 | StatusBar.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 | |||