Tried JNLP, not workingas expected, so diabled. Artifacts remain.
Bug fixes committer: Jonathan Bernard <jdbernard@gmail.com>
This commit is contained in:
@ -15,6 +15,7 @@ import java.util.logging.FileHandler;
|
||||
import java.util.logging.Handler;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
import java.util.logging.SimpleFormatter;
|
||||
import org.jdesktop.application.Application;
|
||||
import org.jdesktop.application.SingleFrameApplication;
|
||||
|
||||
@ -44,6 +45,7 @@ implements Application.ExitListener {
|
||||
|
||||
try {
|
||||
FileHandler fh = new FileHandler("TimeStamper.log", true);
|
||||
fh.setFormatter(new SimpleFormatter());
|
||||
fh.setLevel(Level.ALL);
|
||||
} catch (IOException ioe) {
|
||||
log.warning("Could not open log file for writing. Switching console"
|
||||
@ -141,7 +143,7 @@ implements Application.ExitListener {
|
||||
|
||||
try {
|
||||
activeTimeline = Timeline.readFromFile(filename);
|
||||
// TODO: re-init gui for new timeline
|
||||
currentTimelineFile = filename;
|
||||
} catch (IOException ioe) {
|
||||
log.warning("Could not load from the file: " +
|
||||
ioe.getLocalizedMessage());
|
||||
|
@ -26,15 +26,15 @@
|
||||
<Group type="103" groupAlignment="0" attributes="0">
|
||||
<Group type="102" alignment="0" attributes="0">
|
||||
<Component id="totalTimeNow" min="-2" max="-2" attributes="0"/>
|
||||
<EmptySpace pref="23" max="32767" attributes="0"/>
|
||||
<EmptySpace pref="58" max="32767" attributes="0"/>
|
||||
<Component id="currentTimeLabel" min="-2" max="-2" attributes="0"/>
|
||||
</Group>
|
||||
<Group type="102" alignment="1" attributes="0">
|
||||
<Component id="currentTaskLabel" min="-2" max="-2" attributes="1"/>
|
||||
<EmptySpace max="-2" attributes="0"/>
|
||||
<Component id="startTimeLabel" pref="95" max="32767" attributes="1"/>
|
||||
<Component id="startTimeLabel" pref="116" max="32767" attributes="1"/>
|
||||
</Group>
|
||||
<Component id="taskTextField" alignment="0" pref="266" max="32767" attributes="1"/>
|
||||
<Component id="taskTextField" alignment="0" pref="275" max="32767" attributes="1"/>
|
||||
</Group>
|
||||
<EmptySpace min="-2" max="-2" attributes="0"/>
|
||||
<Group type="103" groupAlignment="1" attributes="0">
|
||||
|
@ -19,6 +19,7 @@ import org.jdesktop.application.Action;
|
||||
import org.jdesktop.application.ResourceMap;
|
||||
import org.jdesktop.application.SingleFrameApplication;
|
||||
import org.jdesktop.application.FrameView;
|
||||
import sun.security.jca.GetInstance;
|
||||
|
||||
/**
|
||||
* The application's main frame.
|
||||
@ -72,16 +73,7 @@ public class TimeStamperView extends FrameView implements MouseMotionListener {
|
||||
boldTaskFont = thinTaskFont.deriveFont(Font.BOLD);
|
||||
|
||||
// refresh new timeline
|
||||
Timeline t = ((TimeStamperApp) getApplication()).getActiveTimeline();
|
||||
Timeline.TimelineMarker lastMarker = t.getLastMarker(new Date());
|
||||
|
||||
if (lastMarker != null) {
|
||||
mostRecentTask = lastMarker.getTimestamp();
|
||||
startTimeLabel.setText(Timeline.shortFormat.format(lastMarker.getTimestamp()));
|
||||
|
||||
taskTextField.setText(lastMarker.getMark());
|
||||
notesDialog.setNotes(lastMarker.getNotes());
|
||||
}
|
||||
refreshDialog();
|
||||
}
|
||||
|
||||
/** This method is called from within the constructor to
|
||||
@ -401,7 +393,10 @@ public class TimeStamperView extends FrameView implements MouseMotionListener {
|
||||
((TimeStamperApp) getApplication()).loadTimeline(
|
||||
fileChooser.getSelectedFile().getAbsolutePath());
|
||||
|
||||
// refresh new timeline
|
||||
refreshDialog();
|
||||
}
|
||||
|
||||
public void refreshDialog() {
|
||||
Timeline t = ((TimeStamperApp) getApplication()).getActiveTimeline();
|
||||
Timeline.TimelineMarker lastMarker = t.getLastMarker(new Date());
|
||||
|
||||
|
@ -2,12 +2,12 @@
|
||||
|
||||
Application.name = TimeStamper
|
||||
Application.title = TimeStamper
|
||||
Application.version = 1.3
|
||||
Application.version = 1.4
|
||||
Application.vendor = Jonathan Bernard
|
||||
Application.homepage =
|
||||
Application.description = A simple Java desktop application based on Swing Application Framework.
|
||||
Application.vendorId = Sun
|
||||
Application.id = ${Application.name}
|
||||
Application.description = Simple application used to track activities throughout time.
|
||||
Application.vendorId = Jonathan Bernard
|
||||
Application.id = TimeStamper
|
||||
Application.lookAndFeel = system
|
||||
Application.icon=/jdbernard/timestamper/resources/icons/appointment-new-16x16.png
|
||||
quit.Action.text=Exit
|
||||
|
Reference in New Issue
Block a user