Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(4)  |  Call(2)  |  Derive(0)  |  Import(2)
Return True if a description for a mime type exists.

        def mime_type_is_defined(mime_type):
    """
    Return True if a description for a mime type exists.
    """
    return mime_type in _type_map
        


src/g/r/gramps-3.4.2/src/gramps.py   Gramps(Download)
sys.excepthook = exc_hook
 
from gen.mime import mime_type_is_defined
import TransUtils
#-------------------------------------------------------------------------
        return [(_("Error reading configuration"), str(msg))]
 
    if not mime_type_is_defined(const.APP_GRAMPS):
        error += [(_("Configuration error:"), 
                    _("A definition for the MIME-type %s could not "

src/g/r/gramps-HEAD/gramps/grampsapp.py   gramps(Download)
sys.excepthook = exc_hook
 
from gen.mime import mime_type_is_defined
from gen.utils.trans import LOCALEDOMAIN, LOCALEDIR, setup_windows_gettext
#-------------------------------------------------------------------------
        return [(_("Error reading configuration"), str(msg))]
 
    if not mime_type_is_defined(APP_GRAMPS):
        error += [(_("Configuration error:"), 
                    _("A definition for the MIME-type %s could not "