* src/DbPrompter.py: Try to give a more intelligent error message on an
exception thrown in DbPrompter - don't give a traceback. * src/MediaView.py: clear out details and image if unselected svn: r5938
This commit is contained in:
parent
c1b12a893f
commit
810a80da51
@ -1,3 +1,8 @@
|
||||
2006-02-14 Don Allingham <don@gramps-project.org>
|
||||
* src/DbPrompter.py: Try to give a more intelligent error message on an
|
||||
exception thrown in DbPrompter - don't give a traceback.
|
||||
* src/MediaView.py: clear out details and image if unselected
|
||||
|
||||
2006-02-14 Alex Roitman <shura@gramps-project.org>
|
||||
* src/ReportUtils.py (buried_str): Change the logic to be the same
|
||||
as in born_str: first test for modified date, then full date, then
|
||||
|
@ -138,16 +138,12 @@ class DbPrompter:
|
||||
top.show()
|
||||
response = top.run()
|
||||
top.hide()
|
||||
try:
|
||||
if response == gtk.RESPONSE_OK:
|
||||
if recent.get_active():
|
||||
try:
|
||||
(filename,filetype) = self.recent_files[filelist.get_active()]
|
||||
if open_native(self.parent,filename,filetype):
|
||||
break
|
||||
except RuntimeError,msg:
|
||||
QuestionDialog.ErrorDialog(
|
||||
_("Could not open file: %s") % self.recent_file,
|
||||
str(msg))
|
||||
continue
|
||||
elif new.get_active():
|
||||
prompter = NewNativeDbPrompter(self.parent,
|
||||
@ -161,6 +157,9 @@ class DbPrompter:
|
||||
break
|
||||
elif response == gtk.RESPONSE_HELP:
|
||||
GrampsDisplay.help('choose-db-start')
|
||||
except:
|
||||
import sys
|
||||
QuestionDialog.ErrorDialog(_("Could not open file"),str(sys.exc_info()[1]))
|
||||
|
||||
top.destroy()
|
||||
if response == gtk.RESPONSE_CANCEL:
|
||||
|
@ -227,8 +227,13 @@ class MediaView:
|
||||
|
||||
store,node = self.selection.get_selected()
|
||||
if not node:
|
||||
return
|
||||
|
||||
self.preview.set_from_pixbuf(None)
|
||||
self.mid.set_text('')
|
||||
self.mdesc.set_text('')
|
||||
self.mpath.set_text('')
|
||||
self.mdetails.set_text('')
|
||||
self.mtype.set_text('')
|
||||
else:
|
||||
handle = store.get_value(node,_HANDLE_COL)
|
||||
|
||||
mobj = self.db.get_object_from_handle(handle)
|
||||
|
Loading…
x
Reference in New Issue
Block a user