diff --git a/hamster/__init__.py b/hamster/__init__.py index 42f5779..4f3a07d 100644 --- a/hamster/__init__.py +++ b/hamster/__init__.py @@ -1 +1 @@ -from hamster import HamsterIntegrationPlugin +from .hamster import HamsterIntegrationPlugin diff --git a/hamster/hamster.py b/hamster/hamster.py index 6e736ef..1920d52 100644 --- a/hamster/hamster.py +++ b/hamster/hamster.py @@ -2,7 +2,7 @@ import dbus import datetime as dt -import gobject +from gi.repository import GObject from common import gajim from common import ged from common import dbus_support @@ -13,7 +13,7 @@ from common.pep import ACTIVITIES HAMSTAER_INTERFACE = 'org.gnome.Hamster' SUBACTIVITIES = [] -subactivity_ = [ACTIVITIES[x].keys() for x in ACTIVITIES.keys()] +subactivity_ = [list(ACTIVITIES[x].keys()) for x in list(ACTIVITIES.keys())] for x in subactivity_ : SUBACTIVITIES = SUBACTIVITIES + x SUBACTIVITIES = set(SUBACTIVITIES) @@ -65,7 +65,7 @@ class HamsterIntegrationPlugin(GajimPlugin): if not facts: return if self.from_dbus_fact(facts[-1])['end_time']: - accounts = gajim.connections.keys() + accounts = list(gajim.connections.keys()) for account in accounts: if gajim.account_is_connected(account): connection = gajim.connections[account] @@ -106,4 +106,4 @@ class HamsterIntegrationPlugin(GajimPlugin): id = fact[0]) def on_signed_in(self, network_event): - gobject.timeout_add(5000,self.hamster_facts_changed) + GObject.timeout_add(5000,self.hamster_facts_changed) diff --git a/hamster/manifest.ini b/hamster/manifest.ini index 99c0fe3..d5bc30c 100644 --- a/hamster/manifest.ini +++ b/hamster/manifest.ini @@ -7,4 +7,4 @@ description: Integration with project hamster and http://projecthamster.wordpress.com/about/ authors: Denis Fomin homepage: http://trac-plugins.gajim.org/wiki/ -max_gajim_version: 0.15.9 +min_gajim_version: 0.15.10