summaryrefslogtreecommitdiffstats
path: root/Lib/lib-tk/Dialog.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/lib-tk/Dialog.py')
-rw-r--r--Lib/lib-tk/Dialog.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/Lib/lib-tk/Dialog.py b/Lib/lib-tk/Dialog.py
index 022bd96..db8f5da 100644
--- a/Lib/lib-tk/Dialog.py
+++ b/Lib/lib-tk/Dialog.py
@@ -1,8 +1,16 @@
# Dialog.py -- Tkinter interface to the tk_dialog script.
+
from Tkinter import *
+if TkVersion == 3.6:
+ DIALOG_ICON = 'warning'
+else:
+ DIALOG_ICON = 'questhead'
+
+
class Dialog(Widget):
def __init__(self, master=None, cnf={}):
+ self.widgetName = '__dialog__'
Widget._setup(self, master, cnf)
self.num = self.tk.getint(
apply(self.tk.call,
@@ -21,7 +29,7 @@ def _test():
' since the last time it was saved.'
' Do you want to save it before'
' exiting the application.',
- 'bitmap': 'warning',
+ 'bitmap': DIALOG_ICON,
'default': 0,
'strings': ('Save File',
'Discard Changes',