Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/src/sugar/graphics/icon.py
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <marco@localhost.localdomain>2008-05-24 10:34:46 (GMT)
committer Marco Pesenti Gritti <marco@localhost.localdomain>2008-05-24 10:34:46 (GMT)
commitf4bda5eb226073b9aa61161750aca9203a3c2bd8 (patch)
treec84c6876f453b4e9616eed34a59f194695095f97 /src/sugar/graphics/icon.py
parent6dcc35bc17717008c7d90d3430f670cd03e1c18d (diff)
Allow to attach the invoker to the widget after construction,
so that gproperties to constructor can be implemented correctly.
Diffstat (limited to 'src/sugar/graphics/icon.py')
-rw-r--r--src/sugar/graphics/icon.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/sugar/graphics/icon.py b/src/sugar/graphics/icon.py
index 35e8e43..eeb36a1 100644
--- a/src/sugar/graphics/icon.py
+++ b/src/sugar/graphics/icon.py
@@ -402,12 +402,14 @@ class CanvasIcon(hippo.CanvasBox, hippo.CanvasItem):
__gtype_name__ = 'CanvasIcon'
def __init__(self, **kwargs):
+ from sugar.graphics.palette import CanvasInvoker
+
self._buffer = _IconBuffer()
+ self._palette_invoker = CanvasInvoker()
hippo.CanvasBox.__init__(self, **kwargs)
- from sugar.graphics.palette import CanvasInvoker
- self._palette_invoker = CanvasInvoker(self)
+ self._palette_invoker.attach(self)
self.connect('destroy', self.__destroy_cb)