Moved gtk out of scope of import

svn: r13600
This commit is contained in:
Doug Blank 2009-11-16 23:06:45 +00:00
parent f272ce3dd1
commit ef705c09ef

View File

@ -44,7 +44,6 @@ import DateHandler
from gen.lib.eventroletype import EventRoleType
from gen.lib.eventtype import EventType
from Utils import media_path_full
from QuestionDialog import WarningDialog
from gen.plug.docgen import IndexMark, INDEX_TYPE_ALP
#-------------------------------------------------------------------------
@ -140,6 +139,7 @@ def insert_image(database, doc, photo, w_cm=4.0, h_cm=4.0):
if os.path.exists(filename):
doc.add_media_object(filename, "right", w_cm, h_cm)
else:
from QuestionDialog import WarningDialog
WarningDialog(_("Could not add photo to page"),
"%s: %s" % (filename, _('File does not exist')))