From 9ef619a63a362d4ac65d7d94cc47690db347349a Mon Sep 17 00:00:00 2001 From: Tomeu Vizoso Date: Fri, 27 Mar 2009 12:14:42 +0100 Subject: [PATCH] Revert "Listen for map in Window instead of in Canvas (alsroot) #428" This reverts commit eaf7afcd9104a2e7280ab6d3d45ec45ebd313cad. --- src/sugar/activity/activity.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/sugar/activity/activity.py b/src/sugar/activity/activity.py index d2c97e87..702bd7cb 100644 --- a/src/sugar/activity/activity.py +++ b/src/sugar/activity/activity.py @@ -560,8 +560,6 @@ class Activity(Window, gtk.Container): # https://dev.laptop.org/ticket/3071 datastore.write(self._jobject) - self.connect('map', self.__map_cb) - def get_active(self): return self._active @@ -605,6 +603,7 @@ class Activity(Window, gtk.Container): One commonly used canvas is gtk.ScrolledWindow """ Window.set_canvas(self, canvas) + canvas.connect('map', self.__canvas_map_cb) def __session_quit_requested_cb(self, session): self._quit_requested = True @@ -617,7 +616,7 @@ class Activity(Window, gtk.Container): def __session_quit_cb(self, client): self._complete_close() - def __map_cb(self, canvas): + def __canvas_map_cb(self, canvas): if self._jobject and self._jobject.file_path: self.read_file(self._jobject.file_path)