(GrampsInMemDB._del_*): Prpoper deletes.

svn: r6585
This commit is contained in:
Alex Roitman 2006-05-08 18:54:56 +00:00
parent a19c4f2543
commit 1063ff3d02
2 changed files with 8 additions and 8 deletions

View File

@ -6,7 +6,7 @@
* src/GrampsDb/_ReadXML.py (start_childref): Typo. * src/GrampsDb/_ReadXML.py (start_childref): Typo.
* src/GrampsDb/_GrampsInMemDB.py (load): Define self.full_name * src/GrampsDb/_GrampsInMemDB.py (load): Define self.full_name
prior to calling open_undodb(). prior to calling open_undodb().
(GrampsInMemDB._del_family): Remove obsolete code. (GrampsInMemDB._del_*): Prpoper deletes.
2006-05-07 Don Allingham <don@gramps-project.org> 2006-05-07 Don Allingham <don@gramps-project.org>
* configure.in: set for 2.1.1 * configure.in: set for 2.1.1

View File

@ -171,32 +171,32 @@ class GrampsInMemDB(GrampsDbBase):
def _del_person(self,handle): def _del_person(self,handle):
person = self.person_map.pop(str(handle))
del self.id_trans[person.get_gramps_id()] del self.id_trans[person.get_gramps_id()]
del self.person_map[handle]
def _del_source(self,handle): def _del_source(self,handle):
source = self.source_map.pop(str(handle))
del self.sid_trans[source.get_gramps_id()] del self.sid_trans[source.get_gramps_id()]
del self.source_map[str(handle)]
def _del_repository(self,handle): def _del_repository(self,handle):
repository = self.repository_map.pop(str(handle))
del self.rid_trans[repository.get_gramps_id()] del self.rid_trans[repository.get_gramps_id()]
del self.repository_map[str(handle)]
def _del_place(self,handle): def _del_place(self,handle):
place = self.place_map.pop(str(handle))
del self.pid_trans[place.get_gramps_id()] del self.pid_trans[place.get_gramps_id()]
del self.place_map[str(handle)]
def _del_media(self,handle): def _del_media(self,handle):
obj = self.media_map.pop(str(handle))
del self.oid_trans[obj.get_gramps_id()] del self.oid_trans[obj.get_gramps_id()]
del self.media_map[str(handle)]
def _del_family(self,handle): def _del_family(self,handle):
family = self.family_map.pop(str(handle))
del self.fid_trans[family.get_gramps_id()] del self.fid_trans[family.get_gramps_id()]
del self.family_map[str(handle)]
def _del_event(self,handle): def _del_event(self,handle):
event = self.event_map.pop(str(handle))
del self.eid_trans[event.get_gramps_id()] del self.eid_trans[event.get_gramps_id()]
del self.event_map[str(handle)]
def commit_person(self,person,transaction,change_time=None): def commit_person(self,person,transaction,change_time=None):
if self.readonly or not person.get_handle(): if self.readonly or not person.get_handle():