Slightly better error message in case of missing resources.
This commit is contained in:
parent
d5f4359458
commit
d05e18139f
|
@ -50,7 +50,7 @@ def Message(msg, id=260, ok=None):
|
|||
|
||||
d = GetNewDialog(id, -1)
|
||||
if not d:
|
||||
print "Can't get DLOG resource with id =", id
|
||||
print "EasyDialogs: Can't get DLOG resource with id =", id, " (missing resource file?)"
|
||||
return
|
||||
h = d.GetDialogItemAsControl(2)
|
||||
SetDialogItemText(h, lf2cr(msg))
|
||||
|
@ -81,7 +81,7 @@ def AskString(prompt, default = "", id=261, ok=None, cancel=None):
|
|||
|
||||
d = GetNewDialog(id, -1)
|
||||
if not d:
|
||||
print "Can't get DLOG resource with id =", id
|
||||
print "EasyDialogs: Can't get DLOG resource with id =", id, " (missing resource file?)"
|
||||
return
|
||||
h = d.GetDialogItemAsControl(3)
|
||||
SetDialogItemText(h, lf2cr(prompt))
|
||||
|
@ -121,7 +121,7 @@ def AskPassword(prompt, default='', id=264, ok=None, cancel=None):
|
|||
"""
|
||||
d = GetNewDialog(id, -1)
|
||||
if not d:
|
||||
print "Can't get DLOG resource with id =", id
|
||||
print "EasyDialogs: Can't get DLOG resource with id =", id, " (missing resource file?)"
|
||||
return
|
||||
h = d.GetDialogItemAsControl(3)
|
||||
SetDialogItemText(h, lf2cr(prompt))
|
||||
|
@ -163,7 +163,7 @@ def AskYesNoCancel(question, default = 0, yes=None, no=None, cancel=None, id=262
|
|||
|
||||
d = GetNewDialog(id, -1)
|
||||
if not d:
|
||||
print "Can't get DLOG resource with id =", id
|
||||
print "EasyDialogs: Can't get DLOG resource with id =", id, " (missing resource file?)"
|
||||
return
|
||||
# Button assignments:
|
||||
# 1 = default (invisible)
|
||||
|
@ -393,7 +393,7 @@ def _selectoption(d, optionlist, idx):
|
|||
def GetArgv(optionlist=None, commandlist=None, addoldfile=1, addnewfile=1, addfolder=1, id=ARGV_ID):
|
||||
d = GetNewDialog(id, -1)
|
||||
if not d:
|
||||
print "Can't get DLOG resource with id =", id
|
||||
print "EasyDialogs: Can't get DLOG resource with id =", id, " (missing resource file?)"
|
||||
return
|
||||
# h = d.GetDialogItemAsControl(3)
|
||||
# SetDialogItemText(h, lf2cr(prompt))
|
||||
|
|
Loading…
Reference in New Issue