From 57bb0ce78c2c4da8d5492e7ecf41db838441a548 Mon Sep 17 00:00:00 2001 From: Don Allingham Date: Thu, 25 May 2006 02:30:16 +0000 Subject: [PATCH] * src/GrampsDb/_DbUtils.py: fix index setting of death index * src/GrampsDb/_WriteGedcom.py: remove redundant birth/death references svn: r6772 --- ChangeLog | 3 +++ src/GrampsDb/_DbUtils.py | 1 + src/GrampsDb/_WriteGedcom.py | 5 ++++- 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index f84ac44b9..c8720361f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,7 @@ 2006-05-24 Don Allingham + * src/GrampsDb/_DbUtils.py: fix index setting of death index + * src/GrampsDb/_WriteGedcom.py: remove redundant birth/death + references * src/images/stock_notes.png: added * src/images/Makefile.am: add stock_notes.png * src/gramps_main.py: register stock_notes as gramps_notes diff --git a/src/GrampsDb/_DbUtils.py b/src/GrampsDb/_DbUtils.py index 2c9d73bbb..87179ba5d 100644 --- a/src/GrampsDb/_DbUtils.py +++ b/src/GrampsDb/_DbUtils.py @@ -283,6 +283,7 @@ def set_birth_death_index(db, person): birth = index elif int(event.get_type()) == RelLib.EventType.DEATH and death == -1: death = index + index += 1 person.birth_ref_index = birth person.death_ref_index = death diff --git a/src/GrampsDb/_WriteGedcom.py b/src/GrampsDb/_WriteGedcom.py index cd039d92e..5b2b3fac1 100644 --- a/src/GrampsDb/_WriteGedcom.py +++ b/src/GrampsDb/_WriteGedcom.py @@ -907,6 +907,10 @@ class GedcomWriter(UpdateCallback): for event_ref in person.get_event_ref_list(): event = self.db.get_event_from_handle(event_ref.ref) + if int(event.get_type()) in (RelLib.EventType.BIRTH, + RelLib.EventType.DEATH): + continue + if self.private and event.get_privacy(): continue val = event.get_type().xml_str() @@ -1359,7 +1363,6 @@ class GedcomWriter(UpdateCallback): def write_photo(self,photo,level): photo_obj_id = photo.get_reference_handle() photo_obj = self.db.get_object_from_handle(photo_obj_id) - print photo_obj, photo_obj.get_mime_type() if photo_obj: mime = photo_obj.get_mime_type() if self.mime2ged.has_key(mime):