2006-09-11 Don Allingham <don@gramps-project.org>

* src/GrampsDb/_ReadXML.py: don't assume that os.path.sep is the
	first element of an absolute path. Many not be true on some legacy
	operating systems.



svn: r7312
This commit is contained in:
Don Allingham 2006-09-11 15:38:59 +00:00
parent a74f39ea74
commit a05a72b8ea
3 changed files with 8 additions and 3 deletions

View File

@ -1,3 +1,8 @@
2006-09-11 Don Allingham <don@gramps-project.org>
* src/GrampsDb/_ReadXML.py: don't assume that os.path.sep is the
first element of an absolute path. Many not be true on some legacy
operating systems.
2006-09-10 Don Allingham <don@gramps-project.org>
* src/DisplayTabls/_PersonEmbedList.py: enable dnd with people for
associations

View File

@ -1000,9 +1000,9 @@ class GrampsParser(UpdateCallback):
def start_file(self,attrs):
self.object.mime = attrs['mime']
self.object.desc = attrs['description']
src = attrs["src"]
drive,src = os.path.splitdrive(attrs["src"])
if src:
if src[0] != os.path.sep:
if not drive and src[0] != os.path.sep:
fullpath = os.path.abspath(self.filename)
src = os.path.dirname(fullpath) + os.path.sep + src
self.object.path = src

View File

@ -44,7 +44,7 @@ url_bugtracker = "http://bugs.gramps-project.org/bug_report_advanced_page.php"
# Mime Types
#
#-------------------------------------------------------------------------
app_gramps = "application/x-gramps"
app_gramps = ("application/x-gramps", "x-extension-grdb")
app_gramps_xml = "application/x-gramps-xml"
app_gedcom = "application/x-gedcom"
app_gramps_package = "application/x-gramps-package"