Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomeu Vizoso <tomeu@sugarlabs.org>2009-08-17 17:21:17 (GMT)
committer Tomeu Vizoso <tomeu@sugarlabs.org>2009-08-17 17:21:17 (GMT)
commit3f9761469c4b78f5d7d2a397f2e824f89e4c1215 (patch)
tree6cdd8995a1ecf5ddb65c0cc6122aa92d863b82d1
parenta8ecc1729fce707eb9bfef790f17855387016171 (diff)
Mention TempFilePath in the comment
-rw-r--r--src/sugar/graphics/icon.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/sugar/graphics/icon.py b/src/sugar/graphics/icon.py
index 2f48717..2790775 100644
--- a/src/sugar/graphics/icon.py
+++ b/src/sugar/graphics/icon.py
@@ -314,6 +314,9 @@ class Icon(gtk.Image):
def __init__(self, **kwargs):
self._buffer = _IconBuffer()
+ # HACK: need to keep a reference to the path so it doesn't get garbage
+ # collected while it's still used if it's a sugar.util.TempFilePath.
+ # See #1175
self._file = None
gobject.GObject.__init__(self, **kwargs)
@@ -325,8 +328,6 @@ class Icon(gtk.Image):
self._file = file_name
self._buffer.file_name = file_name
- # XXX we need to override file property to support auto_ptr objects
- # that used to represent temporaly unzipped icons from bundles, see #1175
file = gobject.property(type=object, setter=set_file, getter=get_file)
def _sync_image_properties(self):