diff options
author | Kurt B. Kaiser <kbk@shore.net> | 2002-09-18 03:26:47 (GMT) |
---|---|---|
committer | Kurt B. Kaiser <kbk@shore.net> | 2002-09-18 03:26:47 (GMT) |
commit | 2a5e350265ccc3c8ffe2f3cc66854f4a341da432 (patch) | |
tree | be319a8e7b048aea35abc08eac25d8386c633816 /Lib | |
parent | 089a64a749a510f67217bf5736afc56a9dfd0fdc (diff) | |
download | cpython-2a5e350265ccc3c8ffe2f3cc66854f4a341da432.zip cpython-2a5e350265ccc3c8ffe2f3cc66854f4a341da432.tar.gz cpython-2a5e350265ccc3c8ffe2f3cc66854f4a341da432.tar.bz2 |
Merge Py Idle changes:
Rev 1.6 GvR
Finally fix SF bug #441172, using a variant of patch ##443626:
canceling an edit operation would not revert the value of the field.
The fix takes care to destroy the Entry object, as suggested in the
patch.
Rev 1.7 Geiger Ho / GvR
(previously applied - Idlefork Rev 1.3)
Rev 1.8 doerwalter
(string methods)
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/idlelib/TreeWidget.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Lib/idlelib/TreeWidget.py b/Lib/idlelib/TreeWidget.py index ebc7be0..d713264 100644 --- a/Lib/idlelib/TreeWidget.py +++ b/Lib/idlelib/TreeWidget.py @@ -16,7 +16,6 @@ import os import sys -import string from Tkinter import * import imp @@ -291,6 +290,12 @@ class TreeNode: self.canvas.focus_set() def edit_cancel(self, event=None): + try: + entry = self.entry + del self.entry + except AttributeError: + return + entry.destroy() self.drawtext() self.canvas.focus_set() |