Skip to content

Commit

Permalink
Change refresh time to 10s
Browse files Browse the repository at this point in the history
  • Loading branch information
pwegrzyn committed Jun 15, 2019
1 parent e8db8fc commit 1a2bcae
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public abstract class AbstractActivityTracker implements ActivityTracker {

AbstractActivityTracker(StateTransitionEvent.Type activeState, StateTransitionEvent.Type inactiveState, String fileName){
this.timer = new Timer(true);
this.refreshRateTickInSeconds = 1;
this.refreshRateTickInSeconds = 10;

this.activeState = activeState;
this.inactiveState = inactiveState;
Expand Down
5 changes: 2 additions & 3 deletions src/main/java/pl/edu/agh/io/jappka/app/App.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import javafx.collections.ObservableMap;
import javafx.stage.Stage;
import pl.edu.agh.io.jappka.activity.*;
import org.apache.commons.exec.OS;
import pl.edu.agh.io.jappka.presenter.AppGUI;

import java.util.*;
Expand All @@ -25,7 +24,7 @@ public static void main(String[] args) {
@Override
public void start(Stage primaryStage) {
try {
// TODO: find out why this now out-commented call below fucks our fatJar
// TODO: find out why this call fails in a jar
/*if (!OS.isFamilyWindows()) {
System.out.println("Inside if");
LOGGER.severe("Unsupported Operating System found!");
Expand Down Expand Up @@ -60,7 +59,7 @@ public void start(Stage primaryStage) {
public void run() {
gui.gatherData();
}
}, 0, 1000);
}, 0, 10000);
} catch (Exception e) {
LOGGER.log(Level.SEVERE, "Fatal error during runtime!", e);
System.exit(1);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import pl.edu.agh.io.jappka.Exceptions.InvalidEventException;
import pl.edu.agh.io.jappka.util.DateTimePicker;

import java.time.LocalDateTime;
import java.time.ZoneId;

public class AddOwnEventController {
Expand All @@ -26,6 +27,8 @@ public class AddOwnEventController {

public void initialize(AppController appController) {
this.appController = appController;
this.start.setDateTimeValue(LocalDateTime.now().minusHours(1));
this.end.setDateTimeValue(LocalDateTime.now());
}

public void setStage(Stage stage) {
Expand Down

0 comments on commit 1a2bcae

Please sign in to comment.