diff options
author | Marco Pesenti Gritti <mpg@redhat.com> | 2007-10-16 15:18:43 (GMT) |
---|---|---|
committer | Marco Pesenti Gritti <mpg@redhat.com> | 2007-10-16 15:18:43 (GMT) |
commit | 40fc6e2e47b956eabc34d8b772c066d8f8f0d530 (patch) | |
tree | 5dd559f6b9dbd16ddbbd3e0bbcfe1e8b05853020 /lib | |
parent | 05236c66702b4d674123a50061c553ae9e11d589 (diff) |
Simplify the API to get icon/description for objects.
Get rid of the service for now, it's not necessary
until we allow activities to extend the
mime type -> generic type mapping (post 1.0)
Diffstat (limited to 'lib')
-rw-r--r-- | lib/sugar/Makefile.am | 2 | ||||
-rw-r--r-- | lib/sugar/graphics/objectchooser.py | 5 |
2 files changed, 2 insertions, 5 deletions
diff --git a/lib/sugar/Makefile.am b/lib/sugar/Makefile.am index 8c1946d..3446830 100644 --- a/lib/sugar/Makefile.am +++ b/lib/sugar/Makefile.am @@ -1,4 +1,4 @@ -SUBDIRS = activity bundle clipboard graphics objects presence datastore +SUBDIRS = activity bundle clipboard graphics presence datastore sugardir = $(pythondir)/sugar sugar_PYTHON = \ diff --git a/lib/sugar/graphics/objectchooser.py b/lib/sugar/graphics/objectchooser.py index 114665f..7522a9d 100644 --- a/lib/sugar/graphics/objectchooser.py +++ b/lib/sugar/graphics/objectchooser.py @@ -148,10 +148,7 @@ class CollapsedEntry(CanvasRoundBox): mime_type = self.jobject.metadata['mime_type'] if not self._icon_name and mime_type: - type = objecttype.get_registry().get_type_for_mime(mime_type) - if type: - self._icon_name = type.icon - + self._icon_name = mime.get_mime_icon(mime_type) if not self._icon_name: self._icon_name = 'image-missing' |