aboutsummaryrefslogtreecommitdiffstats
path: root/src/redshift-gtk/controller.py
diff options
context:
space:
mode:
authorJon Lund Steffensen <jonlst@gmail.com>2017-07-30 20:16:50 -0700
committerJon Lund Steffensen <jonlst@gmail.com>2017-07-30 20:21:52 -0700
commit7e9886cd68be7c9a5ebb47eef93253bb006814b0 (patch)
tree0b9c1c206c37e9eda1fb766b12d9f28df6c499ee /src/redshift-gtk/controller.py
parentutils: Make xdg module optional (diff)
downloadredshift-ng-7e9886cd68be7c9a5ebb47eef93253bb006814b0.tar.gz
redshift-ng-7e9886cd68be7c9a5ebb47eef93253bb006814b0.tar.bz2
redshift-ng-7e9886cd68be7c9a5ebb47eef93253bb006814b0.tar.xz
controller: Emit signal when stopped
Diffstat (limited to 'src/redshift-gtk/controller.py')
-rw-r--r--src/redshift-gtk/controller.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/redshift-gtk/controller.py b/src/redshift-gtk/controller.py
index a1591c8..24c58ae 100644
--- a/src/redshift-gtk/controller.py
+++ b/src/redshift-gtk/controller.py
@@ -37,8 +37,9 @@ class RedshiftController(GObject.GObject):
'temperature-changed': (GObject.SIGNAL_RUN_FIRST, None, (int,)),
'period-changed': (GObject.SIGNAL_RUN_FIRST, None, (str,)),
'location-changed': (GObject.SIGNAL_RUN_FIRST, None, (float, float)),
- 'error-occured': (GObject.SIGNAL_RUN_FIRST, None, (str,))
- }
+ 'error-occured': (GObject.SIGNAL_RUN_FIRST, None, (str,)),
+ 'stopped': (GObject.SIGNAL_RUN_FIRST, None, ()),
+ }
def __init__(self, args):
"""Initialize controller and start child process.
@@ -159,6 +160,7 @@ class RedshiftController(GObject.GObject):
self.emit('error-occured', self._errors)
GLib.spawn_close_pid(self._process[0])
+ self.emit('stopped')
def _child_key_change_cb(self, key, value):
"""Called when the child process reports a change of internal state."""