2006-12-04 Don Allingham <don@gramps-project.org>
* src/GrampsDb/_ReadGedcom.py: Handle notes with the way that Legacy can produce Place/Address combinations svn: r7757
This commit is contained in:
parent
01ebb7e67a
commit
3ca02c31ef
@ -1,3 +1,7 @@
|
||||
2006-12-04 Don Allingham <don@gramps-project.org>
|
||||
* src/GrampsDb/_ReadGedcom.py: Handle notes with the way that
|
||||
Legacy can produce Place/Address combinations
|
||||
|
||||
2006-12-03 Don Allingham <don@gramps-project.org>
|
||||
* src/DataViews/_RelationView.py: improve tooltips
|
||||
* src/GrampsWidgets.py: tooltip support
|
||||
|
@ -1523,6 +1523,16 @@ class GedcomParser(UpdateCallback):
|
||||
task(note)
|
||||
return note
|
||||
|
||||
def parse_note_simple(self, matches, level):
|
||||
# reference to a named note defined elsewhere
|
||||
if matches[2] and matches[2][0] == "@":
|
||||
note_obj = self.note_map.get(matches[2])
|
||||
note = note_obj.get()
|
||||
else:
|
||||
note = matches[2]
|
||||
self.ignore_sub_junk(level+1)
|
||||
return note
|
||||
|
||||
def parse_note(self,matches,obj,level,old_note):
|
||||
return self.parse_note_base(matches,obj,level,old_note,obj.set_note)
|
||||
|
||||
@ -1772,7 +1782,7 @@ class GedcomParser(UpdateCallback):
|
||||
location.set_country(matches[2])
|
||||
added = True
|
||||
elif matches[1] == TOKEN_NOTE:
|
||||
note = self.parse_note(matches,location,level+1,'')
|
||||
note = self.parse_note_simple(matches, level+1)
|
||||
added = True
|
||||
elif matches[1] in (TOKEN__LOC, TOKEN__NAME, TOKEN_PHON):
|
||||
pass # ignore unsupported extended location syntax
|
||||
|
Loading…
Reference in New Issue
Block a user