From d001bd8252c999b4439e0d4fb2f2611f7f0dcd64 Mon Sep 17 00:00:00 2001 From: hansonr Date: Wed, 7 Aug 2019 19:34:13 -0500 Subject: [PATCH] Platform.timeCheck - just resetting duration for reset/set-mark..set-mark/get sequence. --- src/jalview/util/Platform.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/jalview/util/Platform.java b/src/jalview/util/Platform.java index 6d95747..fba669b 100644 --- a/src/jalview/util/Platform.java +++ b/src/jalview/util/Platform.java @@ -276,6 +276,8 @@ public class Platform * * Platform.timeCheck("some message", Platform.TIME_MARK); * + * reset...[set/mark]n...get + * * @param msg * @param mode */ @@ -286,6 +288,7 @@ public class Platform { case TIME_RESET: time = mark = t; + duration = 0; if (msg != null) { System.err.println("Platform: timer reset\t\t\t" + msg); @@ -294,6 +297,7 @@ public class Platform case TIME_MARK: if (set > 0) { + // total time between set/mark points duration += (t - set); } else @@ -316,7 +320,7 @@ public class Platform case TIME_GET: if (msg != null) { - System.err.println("Platform: timer dur\t" + ((t - time) / 1000f) + System.err.println("Platform: timer get\t" + ((t - time) / 1000f) + "\t" + ((duration) / 1000f) + "\t" + msg); } set = 0; -- 1.7.10.2