7439: pre-load alert dialogs crash w/o DISPLAY
This commit is contained in:
@@ -27,6 +27,8 @@
|
||||
#
|
||||
#------------------------------------------------------------------------
|
||||
|
||||
from constfunc import has_display
|
||||
if has_display():
|
||||
try :
|
||||
import osmgpsmap
|
||||
OSMGPSMAP = True
|
||||
@@ -44,6 +46,8 @@ except:
|
||||
title = _("OsmGpsMap module not loaded.")
|
||||
message = _("Geography functionality will not be available.")
|
||||
MessageHideDialog(title, message, 'interface.ignore-osmgpsmap')
|
||||
else:
|
||||
OSMGPSMAP = False
|
||||
|
||||
if OSMGPSMAP:
|
||||
# Load the view only if osmgpsmap library is present.
|
||||
|
||||
Reference in New Issue
Block a user