diff options
author | Gonzalo Odiard <godiard@gmail.com> | 2012-02-20 06:57:22 (GMT) |
---|---|---|
committer | Gonzalo Odiard <godiard@gmail.com> | 2012-02-20 06:57:22 (GMT) |
commit | 4e492b3e697d853ff529afd44f48ee17822c55f1 (patch) | |
tree | 637a295b6ad9d45e0939345dc49db49c2686311b /resources.py | |
parent | 00304e296a01eb6d38b8bc4caf9d9b25ddc9d6e2 (diff) |
Fix load of images in resources
Diffstat (limited to 'resources.py')
-rw-r--r-- | resources.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/resources.py b/resources.py index 9f3e918..e97ffd6 100644 --- a/resources.py +++ b/resources.py @@ -6,6 +6,8 @@ import os import shutil from gettext import gettext as _ + +from sugar.activity import activity from sugar.graphics.icon import Icon from sugar.graphics.objectchooser import ObjectChooser @@ -120,6 +122,8 @@ class CollectResourcesWin(gtk.HBox): self.size_label_value.set_text('%s x %s px' % (width, height)) # copy to resources directory self.model.check_resources_directory() + resource_path = os.path.join(activity.get_activity_root(), + 'instance', 'resources') shutil.copy(file_path, resource_path) self._image_resource_path = os.path.join(resource_path, os.path.basename(file_path)) |