MousePerspective: inform the user of errors

This simply connects the pieces: when a resync signal is emitted on the
device, we show the notification informing the user that something has
gone wrong.
This commit is contained in:
Jente Hidskes
2019-01-09 15:43:46 +01:00
committed by Peter Hutterer
parent 3b8f490b69
commit 08ea82b08b

View File

@@ -84,6 +84,7 @@ class MousePerspective(Gtk.Overlay):
def set_device(self, device):
self._device = device
capabilities = device.capabilities
device.connect("resync", lambda _: self._show_notification_error())
self.stack.foreach(Gtk.Widget.destroy)
if RatbagdDevice.CAP_RESOLUTION in capabilities: