From 804a5d94b6b7f8cb8546112aee2bc3af362f28f5 Mon Sep 17 00:00:00 2001 From: Cheryl Sabella Date: Fri, 28 Dec 2018 13:15:30 -0500 Subject: IDLE: Create function to update menu item state. (GH-11343) This will be needed for other menu items. Change outwin to call the function instead of updating the menu item directly. --- Lib/idlelib/outwin.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'Lib/idlelib/outwin.py') diff --git a/Lib/idlelib/outwin.py b/Lib/idlelib/outwin.py index f6361eb9ae..ecc53ef019 100644 --- a/Lib/idlelib/outwin.py +++ b/Lib/idlelib/outwin.py @@ -78,8 +78,7 @@ class OutputWindow(EditorWindow): EditorWindow.__init__(self, *args) self.text.bind("<>", self.goto_file_line) self.text.unbind("<>") - self.menudict['options'].entryconfig('*Code Context', - state='disabled') + self.update_menu_state('options', '*Code Context', 'disabled') # Customize EditorWindow def ispythonsource(self, filename): -- cgit v1.2.1