diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-05-16 18:43:26 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-05-16 18:48:31 +0200 |
commit | 7680d6d24de9b049dfe8f322bf97fec820734fb9 (patch) | |
tree | 9c3841509480af9374e93920903438e93b1d9068 /examples/x-window-focus | |
parent | do not toggle when dying (diff) | |
download | nightshift-7680d6d24de9b049dfe8f322bf97fec820734fb9.tar.gz nightshift-7680d6d24de9b049dfe8f322bf97fec820734fb9.tar.bz2 nightshift-7680d6d24de9b049dfe8f322bf97fec820734fb9.tar.xz |
m misc + add freeze/thaw
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to 'examples/x-window-focus')
-rw-r--r-- | examples/x-window-focus | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/examples/x-window-focus b/examples/x-window-focus index e08442e..9d341ff 100644 --- a/examples/x-window-focus +++ b/examples/x-window-focus @@ -29,6 +29,9 @@ import threading import Xlib.display +# TODO: cannot re-exec when this script is used +# TODO: does not wait with toggling of redshift is froozen + def x_window_focus_thread_function(proc): ''' @@ -95,7 +98,7 @@ def x_window_focus_thread_function(proc): should_be_disabled = True # Perhaps toggle - if red_running and (should_be_disabled == red_status) and not red_dying: + if red_running and (should_be_disabled == red_status) and (not red_dying) and (not red_froozen): if red_status or we_disabled: we_disabled = should_be_disabled proc.send_signal(signal.SIGUSR1) |