#18 Eliminate initial delay
authorKevin Lamonte <kevin.lamonte@gmail.com>
Tue, 15 Aug 2017 19:56:51 +0000 (15:56 -0400)
committerKevin Lamonte <kevin.lamonte@gmail.com>
Tue, 15 Aug 2017 19:56:51 +0000 (15:56 -0400)
src/jexer/TApplication.java

index c0166b11c3daf492e7e5afc04ff0af4a0a2ca5a6..09f617ed82fd45a259ce62410d1d35e82641cf03 100644 (file)
@@ -931,10 +931,16 @@ public class TApplication implements Runnable {
      * Run this application until it exits.
      */
     public void run() {
+        boolean first = true;
+
         while (!quit) {
             // Timeout is in milliseconds, so default timeout after 1 second
             // of inactivity.
             long timeout = 1000;
+            if (first) {
+                first = false;
+                timeout = 0;
+            }
 
             // If I've got no updates to render, wait for something from the
             // backend or a timer.