* src/ReadGedcom.py (parse_family_object): Set MediaRef properly
* src/Marriage.py (__init__): Properly get place title svn: r4395
This commit is contained in:
parent
3aebc669e3
commit
d43ec2d13c
@ -1,3 +1,7 @@
|
|||||||
|
2005-04-21 Martin Hawlisch <Martin.Hawlisch@gmx.de>
|
||||||
|
* src/ReadGedcom.py (parse_family_object): Set MediaRef properly
|
||||||
|
* src/Marriage.py (__init__): Properly get place title
|
||||||
|
|
||||||
2005-04-20 Don Allingham <don@gramps-project.org>
|
2005-04-20 Don Allingham <don@gramps-project.org>
|
||||||
* src/DbPrompter.py: handle runtime errors issued by
|
* src/DbPrompter.py: handle runtime errors issued by
|
||||||
gnomevfs.get_mime_type
|
gnomevfs.get_mime_type
|
||||||
|
@ -236,8 +236,11 @@ class Marriage:
|
|||||||
|
|
||||||
lds_ord = self.family.get_lds_sealing()
|
lds_ord = self.family.get_lds_sealing()
|
||||||
if lds_ord:
|
if lds_ord:
|
||||||
if lds_ord.get_place_handle():
|
place_handle = lds_ord.get_place_handle()
|
||||||
self.lds_place.child.set_text(lds_ord.get_place_handle().get_title())
|
if place_handle:
|
||||||
|
place = self.db.get_place_from_handle( place_handle)
|
||||||
|
if place:
|
||||||
|
self.lds_place.child.set_text( place.get_title())
|
||||||
self.lds_date.set_text(lds_ord.get_date())
|
self.lds_date.set_text(lds_ord.get_date())
|
||||||
self.seal_stat = lds_ord.get_status()
|
self.seal_stat = lds_ord.get_status()
|
||||||
self.lds_date_object = lds_ord.get_date_object()
|
self.lds_date_object = lds_ord.get_date_object()
|
||||||
|
@ -1209,14 +1209,19 @@ class GedcomParser:
|
|||||||
self.warn("\n\t\t".join(path))
|
self.warn("\n\t\t".join(path))
|
||||||
self.warn('\n')
|
self.warn('\n')
|
||||||
else:
|
else:
|
||||||
photo = RelLib.MediaObject()
|
photo_handle = self.media_map.get(path)
|
||||||
photo.set_path(path)
|
if photo_handle == None:
|
||||||
photo.set_description(title)
|
photo = RelLib.MediaObject()
|
||||||
photo.set_mime_type(GrampsMime.get_type(os.path.abspath(path)))
|
photo.set_path(path)
|
||||||
self.db.add_object(photo, self.trans)
|
photo.set_description(title)
|
||||||
|
photo.set_mime_type(GrampsMime.get_type(os.path.abspath(path)))
|
||||||
|
self.db.add_object(photo, self.trans)
|
||||||
|
self.media_map[path] = photo.get_handle()
|
||||||
|
else:
|
||||||
|
photo = self.db.get_object_from_handle(photo_handle)
|
||||||
oref = RelLib.MediaRef()
|
oref = RelLib.MediaRef()
|
||||||
oref.set_reference_handle(photo.get_handle())
|
oref.set_reference_handle(photo.get_handle())
|
||||||
self.family.add_media_reference(photo)
|
self.family.add_media_reference(oref)
|
||||||
self.db.commit_family(self.family, self.trans)
|
self.db.commit_family(self.family, self.trans)
|
||||||
|
|
||||||
def parse_residence(self,address,level):
|
def parse_residence(self,address,level):
|
||||||
|
Loading…
Reference in New Issue
Block a user