Fixed size issue and application icon
committer: Jonathan Bernard <jdbernard@gmail.com>
This commit is contained in:
parent
ceebe27075
commit
b47ab393c6
@ -1,2 +1,2 @@
|
|||||||
jaxws.endorsed.dir=/usr/local/netbeans-6.1/java2/modules/ext/jaxws21/api
|
jaxws.endorsed.dir=C:\\Program Files\\NetBeans 6.1\\java2\\modules\\ext\\jaxws21\\api
|
||||||
user.properties.file=/home/jdbernard/.netbeans/6.1/build.properties
|
user.properties.file=C:\\Documents and Settings\\jbernard\\.netbeans\\6.1\\build.properties
|
||||||
|
@ -30,6 +30,7 @@ public class NotesDialog extends JDialog implements MouseMotionListener {
|
|||||||
thinNotesFont = notesTextArea.getFont().deriveFont(Font.PLAIN);
|
thinNotesFont = notesTextArea.getFont().deriveFont(Font.PLAIN);
|
||||||
boldNotesFont = notesTextArea.getFont().deriveFont(Font.BOLD);
|
boldNotesFont = notesTextArea.getFont().deriveFont(Font.BOLD);
|
||||||
|
|
||||||
|
setLocationRelativeTo(parent.getFrame());
|
||||||
this.parent = parent;
|
this.parent = parent;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -88,7 +88,7 @@ implements Application.ExitListener {
|
|||||||
*/
|
*/
|
||||||
@Override protected void startup() {
|
@Override protected void startup() {
|
||||||
show(new TimeStamperView(this));
|
show(new TimeStamperView(this));
|
||||||
getMainFrame().setSize(350, 60);
|
getMainFrame().setSize(300, 60);
|
||||||
getApplication().addExitListener(this);
|
getApplication().addExitListener(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -22,33 +22,27 @@
|
|||||||
<DimensionLayout dim="0">
|
<DimensionLayout dim="0">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" attributes="0">
|
<Group type="102" attributes="0">
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace min="-2" max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="1" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<Component id="totalTimeNow" min="-2" max="-2" attributes="0"/>
|
<Component id="totalTimeNow" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace pref="12" max="32767" attributes="0"/>
|
<EmptySpace pref="29" max="32767" attributes="0"/>
|
||||||
<Component id="currentTimeLabel" min="-2" max="-2" attributes="0"/>
|
<Component id="currentTimeLabel" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<Component id="taskTextField" alignment="0" pref="229" max="32767" attributes="1"/>
|
<Group type="102" alignment="1" attributes="0">
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<Component id="currentTaskLabel" min="-2" max="-2" attributes="1"/>
|
<Component id="currentTaskLabel" min="-2" max="-2" attributes="1"/>
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
<Component id="startTimeLabel" min="-2" max="-2" attributes="1"/>
|
<Component id="startTimeLabel" pref="87" max="32767" attributes="1"/>
|
||||||
</Group>
|
</Group>
|
||||||
|
<Component id="taskTextField" alignment="0" pref="246" max="32767" attributes="1"/>
|
||||||
</Group>
|
</Group>
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<EmptySpace min="-2" max="-2" attributes="0"/>
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="103" groupAlignment="1" attributes="0">
|
||||||
<EmptySpace pref="109" max="32767" attributes="0"/>
|
<Component id="optionsButton" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="optionsButton" min="-2" max="-2" attributes="0"/>
|
<Component id="notesButton" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace min="-2" pref="0" max="-2" attributes="0"/>
|
|
||||||
<Component id="exitButton" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Component id="notesButton" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="0" max="-2" attributes="0"/>
|
||||||
|
<Component id="exitButton" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
@ -58,26 +52,24 @@
|
|||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Component id="exitButton" alignment="0" min="-2" pref="16" max="-2" attributes="0"/>
|
<Component id="exitButton" alignment="0" min="-2" pref="16" max="-2" attributes="0"/>
|
||||||
<Component id="optionsButton" alignment="0" min="-2" max="-2" attributes="0"/>
|
<Component id="optionsButton" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="103" alignment="0" groupAlignment="3" attributes="0">
|
||||||
<Group type="103" groupAlignment="1" attributes="0">
|
<Component id="currentTaskLabel" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="notesButton" alignment="1" min="-2" max="-2" attributes="0"/>
|
<Component id="startTimeLabel" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Group type="102" alignment="1" attributes="0">
|
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
|
||||||
<Component id="currentTaskLabel" alignment="3" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="startTimeLabel" alignment="3" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace min="-2" pref="0" max="-2" attributes="0"/>
|
|
||||||
<Component id="taskTextField" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace min="-2" pref="0" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
|
||||||
<Component id="currentTimeLabel" alignment="3" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="totalTimeNow" alignment="3" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace pref="31" max="32767" attributes="0"/>
|
<EmptySpace min="-2" pref="0" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Component id="taskTextField" min="-2" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace min="-2" pref="0" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
|
<Component id="totalTimeNow" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="currentTimeLabel" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
<Component id="notesButton" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="312" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
@ -256,6 +248,6 @@
|
|||||||
<AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
|
<AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
|
||||||
<AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
|
<AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
|
||||||
<AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
|
<AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
|
||||||
<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,0,91,0,0,1,-128"/>
|
<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,0,83,0,0,1,47"/>
|
||||||
</AuxValues>
|
</AuxValues>
|
||||||
</Form>
|
</Form>
|
||||||
|
@ -34,6 +34,9 @@ public class TimeStamperView extends FrameView implements MouseMotionListener {
|
|||||||
|
|
||||||
getFrame().setUndecorated(true);
|
getFrame().setUndecorated(true);
|
||||||
|
|
||||||
|
getFrame().setIconImage(resourceMap.getImageIcon("Application.icon")
|
||||||
|
.getImage());
|
||||||
|
|
||||||
fileChooser = new JFileChooser();
|
fileChooser = new JFileChooser();
|
||||||
notesDialog = new NotesDialog(this, false);
|
notesDialog = new NotesDialog(this, false);
|
||||||
|
|
||||||
@ -193,25 +196,21 @@ public class TimeStamperView extends FrameView implements MouseMotionListener {
|
|||||||
.addGroup(mainPanelLayout.createSequentialGroup()
|
.addGroup(mainPanelLayout.createSequentialGroup()
|
||||||
.addContainerGap()
|
.addContainerGap()
|
||||||
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, mainPanelLayout.createSequentialGroup()
|
|
||||||
.addComponent(totalTimeNow)
|
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 12, Short.MAX_VALUE)
|
|
||||||
.addComponent(currentTimeLabel))
|
|
||||||
.addComponent(taskTextField, javax.swing.GroupLayout.DEFAULT_SIZE, 229, Short.MAX_VALUE)
|
|
||||||
.addGroup(mainPanelLayout.createSequentialGroup()
|
.addGroup(mainPanelLayout.createSequentialGroup()
|
||||||
|
.addComponent(totalTimeNow)
|
||||||
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 29, Short.MAX_VALUE)
|
||||||
|
.addComponent(currentTimeLabel))
|
||||||
|
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, mainPanelLayout.createSequentialGroup()
|
||||||
.addComponent(currentTaskLabel)
|
.addComponent(currentTaskLabel)
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||||
.addComponent(startTimeLabel)))
|
.addComponent(startTimeLabel, javax.swing.GroupLayout.DEFAULT_SIZE, 87, Short.MAX_VALUE))
|
||||||
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
.addComponent(taskTextField, javax.swing.GroupLayout.DEFAULT_SIZE, 246, Short.MAX_VALUE))
|
||||||
.addGroup(mainPanelLayout.createSequentialGroup()
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 109, Short.MAX_VALUE)
|
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
|
||||||
.addComponent(optionsButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(optionsButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addGap(0, 0, 0)
|
.addComponent(notesButton))
|
||||||
.addComponent(exitButton))
|
.addGap(0, 0, 0)
|
||||||
.addGroup(mainPanelLayout.createSequentialGroup()
|
.addComponent(exitButton))
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
|
||||||
.addComponent(notesButton)
|
|
||||||
.addContainerGap())))
|
|
||||||
);
|
);
|
||||||
mainPanelLayout.setVerticalGroup(
|
mainPanelLayout.setVerticalGroup(
|
||||||
mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
@ -219,20 +218,19 @@ public class TimeStamperView extends FrameView implements MouseMotionListener {
|
|||||||
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
.addComponent(exitButton, javax.swing.GroupLayout.PREFERRED_SIZE, 16, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(exitButton, javax.swing.GroupLayout.PREFERRED_SIZE, 16, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addComponent(optionsButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(optionsButton, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
|
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||||
|
.addComponent(currentTaskLabel)
|
||||||
|
.addComponent(startTimeLabel)))
|
||||||
|
.addGap(0, 0, 0)
|
||||||
|
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
.addGroup(mainPanelLayout.createSequentialGroup()
|
.addGroup(mainPanelLayout.createSequentialGroup()
|
||||||
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
|
.addComponent(taskTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addComponent(notesButton)
|
|
||||||
.addGroup(mainPanelLayout.createSequentialGroup()
|
|
||||||
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
|
||||||
.addComponent(currentTaskLabel)
|
|
||||||
.addComponent(startTimeLabel))
|
|
||||||
.addGap(0, 0, 0)
|
|
||||||
.addComponent(taskTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
|
|
||||||
.addGap(0, 0, 0)
|
.addGap(0, 0, 0)
|
||||||
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
.addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||||
.addComponent(currentTimeLabel)
|
.addComponent(totalTimeNow)
|
||||||
.addComponent(totalTimeNow))))
|
.addComponent(currentTimeLabel)))
|
||||||
.addContainerGap(31, Short.MAX_VALUE))
|
.addComponent(notesButton))
|
||||||
|
.addGap(312, 312, 312))
|
||||||
);
|
);
|
||||||
|
|
||||||
optionsMenu.setName("optionsMenu"); // NOI18N
|
optionsMenu.setName("optionsMenu"); // NOI18N
|
||||||
|
@ -9,6 +9,7 @@ Application.description = A simple Java desktop application based on Swing Appli
|
|||||||
Application.vendorId = Sun
|
Application.vendorId = Sun
|
||||||
Application.id = ${Application.name}
|
Application.id = ${Application.name}
|
||||||
Application.lookAndFeel = system
|
Application.lookAndFeel = system
|
||||||
|
Application.icon=/jdbernard/timestamper/resources/icons/appointment-new-16x16.png
|
||||||
quit.Action.text=Exit
|
quit.Action.text=Exit
|
||||||
quit.Action.accelerator=ctrl pressed Q
|
quit.Action.accelerator=ctrl pressed Q
|
||||||
quit.Action.smallIcon=/jdbernard/timestamper/resources/icons/16-em-cross.png
|
quit.Action.smallIcon=/jdbernard/timestamper/resources/icons/16-em-cross.png
|
||||||
|
BIN
src/jdbernard/timestamper/resources/icons/appointment-new-16x16.png
Executable file
BIN
src/jdbernard/timestamper/resources/icons/appointment-new-16x16.png
Executable file
Binary file not shown.
After Width: | Height: | Size: 897 B |
Loading…
x
Reference in New Issue
Block a user