From dad0644f8819521c26739c185254f6edb36746ce Mon Sep 17 00:00:00 2001 From: hut Date: Mon, 1 Nov 2010 14:25:58 +0100 Subject: widgets.browsercolumn: Run files with right mouse click --- ranger/gui/widgets/browsercolumn.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ranger/gui/widgets/browsercolumn.py b/ranger/gui/widgets/browsercolumn.py index eb898e2a..5422b960 100644 --- a/ranger/gui/widgets/browsercolumn.py +++ b/ranger/gui/widgets/browsercolumn.py @@ -82,7 +82,11 @@ class BrowserColumn(Pager): elif event.pressed(3): try: clicked_file = self.target.files[index] - self.fm.enter_dir(clicked_file.path) + if clicked_file.is_directory: + self.fm.enter_dir(clicked_file.path) + elif self.level == 0: + self.fm.env.cwd.move_to_obj(clicked_file) + self.fm.execute_file(clicked_file) except: pass -- cgit 1.4.1-2-gfad0