mirror of
https://github.com/python/cpython.git
synced 2025-10-17 04:08:28 +00:00
Patch #518625: Return objects in Tkinter.
This commit is contained in:
parent
52ea7e9244
commit
ffad633af9
3 changed files with 335 additions and 6 deletions
|
@ -45,6 +45,8 @@ try:
|
|||
except ImportError:
|
||||
_MacOS = None
|
||||
|
||||
want_objects = 1
|
||||
|
||||
TkVersion = float(_tkinter.TK_VERSION)
|
||||
TclVersion = float(_tkinter.TCL_VERSION)
|
||||
|
||||
|
@ -1521,6 +1523,7 @@ class Tk(Misc, Wm):
|
|||
if ext not in ('.py', '.pyc', '.pyo'):
|
||||
baseName = baseName + ext
|
||||
self.tk = _tkinter.create(screenName, baseName, className)
|
||||
self.tk.wantobjects(want_objects)
|
||||
if _MacOS and hasattr(_MacOS, 'SchedParams'):
|
||||
# Disable event scanning except for Command-Period
|
||||
_MacOS.SchedParams(1, 0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue