From 26ba860fc33e4d3cff9af87e7cd88167df12d4d9 Mon Sep 17 00:00:00 2001 From: Don Allingham Date: Thu, 16 Jun 2005 04:08:42 +0000 Subject: [PATCH] * src/DisplayModels.py: fixed event type display svn: r4832 --- ChangeLog | 1 + src/DisplayModels.py | 9 ++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index bc10d0359..b4a57636c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,5 @@ 2005-06-15 Don Allingham + * src/DisplayModels.py: fixed event type display * src/ReadXML.py: build child/family relationships properly on import, add missing event descriptions * src/RelLib.py: type checking for set_role relationship types diff --git a/src/DisplayModels.py b/src/DisplayModels.py index 062827e1a..131224773 100644 --- a/src/DisplayModels.py +++ b/src/DisplayModels.py @@ -538,7 +538,14 @@ class EventModel(BaseModel): return u'' def column_type(self,data): - return unicode(data[2][1]) + (code,val) = data[2] + if code == RelLib.Event.CUSTOM: + return unicode(val) + else: + val = Utils.personal_events.get(code) + if not val: + val = Utils.family_events.get(code,_("Unknown")) + return val def column_id(self,data): return unicode(data[1])