Neurogami-roir 1.3.3.1
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +22 -0
- data/Manifest.txt +250 -0
- data/README.md +12 -0
- data/Rakefile +63 -0
- data/bin/roir +176 -0
- data/data/GenericJavaApp.icns +0 -0
- data/data/JavaApplicationStub +0 -0
- data/data/Rawr logo 1 large.png +0 -0
- data/data/Rawr logo 2 large.png +0 -0
- data/data/Rawr logo2.png +0 -0
- data/data/website/_notes/dwsync.xml +1 -0
- data/data/website/css/1.css +254 -0
- data/data/website/css/_notes/dwsync.xml +1 -0
- data/data/website/images/_notes/dwsync.xml +1 -0
- data/data/website/images/body_bg.jpg +0 -0
- data/data/website/images/bullet.gif +0 -0
- data/data/website/images/content.jpg +0 -0
- data/data/website/images/content_h2.gif +0 -0
- data/data/website/images/details.gif +0 -0
- data/data/website/images/details.jpg +0 -0
- data/data/website/images/header_bg.jpg +0 -0
- data/data/website/images/nav_a_hover.gif +0 -0
- data/data/website/images/rawr_logo.png +0 -0
- data/data/website/index.html +164 -0
- data/lib/app_bundler.rb +138 -0
- data/lib/bundler.rb +36 -0
- data/lib/command.rb +68 -0
- data/lib/exe_bundler.rb +106 -0
- data/lib/generator.rb +127 -0
- data/lib/jar_builder.rb +57 -0
- data/lib/jruby_batch_compiler.rb +127 -0
- data/lib/jruby_release.rb +104 -0
- data/lib/launch4j/LICENSE.txt +30 -0
- data/lib/launch4j/bin-linux/COPYING +340 -0
- data/lib/launch4j/bin-linux/ld +0 -0
- data/lib/launch4j/bin-linux/windres +0 -0
- data/lib/launch4j/bin-mac/COPYING +340 -0
- data/lib/launch4j/bin-mac/ld +0 -0
- data/lib/launch4j/bin-mac/readme.txt +1 -0
- data/lib/launch4j/bin-mac/windres +0 -0
- data/lib/launch4j/bin-win/COPYING +340 -0
- data/lib/launch4j/bin-win/ld.exe +0 -0
- data/lib/launch4j/bin-win/windres.exe +0 -0
- data/lib/launch4j/build.xml +62 -0
- data/lib/launch4j/demo/ConsoleApp/ConsoleApp.jar +0 -0
- data/lib/launch4j/demo/ConsoleApp/build.xml +57 -0
- data/lib/launch4j/demo/ConsoleApp/l4j/ConsoleApp.ico +0 -0
- data/lib/launch4j/demo/ConsoleApp/lib/readme.txt +8 -0
- data/lib/launch4j/demo/ConsoleApp/readme.txt +1 -0
- data/lib/launch4j/demo/ConsoleApp/src/net/sf/launch4j/example/ConsoleApp.java +72 -0
- data/lib/launch4j/demo/LICENSE.txt +30 -0
- data/lib/launch4j/demo/SimpleApp/SimpleApp.jar +0 -0
- data/lib/launch4j/demo/SimpleApp/build.xml +52 -0
- data/lib/launch4j/demo/SimpleApp/l4j/SimpleApp.ico +0 -0
- data/lib/launch4j/demo/SimpleApp/l4j/SimpleApp.xml +18 -0
- data/lib/launch4j/demo/SimpleApp/l4j/splash.bmp +0 -0
- data/lib/launch4j/demo/SimpleApp/lib/readme.txt +8 -0
- data/lib/launch4j/demo/SimpleApp/readme.txt +1 -0
- data/lib/launch4j/demo/SimpleApp/src/net/sf/launch4j/example/SimpleApp.java +104 -0
- data/lib/launch4j/demo/readme.txt +3 -0
- data/lib/launch4j/head/LICENSE.txt +23 -0
- data/lib/launch4j/head/consolehead.o +0 -0
- data/lib/launch4j/head/guihead.o +0 -0
- data/lib/launch4j/head/head.o +0 -0
- data/lib/launch4j/head_src/LICENSE.txt +23 -0
- data/lib/launch4j/head_src/consolehead/Makefile.win +33 -0
- data/lib/launch4j/head_src/consolehead/consolehead.c +65 -0
- data/lib/launch4j/head_src/consolehead/consolehead.dev +108 -0
- data/lib/launch4j/head_src/guihead/Makefile.win +33 -0
- data/lib/launch4j/head_src/guihead/guihead.c +185 -0
- data/lib/launch4j/head_src/guihead/guihead.dev +109 -0
- data/lib/launch4j/head_src/guihead/guihead.h +43 -0
- data/lib/launch4j/head_src/head.c +807 -0
- data/lib/launch4j/head_src/head.h +113 -0
- data/lib/launch4j/head_src/resource.h +71 -0
- data/lib/launch4j/launch4j +8 -0
- data/lib/launch4j/launch4j.jar +0 -0
- data/lib/launch4j/launch4j.jfpr +0 -0
- data/lib/launch4j/lib/JGoodies.Forms.LICENSE.txt +31 -0
- data/lib/launch4j/lib/JGoodies.Looks.LICENSE.txt +31 -0
- data/lib/launch4j/lib/Nuvola.Icon.Theme.LICENSE.txt +504 -0
- data/lib/launch4j/lib/XStream.LICENSE.txt +27 -0
- data/lib/launch4j/lib/commons-beanutils.jar +0 -0
- data/lib/launch4j/lib/commons-logging.jar +0 -0
- data/lib/launch4j/lib/commons.LICENSE.txt +50 -0
- data/lib/launch4j/lib/forms.jar +0 -0
- data/lib/launch4j/lib/formsrt.jar +0 -0
- data/lib/launch4j/lib/foxtrot.LICENSE.txt +25 -0
- data/lib/launch4j/lib/foxtrot.jar +0 -0
- data/lib/launch4j/lib/looks.jar +0 -0
- data/lib/launch4j/lib/xstream.jar +0 -0
- data/lib/launch4j/manifest/uac.exe.manifest +12 -0
- data/lib/launch4j/manifest/xp-themes.exe.manifest +14 -0
- data/lib/launch4j/src/images/asterix-o.gif +0 -0
- data/lib/launch4j/src/images/asterix.gif +0 -0
- data/lib/launch4j/src/images/build.png +0 -0
- data/lib/launch4j/src/images/button_ok.png +0 -0
- data/lib/launch4j/src/images/cancel16.png +0 -0
- data/lib/launch4j/src/images/down16.png +0 -0
- data/lib/launch4j/src/images/edit_add16.png +0 -0
- data/lib/launch4j/src/images/info.png +0 -0
- data/lib/launch4j/src/images/new.png +0 -0
- data/lib/launch4j/src/images/new16.png +0 -0
- data/lib/launch4j/src/images/ok16.png +0 -0
- data/lib/launch4j/src/images/open.png +0 -0
- data/lib/launch4j/src/images/open16.png +0 -0
- data/lib/launch4j/src/images/run.png +0 -0
- data/lib/launch4j/src/images/save.png +0 -0
- data/lib/launch4j/src/images/up16.png +0 -0
- data/lib/launch4j/src/launch4j.properties +2 -0
- data/lib/launch4j/src/net/sf/launch4j/Builder.java +207 -0
- data/lib/launch4j/src/net/sf/launch4j/BuilderException.java +52 -0
- data/lib/launch4j/src/net/sf/launch4j/ExecException.java +66 -0
- data/lib/launch4j/src/net/sf/launch4j/FileChooserFilter.java +76 -0
- data/lib/launch4j/src/net/sf/launch4j/Log.java +105 -0
- data/lib/launch4j/src/net/sf/launch4j/Main.java +99 -0
- data/lib/launch4j/src/net/sf/launch4j/Messages.java +78 -0
- data/lib/launch4j/src/net/sf/launch4j/OptionParser.java +71 -0
- data/lib/launch4j/src/net/sf/launch4j/RcBuilder.java +340 -0
- data/lib/launch4j/src/net/sf/launch4j/Util.java +197 -0
- data/lib/launch4j/src/net/sf/launch4j/ant/AntClassPath.java +61 -0
- data/lib/launch4j/src/net/sf/launch4j/ant/AntConfig.java +129 -0
- data/lib/launch4j/src/net/sf/launch4j/ant/AntJre.java +69 -0
- data/lib/launch4j/src/net/sf/launch4j/ant/Launch4jTask.java +162 -0
- data/lib/launch4j/src/net/sf/launch4j/ant/Messages.java +55 -0
- data/lib/launch4j/src/net/sf/launch4j/ant/StringWrapper.java +67 -0
- data/lib/launch4j/src/net/sf/launch4j/ant/messages.properties +35 -0
- data/lib/launch4j/src/net/sf/launch4j/ant/messages_es.properties +35 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/Binding.java +62 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/BindingException.java +52 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/Bindings.java +317 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/IValidatable.java +44 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/InvariantViolationException.java +67 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/JComboBoxBinding.java +119 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/JListBinding.java +118 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/JRadioButtonBinding.java +146 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/JTextAreaBinding.java +123 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/JTextComponentBinding.java +108 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/JToggleButtonBinding.java +108 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/Messages.java +78 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/OptComponentBinding.java +119 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/OptJTextAreaBinding.java +141 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/Validator.java +259 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/messages.properties +52 -0
- data/lib/launch4j/src/net/sf/launch4j/binding/messages_es.properties +51 -0
- data/lib/launch4j/src/net/sf/launch4j/config/ClassPath.java +87 -0
- data/lib/launch4j/src/net/sf/launch4j/config/Config.java +396 -0
- data/lib/launch4j/src/net/sf/launch4j/config/ConfigPersister.java +249 -0
- data/lib/launch4j/src/net/sf/launch4j/config/ConfigPersisterException.java +51 -0
- data/lib/launch4j/src/net/sf/launch4j/config/Jre.java +235 -0
- data/lib/launch4j/src/net/sf/launch4j/config/LdDefaults.java +62 -0
- data/lib/launch4j/src/net/sf/launch4j/config/Messages.java +78 -0
- data/lib/launch4j/src/net/sf/launch4j/config/Msg.java +111 -0
- data/lib/launch4j/src/net/sf/launch4j/config/SingleInstance.java +74 -0
- data/lib/launch4j/src/net/sf/launch4j/config/Splash.java +103 -0
- data/lib/launch4j/src/net/sf/launch4j/config/VersionInfo.java +168 -0
- data/lib/launch4j/src/net/sf/launch4j/config/messages.properties +93 -0
- data/lib/launch4j/src/net/sf/launch4j/config/messages_es.properties +75 -0
- data/lib/launch4j/src/net/sf/launch4j/form/BasicForm.java +283 -0
- data/lib/launch4j/src/net/sf/launch4j/form/BasicForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/ClassPathForm.java +193 -0
- data/lib/launch4j/src/net/sf/launch4j/form/ClassPathForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/ConfigForm.java +132 -0
- data/lib/launch4j/src/net/sf/launch4j/form/ConfigForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/EnvironmentVarsForm.java +127 -0
- data/lib/launch4j/src/net/sf/launch4j/form/EnvironmentVarsForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/HeaderForm.java +171 -0
- data/lib/launch4j/src/net/sf/launch4j/form/HeaderForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/JreForm.java +266 -0
- data/lib/launch4j/src/net/sf/launch4j/form/JreForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/Messages.java +55 -0
- data/lib/launch4j/src/net/sf/launch4j/form/MessagesForm.java +183 -0
- data/lib/launch4j/src/net/sf/launch4j/form/MessagesForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/SingleInstanceForm.java +141 -0
- data/lib/launch4j/src/net/sf/launch4j/form/SingleInstanceForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/SplashForm.java +166 -0
- data/lib/launch4j/src/net/sf/launch4j/form/SplashForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/VersionInfoForm.java +232 -0
- data/lib/launch4j/src/net/sf/launch4j/form/VersionInfoForm.jfrm +0 -0
- data/lib/launch4j/src/net/sf/launch4j/form/messages.properties +146 -0
- data/lib/launch4j/src/net/sf/launch4j/form/messages_es.properties +118 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/AbstractAcceptListener.java +75 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/BasicFormImpl.java +101 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/BrowseActionListener.java +79 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/ClassPathFormImpl.java +222 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/ConfigFormImpl.java +100 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/EnvironmentVarsFormImpl.java +50 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/FileChooser.java +65 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/GlassPane.java +67 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/HeaderFormImpl.java +102 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/JreFormImpl.java +166 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/MainFrame.java +358 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/Messages.java +55 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/MessagesFormImpl.java +58 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/SingleInstanceFormImpl.java +54 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/SplashFormImpl.java +61 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/VersionInfoFormImpl.java +63 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/messages.properties +74 -0
- data/lib/launch4j/src/net/sf/launch4j/formimpl/messages_es.properties +56 -0
- data/lib/launch4j/src/net/sf/launch4j/messages.properties +45 -0
- data/lib/launch4j/src/net/sf/launch4j/messages_es.properties +45 -0
- data/lib/launch4j/w32api/MinGW.LICENSE.txt +25 -0
- data/lib/launch4j/w32api/crt2.o +0 -0
- data/lib/launch4j/w32api/libadvapi32.a +0 -0
- data/lib/launch4j/w32api/libgcc.a +0 -0
- data/lib/launch4j/w32api/libkernel32.a +0 -0
- data/lib/launch4j/w32api/libmingw32.a +0 -0
- data/lib/launch4j/w32api/libmsvcrt.a +0 -0
- data/lib/launch4j/w32api/libshell32.a +0 -0
- data/lib/launch4j/w32api/libuser32.a +0 -0
- data/lib/launch4j/web/bullet.gif +0 -0
- data/lib/launch4j/web/changelog.html +356 -0
- data/lib/launch4j/web/docs.html +585 -0
- data/lib/launch4j/web/index.html +128 -0
- data/lib/launch4j/web/launch4j-use.gif +0 -0
- data/lib/launch4j/web/launch4j.gif +0 -0
- data/lib/launch4j/web/links.html +73 -0
- data/lib/launch4j/web/style.css +159 -0
- data/lib/options.rb +101 -0
- data/lib/platform.rb +28 -0
- data/lib/rawr.rb +178 -0
- data/lib/rawr_bundle.rb +26 -0
- data/lib/rawr_version.rb +3 -0
- data/lib/web_bundler.rb +114 -0
- data/lib/zip/ioextras.rb +155 -0
- data/lib/zip/stdrubyext.rb +111 -0
- data/lib/zip/tempfile_bugfixed.rb +195 -0
- data/lib/zip/zip.rb +1848 -0
- data/lib/zip/zipfilesystem.rb +609 -0
- data/lib/zip/ziprequire.rb +90 -0
- data/tasks/ann.rake +81 -0
- data/tasks/bones.rake +21 -0
- data/tasks/gem.rake +121 -0
- data/tasks/manifest.rake +49 -0
- data/tasks/notes.rake +28 -0
- data/tasks/post_load.rake +39 -0
- data/tasks/rdoc.rake +51 -0
- data/tasks/rubyforge.rake +57 -0
- data/tasks/setup.rb +269 -0
- data/tasks/spec.rake +63 -0
- data/tasks/svn.rake +48 -0
- data/tasks/test.rake +38 -0
- data/test/unit/app_bundler_spec.rb +65 -0
- data/test/unit/bundler_spec.rb +27 -0
- data/test/unit/generator_spec.rb +49 -0
- data/test/unit/jar_builder_spec.rb +5 -0
- data/test/unit/options_spec.rb +97 -0
- data/test/unit/platform_spec.rb +29 -0
- data/test/unit/spec_helpers.rb +22 -0
- data/test/unit/web_bundler_spec.rb +83 -0
- metadata +501 -0
@@ -0,0 +1,127 @@
|
|
1
|
+
package net.sf.launch4j.form;
|
2
|
+
|
3
|
+
import com.jgoodies.forms.layout.CellConstraints;
|
4
|
+
import com.jgoodies.forms.layout.FormLayout;
|
5
|
+
import java.awt.BorderLayout;
|
6
|
+
import java.awt.Container;
|
7
|
+
import java.awt.Dimension;
|
8
|
+
import javax.swing.Box;
|
9
|
+
import javax.swing.ImageIcon;
|
10
|
+
import javax.swing.JLabel;
|
11
|
+
import javax.swing.JPanel;
|
12
|
+
import javax.swing.JScrollPane;
|
13
|
+
import javax.swing.JTextArea;
|
14
|
+
|
15
|
+
public abstract class EnvironmentVarsForm extends JPanel
|
16
|
+
{
|
17
|
+
protected final JTextArea _envVarsTextArea = new JTextArea();
|
18
|
+
protected final JLabel _envVarsLabel = new JLabel();
|
19
|
+
|
20
|
+
/**
|
21
|
+
* Default constructor
|
22
|
+
*/
|
23
|
+
public EnvironmentVarsForm()
|
24
|
+
{
|
25
|
+
initializePanel();
|
26
|
+
}
|
27
|
+
|
28
|
+
/**
|
29
|
+
* Adds fill components to empty cells in the first row and first column of the grid.
|
30
|
+
* This ensures that the grid spacing will be the same as shown in the designer.
|
31
|
+
* @param cols an array of column indices in the first row where fill components should be added.
|
32
|
+
* @param rows an array of row indices in the first column where fill components should be added.
|
33
|
+
*/
|
34
|
+
void addFillComponents( Container panel, int[] cols, int[] rows )
|
35
|
+
{
|
36
|
+
Dimension filler = new Dimension(10,10);
|
37
|
+
|
38
|
+
boolean filled_cell_11 = false;
|
39
|
+
CellConstraints cc = new CellConstraints();
|
40
|
+
if ( cols.length > 0 && rows.length > 0 )
|
41
|
+
{
|
42
|
+
if ( cols[0] == 1 && rows[0] == 1 )
|
43
|
+
{
|
44
|
+
/** add a rigid area */
|
45
|
+
panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
|
46
|
+
filled_cell_11 = true;
|
47
|
+
}
|
48
|
+
}
|
49
|
+
|
50
|
+
for( int index = 0; index < cols.length; index++ )
|
51
|
+
{
|
52
|
+
if ( cols[index] == 1 && filled_cell_11 )
|
53
|
+
{
|
54
|
+
continue;
|
55
|
+
}
|
56
|
+
panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
|
57
|
+
}
|
58
|
+
|
59
|
+
for( int index = 0; index < rows.length; index++ )
|
60
|
+
{
|
61
|
+
if ( rows[index] == 1 && filled_cell_11 )
|
62
|
+
{
|
63
|
+
continue;
|
64
|
+
}
|
65
|
+
panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
|
66
|
+
}
|
67
|
+
|
68
|
+
}
|
69
|
+
|
70
|
+
/**
|
71
|
+
* Helper method to load an image file from the CLASSPATH
|
72
|
+
* @param imageName the package and name of the file to load relative to the CLASSPATH
|
73
|
+
* @return an ImageIcon instance with the specified image file
|
74
|
+
* @throws IllegalArgumentException if the image resource cannot be loaded.
|
75
|
+
*/
|
76
|
+
public ImageIcon loadImage( String imageName )
|
77
|
+
{
|
78
|
+
try
|
79
|
+
{
|
80
|
+
ClassLoader classloader = getClass().getClassLoader();
|
81
|
+
java.net.URL url = classloader.getResource( imageName );
|
82
|
+
if ( url != null )
|
83
|
+
{
|
84
|
+
ImageIcon icon = new ImageIcon( url );
|
85
|
+
return icon;
|
86
|
+
}
|
87
|
+
}
|
88
|
+
catch( Exception e )
|
89
|
+
{
|
90
|
+
e.printStackTrace();
|
91
|
+
}
|
92
|
+
throw new IllegalArgumentException( "Unable to load image: " + imageName );
|
93
|
+
}
|
94
|
+
|
95
|
+
public JPanel createPanel()
|
96
|
+
{
|
97
|
+
JPanel jpanel1 = new JPanel();
|
98
|
+
FormLayout formlayout1 = new FormLayout("FILL:7DLU:NONE,RIGHT:MAX(65DLU;DEFAULT):NONE,FILL:3DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:7DLU:NONE","CENTER:9DLU:NONE,FILL:DEFAULT:GROW(1.0),CENTER:9DLU:NONE");
|
99
|
+
CellConstraints cc = new CellConstraints();
|
100
|
+
jpanel1.setLayout(formlayout1);
|
101
|
+
|
102
|
+
_envVarsTextArea.setName("envVarsTextArea");
|
103
|
+
JScrollPane jscrollpane1 = new JScrollPane();
|
104
|
+
jscrollpane1.setViewportView(_envVarsTextArea);
|
105
|
+
jscrollpane1.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
|
106
|
+
jscrollpane1.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
|
107
|
+
jpanel1.add(jscrollpane1,cc.xy(4,2));
|
108
|
+
|
109
|
+
_envVarsLabel.setName("envVarsLabel");
|
110
|
+
_envVarsLabel.setText(Messages.getString("setVariables"));
|
111
|
+
jpanel1.add(_envVarsLabel,new CellConstraints(2,2,1,1,CellConstraints.DEFAULT,CellConstraints.TOP));
|
112
|
+
|
113
|
+
addFillComponents(jpanel1,new int[]{ 1,2,3,4,5 },new int[]{ 1,2,3 });
|
114
|
+
return jpanel1;
|
115
|
+
}
|
116
|
+
|
117
|
+
/**
|
118
|
+
* Initializer
|
119
|
+
*/
|
120
|
+
protected void initializePanel()
|
121
|
+
{
|
122
|
+
setLayout(new BorderLayout());
|
123
|
+
add(createPanel(), BorderLayout.CENTER);
|
124
|
+
}
|
125
|
+
|
126
|
+
|
127
|
+
}
|
Binary file
|
@@ -0,0 +1,171 @@
|
|
1
|
+
package net.sf.launch4j.form;
|
2
|
+
|
3
|
+
import com.jeta.forms.components.separator.TitledSeparator;
|
4
|
+
import com.jgoodies.forms.layout.CellConstraints;
|
5
|
+
import com.jgoodies.forms.layout.FormLayout;
|
6
|
+
import java.awt.BorderLayout;
|
7
|
+
import java.awt.Container;
|
8
|
+
import java.awt.Dimension;
|
9
|
+
import javax.swing.Box;
|
10
|
+
import javax.swing.ButtonGroup;
|
11
|
+
import javax.swing.ImageIcon;
|
12
|
+
import javax.swing.JCheckBox;
|
13
|
+
import javax.swing.JLabel;
|
14
|
+
import javax.swing.JPanel;
|
15
|
+
import javax.swing.JRadioButton;
|
16
|
+
import javax.swing.JScrollPane;
|
17
|
+
import javax.swing.JTextArea;
|
18
|
+
|
19
|
+
public abstract class HeaderForm extends JPanel
|
20
|
+
{
|
21
|
+
protected final JLabel _headerTypeLabel = new JLabel();
|
22
|
+
protected final JRadioButton _guiHeaderRadio = new JRadioButton();
|
23
|
+
protected final ButtonGroup _headerButtonGroup = new ButtonGroup();
|
24
|
+
protected final JRadioButton _consoleHeaderRadio = new JRadioButton();
|
25
|
+
protected final JTextArea _headerObjectsTextArea = new JTextArea();
|
26
|
+
protected final JTextArea _libsTextArea = new JTextArea();
|
27
|
+
protected final JCheckBox _headerObjectsCheck = new JCheckBox();
|
28
|
+
protected final JCheckBox _libsCheck = new JCheckBox();
|
29
|
+
protected final TitledSeparator _linkerOptionsSeparator = new TitledSeparator();
|
30
|
+
|
31
|
+
/**
|
32
|
+
* Default constructor
|
33
|
+
*/
|
34
|
+
public HeaderForm()
|
35
|
+
{
|
36
|
+
initializePanel();
|
37
|
+
}
|
38
|
+
|
39
|
+
/**
|
40
|
+
* Adds fill components to empty cells in the first row and first column of the grid.
|
41
|
+
* This ensures that the grid spacing will be the same as shown in the designer.
|
42
|
+
* @param cols an array of column indices in the first row where fill components should be added.
|
43
|
+
* @param rows an array of row indices in the first column where fill components should be added.
|
44
|
+
*/
|
45
|
+
void addFillComponents( Container panel, int[] cols, int[] rows )
|
46
|
+
{
|
47
|
+
Dimension filler = new Dimension(10,10);
|
48
|
+
|
49
|
+
boolean filled_cell_11 = false;
|
50
|
+
CellConstraints cc = new CellConstraints();
|
51
|
+
if ( cols.length > 0 && rows.length > 0 )
|
52
|
+
{
|
53
|
+
if ( cols[0] == 1 && rows[0] == 1 )
|
54
|
+
{
|
55
|
+
/** add a rigid area */
|
56
|
+
panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
|
57
|
+
filled_cell_11 = true;
|
58
|
+
}
|
59
|
+
}
|
60
|
+
|
61
|
+
for( int index = 0; index < cols.length; index++ )
|
62
|
+
{
|
63
|
+
if ( cols[index] == 1 && filled_cell_11 )
|
64
|
+
{
|
65
|
+
continue;
|
66
|
+
}
|
67
|
+
panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
|
68
|
+
}
|
69
|
+
|
70
|
+
for( int index = 0; index < rows.length; index++ )
|
71
|
+
{
|
72
|
+
if ( rows[index] == 1 && filled_cell_11 )
|
73
|
+
{
|
74
|
+
continue;
|
75
|
+
}
|
76
|
+
panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
|
77
|
+
}
|
78
|
+
|
79
|
+
}
|
80
|
+
|
81
|
+
/**
|
82
|
+
* Helper method to load an image file from the CLASSPATH
|
83
|
+
* @param imageName the package and name of the file to load relative to the CLASSPATH
|
84
|
+
* @return an ImageIcon instance with the specified image file
|
85
|
+
* @throws IllegalArgumentException if the image resource cannot be loaded.
|
86
|
+
*/
|
87
|
+
public ImageIcon loadImage( String imageName )
|
88
|
+
{
|
89
|
+
try
|
90
|
+
{
|
91
|
+
ClassLoader classloader = getClass().getClassLoader();
|
92
|
+
java.net.URL url = classloader.getResource( imageName );
|
93
|
+
if ( url != null )
|
94
|
+
{
|
95
|
+
ImageIcon icon = new ImageIcon( url );
|
96
|
+
return icon;
|
97
|
+
}
|
98
|
+
}
|
99
|
+
catch( Exception e )
|
100
|
+
{
|
101
|
+
e.printStackTrace();
|
102
|
+
}
|
103
|
+
throw new IllegalArgumentException( "Unable to load image: " + imageName );
|
104
|
+
}
|
105
|
+
|
106
|
+
public JPanel createPanel()
|
107
|
+
{
|
108
|
+
JPanel jpanel1 = new JPanel();
|
109
|
+
FormLayout formlayout1 = new FormLayout("FILL:7DLU:NONE,RIGHT:MAX(65DLU;DEFAULT):NONE,FILL:3DLU:NONE,FILL:DEFAULT:NONE,FILL:7DLU:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0),FILL:7DLU:NONE","CENTER:9DLU:NONE,CENTER:DEFAULT:NONE,CENTER:9DLU:NONE,CENTER:DEFAULT:NONE,CENTER:3DLU:NONE,FILL:DEFAULT:GROW(0.2),CENTER:3DLU:NONE,FILL:DEFAULT:GROW(1.0),CENTER:9DLU:NONE");
|
110
|
+
CellConstraints cc = new CellConstraints();
|
111
|
+
jpanel1.setLayout(formlayout1);
|
112
|
+
|
113
|
+
_headerTypeLabel.setName("headerTypeLabel");
|
114
|
+
_headerTypeLabel.setText(Messages.getString("headerType"));
|
115
|
+
jpanel1.add(_headerTypeLabel,cc.xy(2,2));
|
116
|
+
|
117
|
+
_guiHeaderRadio.setActionCommand("GUI");
|
118
|
+
_guiHeaderRadio.setName("guiHeaderRadio");
|
119
|
+
_guiHeaderRadio.setText(Messages.getString("gui"));
|
120
|
+
_headerButtonGroup.add(_guiHeaderRadio);
|
121
|
+
jpanel1.add(_guiHeaderRadio,cc.xy(4,2));
|
122
|
+
|
123
|
+
_consoleHeaderRadio.setActionCommand("Console");
|
124
|
+
_consoleHeaderRadio.setName("consoleHeaderRadio");
|
125
|
+
_consoleHeaderRadio.setText(Messages.getString("console"));
|
126
|
+
_headerButtonGroup.add(_consoleHeaderRadio);
|
127
|
+
jpanel1.add(_consoleHeaderRadio,cc.xy(6,2));
|
128
|
+
|
129
|
+
_headerObjectsTextArea.setName("headerObjectsTextArea");
|
130
|
+
JScrollPane jscrollpane1 = new JScrollPane();
|
131
|
+
jscrollpane1.setViewportView(_headerObjectsTextArea);
|
132
|
+
jscrollpane1.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
|
133
|
+
jscrollpane1.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
|
134
|
+
jpanel1.add(jscrollpane1,cc.xywh(4,6,4,1));
|
135
|
+
|
136
|
+
_libsTextArea.setName("libsTextArea");
|
137
|
+
JScrollPane jscrollpane2 = new JScrollPane();
|
138
|
+
jscrollpane2.setViewportView(_libsTextArea);
|
139
|
+
jscrollpane2.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
|
140
|
+
jscrollpane2.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
|
141
|
+
jpanel1.add(jscrollpane2,cc.xywh(4,8,4,1));
|
142
|
+
|
143
|
+
_headerObjectsCheck.setActionCommand("Object files");
|
144
|
+
_headerObjectsCheck.setName("headerObjectsCheck");
|
145
|
+
_headerObjectsCheck.setText(Messages.getString("objectFiles"));
|
146
|
+
jpanel1.add(_headerObjectsCheck,new CellConstraints(2,6,1,1,CellConstraints.DEFAULT,CellConstraints.TOP));
|
147
|
+
|
148
|
+
_libsCheck.setActionCommand("w32api");
|
149
|
+
_libsCheck.setName("libsCheck");
|
150
|
+
_libsCheck.setText(Messages.getString("libs"));
|
151
|
+
jpanel1.add(_libsCheck,new CellConstraints(2,8,1,1,CellConstraints.DEFAULT,CellConstraints.TOP));
|
152
|
+
|
153
|
+
_linkerOptionsSeparator.setName("linkerOptionsSeparator");
|
154
|
+
_linkerOptionsSeparator.setText(Messages.getString("linkerOptions"));
|
155
|
+
jpanel1.add(_linkerOptionsSeparator,cc.xywh(2,4,6,1));
|
156
|
+
|
157
|
+
addFillComponents(jpanel1,new int[]{ 1,2,3,4,5,6,7,8 },new int[]{ 1,2,3,4,5,6,7,8,9 });
|
158
|
+
return jpanel1;
|
159
|
+
}
|
160
|
+
|
161
|
+
/**
|
162
|
+
* Initializer
|
163
|
+
*/
|
164
|
+
protected void initializePanel()
|
165
|
+
{
|
166
|
+
setLayout(new BorderLayout());
|
167
|
+
add(createPanel(), BorderLayout.CENTER);
|
168
|
+
}
|
169
|
+
|
170
|
+
|
171
|
+
}
|
Binary file
|
@@ -0,0 +1,266 @@
|
|
1
|
+
package net.sf.launch4j.form;
|
2
|
+
|
3
|
+
import com.jgoodies.forms.layout.CellConstraints;
|
4
|
+
import com.jgoodies.forms.layout.FormLayout;
|
5
|
+
import java.awt.BorderLayout;
|
6
|
+
import java.awt.Container;
|
7
|
+
import java.awt.Dimension;
|
8
|
+
import javax.swing.Box;
|
9
|
+
import javax.swing.ImageIcon;
|
10
|
+
import javax.swing.JButton;
|
11
|
+
import javax.swing.JComboBox;
|
12
|
+
import javax.swing.JLabel;
|
13
|
+
import javax.swing.JPanel;
|
14
|
+
import javax.swing.JScrollPane;
|
15
|
+
import javax.swing.JTextArea;
|
16
|
+
import javax.swing.JTextField;
|
17
|
+
|
18
|
+
public abstract class JreForm extends JPanel
|
19
|
+
{
|
20
|
+
protected final JLabel _jrePathLabel = new JLabel();
|
21
|
+
protected final JLabel _jreMinLabel = new JLabel();
|
22
|
+
protected final JLabel _jreMaxLabel = new JLabel();
|
23
|
+
protected final JLabel _jvmOptionsTextLabel = new JLabel();
|
24
|
+
protected final JTextField _jrePathField = new JTextField();
|
25
|
+
protected final JTextField _jreMinField = new JTextField();
|
26
|
+
protected final JTextField _jreMaxField = new JTextField();
|
27
|
+
protected final JTextArea _jvmOptionsTextArea = new JTextArea();
|
28
|
+
protected final JLabel _initialHeapSizeLabel = new JLabel();
|
29
|
+
protected final JLabel _maxHeapSizeLabel = new JLabel();
|
30
|
+
protected final JTextField _initialHeapSizeField = new JTextField();
|
31
|
+
protected final JTextField _maxHeapSizeField = new JTextField();
|
32
|
+
protected final JComboBox _varCombo = new JComboBox();
|
33
|
+
protected final JButton _propertyButton = new JButton();
|
34
|
+
protected final JButton _optionButton = new JButton();
|
35
|
+
protected final JButton _envPropertyButton = new JButton();
|
36
|
+
protected final JButton _envOptionButton = new JButton();
|
37
|
+
protected final JTextField _envVarField = new JTextField();
|
38
|
+
protected final JTextField _maxHeapPercentField = new JTextField();
|
39
|
+
protected final JTextField _initialHeapPercentField = new JTextField();
|
40
|
+
protected final JComboBox _jdkPreferenceCombo = new JComboBox();
|
41
|
+
|
42
|
+
/**
|
43
|
+
* Default constructor
|
44
|
+
*/
|
45
|
+
public JreForm()
|
46
|
+
{
|
47
|
+
initializePanel();
|
48
|
+
}
|
49
|
+
|
50
|
+
/**
|
51
|
+
* Adds fill components to empty cells in the first row and first column of the grid.
|
52
|
+
* This ensures that the grid spacing will be the same as shown in the designer.
|
53
|
+
* @param cols an array of column indices in the first row where fill components should be added.
|
54
|
+
* @param rows an array of row indices in the first column where fill components should be added.
|
55
|
+
*/
|
56
|
+
void addFillComponents( Container panel, int[] cols, int[] rows )
|
57
|
+
{
|
58
|
+
Dimension filler = new Dimension(10,10);
|
59
|
+
|
60
|
+
boolean filled_cell_11 = false;
|
61
|
+
CellConstraints cc = new CellConstraints();
|
62
|
+
if ( cols.length > 0 && rows.length > 0 )
|
63
|
+
{
|
64
|
+
if ( cols[0] == 1 && rows[0] == 1 )
|
65
|
+
{
|
66
|
+
/** add a rigid area */
|
67
|
+
panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
|
68
|
+
filled_cell_11 = true;
|
69
|
+
}
|
70
|
+
}
|
71
|
+
|
72
|
+
for( int index = 0; index < cols.length; index++ )
|
73
|
+
{
|
74
|
+
if ( cols[index] == 1 && filled_cell_11 )
|
75
|
+
{
|
76
|
+
continue;
|
77
|
+
}
|
78
|
+
panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
|
79
|
+
}
|
80
|
+
|
81
|
+
for( int index = 0; index < rows.length; index++ )
|
82
|
+
{
|
83
|
+
if ( rows[index] == 1 && filled_cell_11 )
|
84
|
+
{
|
85
|
+
continue;
|
86
|
+
}
|
87
|
+
panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
|
88
|
+
}
|
89
|
+
|
90
|
+
}
|
91
|
+
|
92
|
+
/**
|
93
|
+
* Helper method to load an image file from the CLASSPATH
|
94
|
+
* @param imageName the package and name of the file to load relative to the CLASSPATH
|
95
|
+
* @return an ImageIcon instance with the specified image file
|
96
|
+
* @throws IllegalArgumentException if the image resource cannot be loaded.
|
97
|
+
*/
|
98
|
+
public ImageIcon loadImage( String imageName )
|
99
|
+
{
|
100
|
+
try
|
101
|
+
{
|
102
|
+
ClassLoader classloader = getClass().getClassLoader();
|
103
|
+
java.net.URL url = classloader.getResource( imageName );
|
104
|
+
if ( url != null )
|
105
|
+
{
|
106
|
+
ImageIcon icon = new ImageIcon( url );
|
107
|
+
return icon;
|
108
|
+
}
|
109
|
+
}
|
110
|
+
catch( Exception e )
|
111
|
+
{
|
112
|
+
e.printStackTrace();
|
113
|
+
}
|
114
|
+
throw new IllegalArgumentException( "Unable to load image: " + imageName );
|
115
|
+
}
|
116
|
+
|
117
|
+
public JPanel createPanel()
|
118
|
+
{
|
119
|
+
JPanel jpanel1 = new JPanel();
|
120
|
+
FormLayout formlayout1 = new FormLayout("FILL:7DLU:NONE,RIGHT:MAX(65DLU;DEFAULT):NONE,FILL:3DLU:NONE,FILL:60DLU:NONE,FILL:3DLU:NONE,FILL:DEFAULT:NONE,FILL:7DLU:NONE,FILL:60DLU:NONE,FILL:3DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:7DLU:NONE","CENTER:9DLU:NONE,CENTER:DEFAULT:NONE,CENTER:3DLU:NONE,CENTER:DEFAULT:NONE,CENTER:3DLU:NONE,CENTER:DEFAULT:NONE,CENTER:3DLU:NONE,CENTER:DEFAULT:NONE,CENTER:3DLU:NONE,CENTER:DEFAULT:NONE,CENTER:3DLU:NONE,FILL:50DLU:GROW(1.0),CENTER:3DLU:NONE,CENTER:DEFAULT:NONE,CENTER:9DLU:NONE");
|
121
|
+
CellConstraints cc = new CellConstraints();
|
122
|
+
jpanel1.setLayout(formlayout1);
|
123
|
+
|
124
|
+
_jrePathLabel.setName("jrePathLabel");
|
125
|
+
_jrePathLabel.setText(Messages.getString("jrePath"));
|
126
|
+
jpanel1.add(_jrePathLabel,cc.xy(2,2));
|
127
|
+
|
128
|
+
_jreMinLabel.setName("jreMinLabel");
|
129
|
+
_jreMinLabel.setText(Messages.getString("jreMin"));
|
130
|
+
jpanel1.add(_jreMinLabel,cc.xy(2,4));
|
131
|
+
|
132
|
+
_jreMaxLabel.setName("jreMaxLabel");
|
133
|
+
_jreMaxLabel.setText(Messages.getString("jreMax"));
|
134
|
+
jpanel1.add(_jreMaxLabel,cc.xy(2,6));
|
135
|
+
|
136
|
+
_jvmOptionsTextLabel.setName("jvmOptionsTextLabel");
|
137
|
+
_jvmOptionsTextLabel.setText(Messages.getString("jvmOptions"));
|
138
|
+
jpanel1.add(_jvmOptionsTextLabel,new CellConstraints(2,12,1,1,CellConstraints.DEFAULT,CellConstraints.TOP));
|
139
|
+
|
140
|
+
_jrePathField.setName("jrePathField");
|
141
|
+
_jrePathField.setToolTipText(Messages.getString("jrePathTip"));
|
142
|
+
jpanel1.add(_jrePathField,cc.xywh(4,2,7,1));
|
143
|
+
|
144
|
+
_jreMinField.setName("jreMinField");
|
145
|
+
jpanel1.add(_jreMinField,cc.xy(4,4));
|
146
|
+
|
147
|
+
_jreMaxField.setName("jreMaxField");
|
148
|
+
jpanel1.add(_jreMaxField,cc.xy(4,6));
|
149
|
+
|
150
|
+
_jvmOptionsTextArea.setName("jvmOptionsTextArea");
|
151
|
+
_jvmOptionsTextArea.setToolTipText(Messages.getString("jvmOptionsTip"));
|
152
|
+
JScrollPane jscrollpane1 = new JScrollPane();
|
153
|
+
jscrollpane1.setViewportView(_jvmOptionsTextArea);
|
154
|
+
jscrollpane1.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
|
155
|
+
jscrollpane1.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
|
156
|
+
jpanel1.add(jscrollpane1,cc.xywh(4,12,7,1));
|
157
|
+
|
158
|
+
_initialHeapSizeLabel.setName("initialHeapSizeLabel");
|
159
|
+
_initialHeapSizeLabel.setText(Messages.getString("initialHeapSize"));
|
160
|
+
jpanel1.add(_initialHeapSizeLabel,cc.xy(2,8));
|
161
|
+
|
162
|
+
_maxHeapSizeLabel.setName("maxHeapSizeLabel");
|
163
|
+
_maxHeapSizeLabel.setText(Messages.getString("maxHeapSize"));
|
164
|
+
jpanel1.add(_maxHeapSizeLabel,cc.xy(2,10));
|
165
|
+
|
166
|
+
JLabel jlabel1 = new JLabel();
|
167
|
+
jlabel1.setText("MB");
|
168
|
+
jpanel1.add(jlabel1,cc.xy(6,8));
|
169
|
+
|
170
|
+
JLabel jlabel2 = new JLabel();
|
171
|
+
jlabel2.setText("MB");
|
172
|
+
jpanel1.add(jlabel2,cc.xy(6,10));
|
173
|
+
|
174
|
+
_initialHeapSizeField.setName("initialHeapSizeField");
|
175
|
+
jpanel1.add(_initialHeapSizeField,cc.xy(4,8));
|
176
|
+
|
177
|
+
_maxHeapSizeField.setName("maxHeapSizeField");
|
178
|
+
jpanel1.add(_maxHeapSizeField,cc.xy(4,10));
|
179
|
+
|
180
|
+
jpanel1.add(createPanel1(),cc.xywh(2,14,9,1));
|
181
|
+
_maxHeapPercentField.setName("maxHeapPercentField");
|
182
|
+
jpanel1.add(_maxHeapPercentField,cc.xy(8,10));
|
183
|
+
|
184
|
+
_initialHeapPercentField.setName("initialHeapPercentField");
|
185
|
+
jpanel1.add(_initialHeapPercentField,cc.xy(8,8));
|
186
|
+
|
187
|
+
_jdkPreferenceCombo.setName("jdkPreferenceCombo");
|
188
|
+
jpanel1.add(_jdkPreferenceCombo,cc.xywh(8,4,3,1));
|
189
|
+
|
190
|
+
JLabel jlabel3 = new JLabel();
|
191
|
+
jlabel3.setText(Messages.getString("freeMemory"));
|
192
|
+
jpanel1.add(jlabel3,cc.xy(10,8));
|
193
|
+
|
194
|
+
JLabel jlabel4 = new JLabel();
|
195
|
+
jlabel4.setText(Messages.getString("freeMemory"));
|
196
|
+
jpanel1.add(jlabel4,cc.xy(10,10));
|
197
|
+
|
198
|
+
addFillComponents(jpanel1,new int[]{ 1,2,3,4,5,6,7,8,9,10,11 },new int[]{ 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15 });
|
199
|
+
return jpanel1;
|
200
|
+
}
|
201
|
+
|
202
|
+
public JPanel createPanel1()
|
203
|
+
{
|
204
|
+
JPanel jpanel1 = new JPanel();
|
205
|
+
FormLayout formlayout1 = new FormLayout("RIGHT:MAX(65DLU;DEFAULT):NONE,FILL:3DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:3DLU:NONE,FILL:DEFAULT:NONE,FILL:3DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE,CENTER:3DLU:NONE,CENTER:DEFAULT:NONE");
|
206
|
+
CellConstraints cc = new CellConstraints();
|
207
|
+
jpanel1.setLayout(formlayout1);
|
208
|
+
|
209
|
+
_varCombo.setName("varCombo");
|
210
|
+
jpanel1.add(_varCombo,cc.xy(3,1));
|
211
|
+
|
212
|
+
_propertyButton.setActionCommand("Add");
|
213
|
+
_propertyButton.setIcon(loadImage("images/edit_add16.png"));
|
214
|
+
_propertyButton.setName("propertyButton");
|
215
|
+
_propertyButton.setText(Messages.getString("property"));
|
216
|
+
_propertyButton.setToolTipText(Messages.getString("propertyTip"));
|
217
|
+
jpanel1.add(_propertyButton,cc.xy(5,1));
|
218
|
+
|
219
|
+
_optionButton.setActionCommand("Add");
|
220
|
+
_optionButton.setIcon(loadImage("images/edit_add16.png"));
|
221
|
+
_optionButton.setName("optionButton");
|
222
|
+
_optionButton.setText(Messages.getString("option"));
|
223
|
+
_optionButton.setToolTipText(Messages.getString("optionTip"));
|
224
|
+
jpanel1.add(_optionButton,cc.xy(7,1));
|
225
|
+
|
226
|
+
_envPropertyButton.setActionCommand("Add");
|
227
|
+
_envPropertyButton.setIcon(loadImage("images/edit_add16.png"));
|
228
|
+
_envPropertyButton.setName("envPropertyButton");
|
229
|
+
_envPropertyButton.setText(Messages.getString("property"));
|
230
|
+
_envPropertyButton.setToolTipText(Messages.getString("propertyTip"));
|
231
|
+
jpanel1.add(_envPropertyButton,cc.xy(5,3));
|
232
|
+
|
233
|
+
JLabel jlabel1 = new JLabel();
|
234
|
+
jlabel1.setText(Messages.getString("varsAndRegistry"));
|
235
|
+
jpanel1.add(jlabel1,cc.xy(1,1));
|
236
|
+
|
237
|
+
JLabel jlabel2 = new JLabel();
|
238
|
+
jlabel2.setIcon(loadImage("images/asterix.gif"));
|
239
|
+
jlabel2.setText(Messages.getString("envVar"));
|
240
|
+
jpanel1.add(jlabel2,cc.xy(1,3));
|
241
|
+
|
242
|
+
_envOptionButton.setActionCommand("Add");
|
243
|
+
_envOptionButton.setIcon(loadImage("images/edit_add16.png"));
|
244
|
+
_envOptionButton.setName("envOptionButton");
|
245
|
+
_envOptionButton.setText(Messages.getString("option"));
|
246
|
+
_envOptionButton.setToolTipText(Messages.getString("optionTip"));
|
247
|
+
jpanel1.add(_envOptionButton,cc.xy(7,3));
|
248
|
+
|
249
|
+
_envVarField.setName("envVarField");
|
250
|
+
jpanel1.add(_envVarField,cc.xy(3,3));
|
251
|
+
|
252
|
+
addFillComponents(jpanel1,new int[]{ 2,4,6 },new int[]{ 2 });
|
253
|
+
return jpanel1;
|
254
|
+
}
|
255
|
+
|
256
|
+
/**
|
257
|
+
* Initializer
|
258
|
+
*/
|
259
|
+
protected void initializePanel()
|
260
|
+
{
|
261
|
+
setLayout(new BorderLayout());
|
262
|
+
add(createPanel(), BorderLayout.CENTER);
|
263
|
+
}
|
264
|
+
|
265
|
+
|
266
|
+
}
|
Binary file
|
@@ -0,0 +1,55 @@
|
|
1
|
+
/*
|
2
|
+
Launch4j (http://launch4j.sourceforge.net/)
|
3
|
+
Cross-platform Java application wrapper for creating Windows native executables.
|
4
|
+
|
5
|
+
Copyright (c) 2004, 2007 Grzegorz Kowal
|
6
|
+
|
7
|
+
All rights reserved.
|
8
|
+
|
9
|
+
Redistribution and use in source and binary forms, with or without modification,
|
10
|
+
are permitted provided that the following conditions are met:
|
11
|
+
|
12
|
+
* Redistributions of source code must retain the above copyright notice,
|
13
|
+
this list of conditions and the following disclaimer.
|
14
|
+
* Redistributions in binary form must reproduce the above copyright notice,
|
15
|
+
this list of conditions and the following disclaimer in the documentation
|
16
|
+
and/or other materials provided with the distribution.
|
17
|
+
* Neither the name of the Launch4j nor the names of its contributors
|
18
|
+
may be used to endorse or promote products derived from this software without
|
19
|
+
specific prior written permission.
|
20
|
+
|
21
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
22
|
+
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
23
|
+
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
24
|
+
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
|
25
|
+
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
26
|
+
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
27
|
+
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
28
|
+
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
29
|
+
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
30
|
+
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
31
|
+
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
32
|
+
*/
|
33
|
+
|
34
|
+
package net.sf.launch4j.form;
|
35
|
+
|
36
|
+
import java.util.MissingResourceException;
|
37
|
+
import java.util.ResourceBundle;
|
38
|
+
|
39
|
+
class Messages {
|
40
|
+
private static final String BUNDLE_NAME = "net.sf.launch4j.form.messages";
|
41
|
+
|
42
|
+
private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
|
43
|
+
.getBundle(BUNDLE_NAME);
|
44
|
+
|
45
|
+
private Messages() {
|
46
|
+
}
|
47
|
+
|
48
|
+
public static String getString(String key) {
|
49
|
+
try {
|
50
|
+
return RESOURCE_BUNDLE.getString(key);
|
51
|
+
} catch (MissingResourceException e) {
|
52
|
+
return '!' + key + '!';
|
53
|
+
}
|
54
|
+
}
|
55
|
+
}
|