GNOME Bugzilla – Bug 143600
gnome.vfs.mime_get_icon() returns None, always
Last modified: 2004-12-22 21:47:04 UTC
using gnome-python-2.0.2 and latest CVS "gnome.vfs.mime_get_icon()" always returns "None" - - - Python 2.3.3 (#1, May 15 2004, 09:42:27) [GCC 3.2.2] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import gnome, gnome.vfs >>> uri = 'file:///home/jaramir/workLog' >>> mime = gnome.vfs.get_mime_type(uri) >>> print mime text/plain >>> icon = gnome.vfs.mime_get_icon(mime) >>> print icon None
Correct. But I can't find any bug in gnome-python, so the bug must be in gnome-vfs.
This API is deprecated now. It was possible that it returned NULL before too, so that case should have been handled by old code. The right API to use for this is gnome_icon_lookup atm. When we will have a libgnomevfsui library we could add a nicer/simpler api to do this to it.