From 5ed9b8db5193b3564c1f5baa4cb191526b74a83e Mon Sep 17 00:00:00 2001 From: Don Allingham Date: Mon, 3 Jan 2005 19:43:22 +0000 Subject: [PATCH] * src/DateHandler.py: Don't force English parser if problem with config value, but LANG is set properly svn: r3863 --- gramps2/ChangeLog | 2 ++ gramps2/src/DateHandler.py | 8 ++++++-- gramps2/src/Plugins.py | 11 ----------- 3 files changed, 8 insertions(+), 13 deletions(-) diff --git a/gramps2/ChangeLog b/gramps2/ChangeLog index d365cd932..aa740b419 100644 --- a/gramps2/ChangeLog +++ b/gramps2/ChangeLog @@ -2,6 +2,8 @@ * src/GrampsDbBase.py: move all thumbnail creation here to have a common thumbnail scheme. * src/GrampsInMemDB.py: remove thumbnail handling, use base class + * src/DateHandler.py: Don't force English parser if problem with + config value, but LANG is set properly 2005-01-02 Alex Roitman * src/Report.py: Add support for a semi-common 'dispf'. diff --git a/gramps2/src/DateHandler.py b/gramps2/src/DateHandler.py index 144cb443d..15f9f27ff 100644 --- a/gramps2/src/DateHandler.py +++ b/gramps2/src/DateHandler.py @@ -37,7 +37,6 @@ import locale # GRAMPS modules # #------------------------------------------------------------------------- -import GrampsGconfKeys import DateParser import DateDisplay @@ -124,9 +123,14 @@ except: parser = DateParser.DateParser() try: + import GrampsGconfKeys val = GrampsGconfKeys.get_date_format(_lang_to_display[_lang].formats) +except: + val = 0 + +try: displayer = _lang_to_display[_lang](val) except: print "Date displayer for",_lang,"not available, using default" - displayer = DateDisplay.DateDisplay(3) + displayer = DateDisplay.DateDisplay(val) diff --git a/gramps2/src/Plugins.py b/gramps2/src/Plugins.py index df78999a1..1fea33c4d 100644 --- a/gramps2/src/Plugins.py +++ b/gramps2/src/Plugins.py @@ -96,17 +96,6 @@ _relcalc_class = Relationship.RelationshipCalculator #------------------------------------------------------------------------- _unavailable = _("No description was provided"), -#------------------------------------------------------------------------- -# -# Constants -# -#------------------------------------------------------------------------- -DOCSTRING = "d" -IMAGE = "i" -TASK = "f" -TITLE = "t" -STATUS = "s" - #------------------------------------------------------------------------- # # PluginDialog interface class