diff options
author | Marco Pesenti Gritti <mpg@redhat.com> | 2006-05-13 05:28:51 (GMT) |
---|---|---|
committer | Marco Pesenti Gritti <mpg@redhat.com> | 2006-05-13 05:28:51 (GMT) |
commit | a3d69ab879567f9c63378ca8341e719169e1391b (patch) | |
tree | 6507b14b8d6ac0d2c5b55d4695997416e207ccc7 /sugar/shell/activity.py | |
parent | 4479a14eea6fd9c6ebc3ac9ad63e06d4020340b9 (diff) |
pylintize!!!
Diffstat (limited to 'sugar/shell/activity.py')
-rw-r--r-- | sugar/shell/activity.py | 30 |
1 files changed, 13 insertions, 17 deletions
diff --git a/sugar/shell/activity.py b/sugar/shell/activity.py index 6f1f3fc..4678a9c 100644 --- a/sugar/shell/activity.py +++ b/sugar/shell/activity.py @@ -1,15 +1,11 @@ # -*- tab-width: 4; indent-tabs-mode: t -*- -import string - -import gc import dbus import dbus.service import dbus.glib -import gobject import pygtk pygtk.require('2.0') -import gtk,sys +import gtk class Activity(dbus.service.Object): @@ -36,21 +32,21 @@ class Activity(dbus.service.Object): "com.redhat.Sugar.Shell.ActivityContainer") self.__activity_id = self.__activity_container.add_activity("") - self.__object_path = "/com/redhat/Sugar/Shell/Activities/%d"%self.__activity_id + self.__object_path = "/com/redhat/Sugar/Shell/Activities/%d" % self.__activity_id - print "object_path = %s"%self.__object_path + print "object_path = %s" % self.__object_path self.__activity_object = dbus.Interface(self.__bus.get_object("com.redhat.Sugar.Shell", self.__object_path), \ "com.redhat.Sugar.Shell.ActivityHost") self.__window_id = self.__activity_object.get_host_xembed_id() - print "XEMBED window_id = %d"%self.__window_id + print "XEMBED window_id = %d" % self.__window_id self.__plug = gtk.Plug(self.__window_id) # Now let the Activity register a peer service so the Shell can poke it - self.__peer_service_name = "com.redhat.Sugar.Activity%d"%self.__activity_id - self.__peer_object_name = "/com/redhat/Sugar/Activity/%d"%self.__activity_id + self.__peer_service_name = "com.redhat.Sugar.Activity%d" % self.__activity_id + self.__peer_object_name = "/com/redhat/Sugar/Activity/%d" % self.__activity_id self.__service = dbus.service.BusName(self.__peer_service_name, bus=self.__bus) dbus.service.Object.__init__(self, self.__service, self.__peer_object_name) @@ -86,7 +82,7 @@ class Activity(dbus.service.Object): pixarray = [] pixstr = pixbuf.get_pixels(); for c in pixstr: - pixarray.append(c) + pixarray.append(c) self.__activity_object.set_tab_icon(pixarray, \ pixbuf.get_colorspace(), \ pixbuf.get_has_alpha(), \ @@ -163,16 +159,16 @@ class Activity(dbus.service.Object): # pure virtual methods def activity_on_connected_to_shell(self): - print "act %d: you need to override activity_on_connected_to_shell"%self.activity_get_id() + print "act %d: you need to override activity_on_connected_to_shell" % self.activity_get_id() def activity_on_disconnected_from_shell(self): - print "act %d: you need to override activity_on_disconnected_from_shell"%self.activity_get_id() - + print "act %d: you need to override activity_on_disconnected_from_shell" % self.activity_get_id() + def activity_on_close_from_user(self): - print "act %d: you need to override activity_on_close_from_user"%self.activity_get_id() + print "act %d: you need to override activity_on_close_from_user" % self.activity_get_id() def activity_on_lost_focus(self): - print "act %d: you need to override activity_on_lost_focus"%self.activity_get_id() + print "act %d: you need to override activity_on_lost_focus" % self.activity_get_id() def activity_on_got_focus(self): - print "act %d: you need to override activity_on_got_focus"%self.activity_get_id() + print "act %d: you need to override activity_on_got_focus" % self.activity_get_id() |