about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2013-01-05 01:14:18 +0000
committerJames Booth <boothj5@gmail.com>2013-01-05 01:14:18 +0000
commit7ae7b01e1568676a748d93a5e60da36f531927b4 (patch)
treee9b28d2dd0c862b4a228f78873625e243e72044a
parentb84051701daab555f1987fee9519ddabc3b2d32e (diff)
parent7ee113e68779a708612b77d0631c1dcfd06abb50 (diff)
downloadprofani-tty-7ae7b01e1568676a748d93a5e60da36f531927b4.tar.gz
Merge remote-tracking branch 'dmitry/next'
Conflicts:
	src/windows.c
-rw-r--r--src/windows.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/src/windows.c b/src/windows.c
index f709231f..d8017e2b 100644
--- a/src/windows.c
+++ b/src/windows.c
@@ -208,21 +208,12 @@ ui_get_idle_time(void)
         unsigned long result = info->idle;
         XFree(info);
         return result;
-
-    // if we couldn't get a screensaverinfo, use profanity interaction idle time
-    // this may occur if compiled with libxss, but then run in a bare terminal
-    } else {
-        gdouble seconds_elapsed = g_timer_elapsed(ui_idle_time, NULL);
-        unsigned long ms_elapsed = seconds_elapsed * 1000.0;
-        return ms_elapsed;
     }
-
-// if not compiled with libxss, just use profanity interaction idle time
-#else
+// if no libxss or xss idle time failed, use profanity idle time
+#endif
     gdouble seconds_elapsed = g_timer_elapsed(ui_idle_time, NULL);
     unsigned long ms_elapsed = seconds_elapsed * 1000.0;
     return ms_elapsed;
-#endif
 }
 
 void