diff --git a/po/POTFILES.in b/po/POTFILES.in index 5517e0cb7..09afb2779 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in @@ -4,7 +4,6 @@ # src/const.py src/gramps.py -src/LdsUtils.py src/TransUtils.py src/Utils.py @@ -325,6 +324,7 @@ src/gen/simple/_simpletable.py # gen.utils src/gen/utils/alive.py +src/gen/utils/lds.py src/gen/utils/place.py # gui - GUI code diff --git a/src/Makefile.am b/src/Makefile.am index d0463a8c3..18ddfc40c 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -15,7 +15,6 @@ gdirdir=$(prefix)/share/gramps gdir_PYTHON = \ const.py\ gramps.py\ - LdsUtils.py \ MacTransUtils.py\ TransUtils.py\ Utils.py diff --git a/src/gen/utils/Makefile.am b/src/gen/utils/Makefile.am index 2368247c8..e109784cf 100644 --- a/src/gen/utils/Makefile.am +++ b/src/gen/utils/Makefile.am @@ -14,6 +14,7 @@ pkgpython_PYTHON = \ configmanager.py \ fallback.py \ image.py \ + lds.py \ place.py \ referent.py diff --git a/src/LdsUtils.py b/src/gen/utils/lds.py similarity index 100% rename from src/LdsUtils.py rename to src/gen/utils/lds.py diff --git a/src/gui/editors/displaytabs/ldsmodel.py b/src/gui/editors/displaytabs/ldsmodel.py index d8d31abf4..1c353a28b 100644 --- a/src/gui/editors/displaytabs/ldsmodel.py +++ b/src/gui/editors/displaytabs/ldsmodel.py @@ -39,7 +39,7 @@ import gtk # #------------------------------------------------------------------------- import gen.datehandler -import LdsUtils +from gen.utils.lds import TEMPLES #------------------------------------------------------------------------- # @@ -59,7 +59,7 @@ class LdsModel(gtk.ListStore): lds_ord.type2str(), gen.datehandler.get_date(lds_ord), lds_ord.status2str(), - LdsUtils.TEMPLES.name(lds_ord.get_temple()), + TEMPLES.name(lds_ord.get_temple()), self.column_place(lds_ord), lds_ord, ]) diff --git a/src/gui/editors/editldsord.py b/src/gui/editors/editldsord.py index d1a325cb3..153e4891c 100644 --- a/src/gui/editors/editldsord.py +++ b/src/gui/editors/editldsord.py @@ -47,7 +47,7 @@ import gtk #------------------------------------------------------------------------- import gen.lib from gen.display.name import displayer as name_displayer -import LdsUtils +from gen.utils.lds import TEMPLES from gui.glade import Glade from editsecondary import EditSecondary from objectentries import PlaceEntry @@ -205,7 +205,7 @@ class EditLdsOrd(EditSecondary): self.top.get_object('temple'), self.obj.set_temple, self.obj.get_temple, - LdsUtils.TEMPLES.name_code_data(), + TEMPLES.name_code_data(), self.db.readonly) self.track_ref_for_deletion('temple_menu') @@ -391,7 +391,7 @@ class EditFamilyLdsOrd(EditSecondary): self.top.get_object('temple'), self.obj.set_temple, self.obj.get_temple, - LdsUtils.TEMPLES.name_code_data(), + TEMPLES.name_code_data(), self.db.readonly) self.track_ref_for_deletion('temple_menu') diff --git a/src/plugins/lib/libgedcom.py b/src/plugins/lib/libgedcom.py index 069300952..2c6bc64d9 100644 --- a/src/plugins/lib/libgedcom.py +++ b/src/plugins/lib/libgedcom.py @@ -118,7 +118,7 @@ import gen.lib from gen.db import DbTxn from gen.updatecallback import UpdateCallback import gen.mime -import LdsUtils +from gen.utils.lds import TEMPLES import Utils from gen.datehandler._dateparser import DateParser from gen.db.dbconst import EVENT_KEY @@ -7136,10 +7136,10 @@ class GedcomParser(UpdateCallback): def __extract_temple(self, line): def get_code(code): - if LdsUtils.TEMPLES.is_valid_code(code): + if TEMPLES.is_valid_code(code): return code - elif LdsUtils.TEMPLES.is_valid_name(code): - return LdsUtils.TEMPLES.code(code) + elif TEMPLES.is_valid_name(code): + return TEMPLES.code(code) code = get_code(line.data) if code: diff --git a/src/plugins/tool/testcasegenerator.py b/src/plugins/tool/testcasegenerator.py index a7bd48705..c0233e11c 100644 --- a/src/plugins/tool/testcasegenerator.py +++ b/src/plugins/tool/testcasegenerator.py @@ -54,7 +54,7 @@ import gen.mime from gui.plug import tool import Utils from gui.utils import ProgressMeter -import LdsUtils +from gen.utils.lds import TEMPLES from gen.db.dbconst import * import const @@ -1535,7 +1535,7 @@ class TestcaseGenerator(tool.BatchTool): if isinstance(o,gen.lib.LdsOrd): if randint(0,1) == 1: - o.set_temple( choice( LdsUtils.TEMPLES.name_code_data())[1]) + o.set_temple( choice(TEMPLES.name_code_data())[1]) if issubclass(o.__class__,gen.lib.ldsordbase.LdsOrdBase): while randint(0,1) == 1: