From: Ned Deily Date: Tue, 29 May 2012 17:42:34 +0000 (-0700) Subject: Issue #10997: Prevent a duplicate entry in IDLE's "Recent Files" menu. X-Git-Tag: v2.7.4rc1~781 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=7148984d61b5677af1ee090e52c1cba08299c9f9;p=thirdparty%2FPython%2Fcpython.git Issue #10997: Prevent a duplicate entry in IDLE's "Recent Files" menu. --- diff --git a/Lib/idlelib/EditorWindow.py b/Lib/idlelib/EditorWindow.py index fb05245dc312..68b51e686834 100644 --- a/Lib/idlelib/EditorWindow.py +++ b/Lib/idlelib/EditorWindow.py @@ -856,7 +856,7 @@ class EditorWindow(object): # for each edit window instance, construct the recent files menu for instance in self.top.instance_dict.keys(): menu = instance.recent_files_menu - menu.delete(1, END) # clear, and rebuild: + menu.delete(0, END) # clear, and rebuild: for i, file_name in enumerate(rf_list): file_name = file_name.rstrip() # zap \n # make unicode string to display non-ASCII chars correctly diff --git a/Misc/NEWS b/Misc/NEWS index efcf5501190c..2c50c2f6ba85 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -67,6 +67,8 @@ Core and Builtins Library ------- +- Issue #10997: Prevent a duplicate entry in IDLE's "Recent Files" menu. + - Issue12510: Attempting to get invalid tooltip no longer closes Idle. Original patch by Roger Serwy.