From 3163157219f3ce4fe6c183ccb4838a7182b212c8 Mon Sep 17 00:00:00 2001 From: tmolitor Date: Fri, 8 Apr 2016 02:17:54 +0200 Subject: [PATCH] Corrected usage of GObject get_data and set_data methods (see https://bugzilla.gnome.org/show_bug.cgi?id=641944) --- src/notify.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/notify.py b/src/notify.py index 42d91d8d8..9efcbf050 100644 --- a/src/notify.py +++ b/src/notify.py @@ -120,10 +120,10 @@ text=None, timeout=-1): notification.set_timeout(timeout*1000) notification.set_category(event_type) - notification.set_data('event_type', event_type) - notification.set_data('jid', jid) - notification.set_data('account', account) - notification.set_data('msg_type', msg_type) + notification._data.event_type = event_type + notification._data.jid = jid + notification._data.account = account + notification._data.msg_type = msg_type notification.set_property('icon-name', path_to_image) if 'actions' in Notify.get_server_caps(): notification.add_action('default', 'Default Action', @@ -142,9 +142,9 @@ text=None, timeout=-1): gajim.interface.roster.popup_notification_windows.append(instance) def on_pynotify_notification_clicked(notification, action): - jid = notification.get_data('jid') - account = notification.get_data('account') - msg_type = notification.get_data('msg_type') + jid = notification._data.jid + account = notification._data.account + msg_type = notification._data.msg_type notification.close() gajim.interface.handle_event(account, jid, msg_type)