4530: Gedcom import looses custom family event description

svn: r16373
This commit is contained in:
Jérôme Rapinat 2011-01-13 10:45:37 +00:00
parent 62358e931b
commit 4f44f6f98f

View File

@ -2045,7 +2045,7 @@ class GedcomParser(UpdateCallback):
self.family_func = {
# +1 <<FAMILY_EVENT_STRUCTURE>> {0:M}
TOKEN_GEVENT : self.__family_std_event,
TOKEN_EVEN : self.__family_even,
TOKEN_EVEN : self.__fam_even,
# +1 HUSB @<XREF:INDI>@ {0:1}
TOKEN_HUSB : self.__family_husb,
# +1 WIFE @<XREF:INDI>@ {0:1}
@ -2733,6 +2733,17 @@ class GedcomParser(UpdateCallback):
self.event_parse_tbl, line.data)
state.person.add_event_ref(event_ref)
def __fam_even(self, line, state):
"""
@param line: The current line in GedLine format
@type line: GedLine
@param state: The current state
@type state: CurrentState
"""
event_ref = self.__build_family_event_pair(state, gen.lib.EventType.CUSTOM,
self.event_parse_tbl, line.data)
state.family.add_event_ref(event_ref)
def __skip_record(self, line, state):
"""
@param line: The current line in GedLine format