notification-hub

distraction-free notification daemon for simple linux desktops.
git clone https://git.ce9e.org/notification-hub.git

commit
08ae1688ed1384549c65444db6c26b7fee28bf17
parent
21f75f7b3388d2da09537518df53d1d7b45f8f33
Author
Tobias Bengfort <tobias.bengfort@posteo.de>
Date
2020-08-12 06:14
fix linter warnings

Diffstat

M notification_hub.py 11 ++++++-----

1 files changed, 6 insertions, 5 deletions


diff --git a/notification_hub.py b/notification_hub.py

@@ -9,9 +9,9 @@ import gi
    9     9 
   10    10 gi.require_version('AyatanaAppIndicator3', '0.1')
   11    11 
   12    -1 from gi.repository import Gio
   13    -1 from gi.repository import GLib
   14    -1 from gi.repository import AyatanaAppIndicator3 as AppIndicator3
   -1    12 from gi.repository import Gio  # noqa
   -1    13 from gi.repository import GLib  # noqa
   -1    14 from gi.repository import AyatanaAppIndicator3 as AppIndicator3  # noqa
   15    15 
   16    16 VERSION = '0.0.0'
   17    17 
@@ -59,13 +59,14 @@ next_id = 1
   59    59 indicator = None
   60    60 
   61    61 
   62    -1 def on_call(conn, sender, path, interface, method, parameters, invocation, user_data=None):
   -1    62 def on_call(
   -1    63     conn, sender, path, interface, method, params, invocation, user_data=None
   -1    64 ):
   63    65     global next_id
   64    66     if method == 'GetCapabilities':
   65    67         # announce fake capabilities to avoid firefox fallback
   66    68         reply = GLib.Variant('(as)', [['actions', 'body', 'body-hyperlinks']])
   67    69     elif method == 'Notify':
   68    -1         print(sender, parameters)
   69    70         indicator.set_status(AppIndicator3.IndicatorStatus.ATTENTION)
   70    71         reply = GLib.Variant('(u)', [next_id])
   71    72         next_id += 1