From d6e8713f81f69947d5373f7dd3b6632f6e970bad Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Wed, 10 Mar 1999 05:18:02 +0000 Subject: Add PathBrowser to File module --- Tools/idle/Bindings.py | 1 + Tools/idle/EditorWindow.py | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/Tools/idle/Bindings.py b/Tools/idle/Bindings.py index e0a2570..f66d118 100644 --- a/Tools/idle/Bindings.py +++ b/Tools/idle/Bindings.py @@ -16,6 +16,7 @@ menudefs = [ ('_Open...', '<>'), ('Open _module...', '<>'), ('Class _browser', '<>'), + ('_Path browser', '<>'), ('Python shell', '<>'), None, ('_Save', '<>'), diff --git a/Tools/idle/EditorWindow.py b/Tools/idle/EditorWindow.py index 9436903..cea3fcd 100644 --- a/Tools/idle/EditorWindow.py +++ b/Tools/idle/EditorWindow.py @@ -19,6 +19,8 @@ import WindowList #$ win #$ unix +#$ event <> + #$ event <> #$ unix #$ unix @@ -118,6 +120,7 @@ class EditorWindow: text.bind("<>", self.flist.new_callback) text.bind("<>", self.flist.close_all_callback) text.bind("<>", self.open_class_browser) + text.bind("<>", self.open_path_browser) vbar['command'] = text.yview vbar.pack(side=RIGHT, fill=Y) @@ -312,6 +315,10 @@ class EditorWindow: import ClassBrowser ClassBrowser.ClassBrowser(self.flist, base, [head]) self.text["cursor"] = save_cursor + + def open_path_browser(self, event=None): + import PathBrowser + PathBrowser.PathBrowser(self.flist) def gotoline(self, lineno): if lineno is not None and lineno > 0: -- cgit v0.12