shithub: orca

Download patch

ref: 9b3e38abe903703af61840cbd05bcac58a6bd1c3
parent: d7caa20113040ee9e6612e9246c7520360158fb7
author: cancel <cancel@cancel.fm>
date: Fri Dec 21 01:24:04 EST 2018

Add much more strict ncurses timeout (temp)

--- a/tui_main.c
+++ b/tui_main.c
@@ -942,7 +942,7 @@
       do_play = true;
       break;
     }
-    if (secs_span - sdiff > ms_to_sec(2.0))
+    if (secs_span - sdiff > ms_to_sec(0.5))
       break;
   }
   if (do_play) {
@@ -1885,12 +1885,18 @@
         new_timeout = 0;
       } else if (secs_to_d < ms_to_sec(2.0)) {
         new_timeout = 0;
-      } else if (secs_to_d < ms_to_sec(10.0)) {
-        new_timeout = 2;
+      } else if (secs_to_d < ms_to_sec(7.0)) {
+        new_timeout = 0;
+      } else if (secs_to_d < ms_to_sec(15.0)) {
+        new_timeout = 0;
+      } else if (secs_to_d < ms_to_sec(25.0)) {
+        new_timeout = 1;
       } else if (secs_to_d < ms_to_sec(50.0)) {
-        new_timeout = 15;
-      } else {
         new_timeout = 20;
+      } else if (secs_to_d < ms_to_sec(100.0)) {
+        new_timeout = 40;
+      } else {
+        new_timeout = 50;
       }
       if (new_timeout != cur_timeout) {
         wtimeout(stdscr, new_timeout);