From d1e4016769582e4a43fc67419c66d3ea5b0da1ba Mon Sep 17 00:00:00 2001 From: Paul Franklin Date: Mon, 21 Oct 2013 19:52:35 +0000 Subject: [PATCH] 7092: API for reporting issues ["interim" solution, from Nick Hall] svn: r23360 --- src/config.py | 1 + src/plugins/view/geography.gpr.py | 9 ++++++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/config.py b/src/config.py index c2afc7833..f57c79b55 100644 --- a/src/config.py +++ b/src/config.py @@ -210,6 +210,7 @@ register('interface.filter-editor-width', 400) register('interface.filter-editor-height', 350) register('interface.fullscreen', False) register('interface.height', 500) +register('interface.ignore-osmgpsmap', False) register('interface.lds-height', 450) register('interface.lds-width', 600) register('interface.location-height', 250) diff --git a/src/plugins/view/geography.gpr.py b/src/plugins/view/geography.gpr.py index bd12b2aef..325b69a50 100644 --- a/src/plugins/view/geography.gpr.py +++ b/src/plugins/view/geography.gpr.py @@ -38,9 +38,12 @@ try : osmgpsmap.__version__) except: OSMGPSMAP = False - import logging - logging.warning(_("WARNING: osmgpsmap module not loaded. " - "Geography functionality will not be available.")) + import config + if not config.get('interface.ignore-osmgpsmap'): + from QuestionDialog import MessageHideDialog + title = _("OsmGpsMap module not loaded.") + message = _("Geography functionality will not be available.") + MessageHideDialog(title, message, 'interface.ignore-osmgpsmap') if OSMGPSMAP: # Load the view only if osmgpsmap library is present.