diff --git a/gramps/gen/config.py b/gramps/gen/config.py index 11fe37a7e..01bc2e245 100644 --- a/gramps/gen/config.py +++ b/gramps/gen/config.py @@ -212,6 +212,8 @@ register('interface.filter-editor-height', 350) register('interface.fullscreen', False) register('interface.grampletbar-close', False) register('interface.height', 500) +register('interface.ignore-gexiv2', False) +register('interface.ignore-osmgpsmap', False) register('interface.lds-height', 450) register('interface.lds-width', 600) register('interface.location-height', 250) diff --git a/gramps/plugins/gramplet/gramplet.gpr.py b/gramps/plugins/gramplet/gramplet.gpr.py index 5fa61143f..5a0648e54 100644 --- a/gramps/plugins/gramplet/gramplet.gpr.py +++ b/gramps/plugins/gramplet/gramplet.gpr.py @@ -405,13 +405,16 @@ if available: navtypes=["Media"], ) else: - import logging - logging.warning(_("GExiv2 module not loaded. Image metadata " - "functionality will not be available.\n" - "To build it for Gramps see " - "http://www.gramps-project.org/wiki/index.php?" - "title=GEPS_029:_GTK3-GObject_introspection" - "_Conversion#GExiv2_for_Image_metadata")) + from gramps.gen.config import config + from gramps.gui.dialog import MessageHideDialog + if not config.get('interface.ignore-gexiv2'): + title = _("GExiv2 module not loaded.") + message = _("Image metadata functionality will not be available.\n" + "To build it for Gramps see " + "http://www.gramps-project.org/wiki/index.php?" + "title=GEPS_029:_GTK3-GObject_introspection" + "_Conversion#GExiv2_for_Image_metadata") + MessageHideDialog(title, message, 'interface.ignore-gexiv2') register(GRAMPLET, id="Person Residence", diff --git a/gramps/plugins/view/geography.gpr.py b/gramps/plugins/view/geography.gpr.py index 890d60a54..7c47bb600 100644 --- a/gramps/plugins/view/geography.gpr.py +++ b/gramps/plugins/view/geography.gpr.py @@ -58,12 +58,16 @@ if repository.enumerate_versions("OsmGpsMap"): pass if not OSMGPSMAP: - _LOG.warning(_("OsmGpsMap module not loaded. " - "Geography functionality will not be available.\n" + from gramps.gen.config import config + from gramps.gui.dialog import MessageHideDialog + if not config.get('interface.ignore-osmgpsmap'): + title = _("OsmGpsMap module not loaded.") + message = _("Geography functionality will not be available.\n" "To build it for Gramps see " "http://www.gramps-project.org/wiki/index.php?" "title=GEPS_029:_GTK3-GObject_introspection_Conversion" - "#OsmGpsMap_for_Geography")) + "#OsmGpsMap_for_Geography") + MessageHideDialog(title, message, 'interface.ignore-osmgpsmap') else: # Load the view only if osmgpsmap library is present. register(VIEW,