diff --git a/src/Acquisition/FolderInputSystem.java b/src/Acquisition/FolderInputSystem.java index b8e80f37..c8c2d872 100644 --- a/src/Acquisition/FolderInputSystem.java +++ b/src/Acquisition/FolderInputSystem.java @@ -690,7 +690,7 @@ public class FolderInputSystem extends FileInputSystem implements PamSettings, D } if (currentFile < allFiles.size()) { // only restart if the file ended - not if it stopped - if (getStreamStatus() == STREAM_ENDED) { + if (getStreamStatus() == STREAM_ENDED && PamController.getInstance().isManualStop() == false) { // System.out.println(String.format("Start new file timer (file %d/%d)",currentFile+1,allFiles.size())); newFileTimer.start(); } diff --git a/src/Localiser/algorithms/timeDelayLocalisers/bearingLoc/PairBearingLocaliser.java b/src/Localiser/algorithms/timeDelayLocalisers/bearingLoc/PairBearingLocaliser.java index d6908eca..59c166fd 100644 --- a/src/Localiser/algorithms/timeDelayLocalisers/bearingLoc/PairBearingLocaliser.java +++ b/src/Localiser/algorithms/timeDelayLocalisers/bearingLoc/PairBearingLocaliser.java @@ -214,7 +214,7 @@ public class PairBearingLocaliser implements BearingLocaliser { private boolean resetArray(long timeMillis){ if (this.timeMillis!=timeMillis && currentArray.getHydrophoneLocator().isChangeable()){ - System.out.println("Reset PairBearingLocaliser"); +// System.out.println("Reset PairBearingLocaliser"); prepare(this.arrayElements, timeMillis, this.timingError); return true; } diff --git a/src/PamController/PamController.java b/src/PamController/PamController.java index 54f7735f..c52905fd 100644 --- a/src/PamController/PamController.java +++ b/src/PamController/PamController.java @@ -1099,7 +1099,8 @@ public class PamController implements PamControllerInterface, PamSettings { * later in the AWT event queue. */ public void startLater() { - SwingUtilities.invokeLater(new StartLater(true)); +// SwingUtilities.invokeLater(new StartLater(true)); + startLater(true); } public void startLater(boolean saveSettings) { @@ -1173,6 +1174,7 @@ public class PamController implements PamControllerInterface, PamSettings { @Override public void manualStop() { lastStartStopButton = BUTTON_STOP; + setManualStop(true); pamStop(); } @@ -1186,6 +1188,7 @@ public class PamController implements PamControllerInterface, PamSettings { @Override public boolean pamStart() { // Debug.println("PAMController: pamStart"); + setManualStop(false); return pamStart(true); }