[Python-checkins] r78988 - in python/trunk: Lib/lib-tk/tkMessageBox.py Misc/NEWS
matthias.klose
python-checkins at python.org
Tue Mar 16 11:48:53 CET 2010
Author: matthias.klose
Date: Tue Mar 16 11:48:52 2010
New Revision: 78988
Log:
- Issue #4961: Inconsistent/wrong result of askyesno function in tkMessageBox
with Tcl/Tk-8.5.
Modified:
python/trunk/Lib/lib-tk/tkMessageBox.py
python/trunk/Misc/NEWS
Modified: python/trunk/Lib/lib-tk/tkMessageBox.py
==============================================================================
--- python/trunk/Lib/lib-tk/tkMessageBox.py (original)
+++ python/trunk/Lib/lib-tk/tkMessageBox.py Tue Mar 16 11:48:52 2010
@@ -70,11 +70,13 @@
if title: options["title"] = title
if message: options["message"] = message
res = Message(**options).show()
- # In some Tcl installations, Tcl converts yes/no into a boolean
+ # In some Tcl installations, yes/no is converted into a boolean.
if isinstance(res, bool):
- if res: return YES
+ if res:
+ return YES
return NO
- return res
+ # In others we get a Tcl_Obj.
+ return str(res)
def showinfo(title=None, message=None, **options):
"Show an info message"
Modified: python/trunk/Misc/NEWS
==============================================================================
--- python/trunk/Misc/NEWS (original)
+++ python/trunk/Misc/NEWS Tue Mar 16 11:48:52 2010
@@ -20,6 +20,9 @@
Library
-------
+- Issue #4961: Inconsistent/wrong result of askyesno function in tkMessageBox
+ with Tcl/Tk-8.5.
+
- Issue #8140: extend compileall to compile single files. Add -i option.
- Issue #7356: ctypes.util: Make parsing of ldconfig output independent of
More information about the Python-checkins
mailing list