about summary refs log tree commit diff stats
path: root/ranger/gui/widgets
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2009-12-15 23:44:49 +0100
committerhut <hut@lavabit.com>2009-12-15 23:44:49 +0100
commite48e3c5c5046bf992a563d112629f10a3adc8168 (patch)
treeeb1a41180d2918dbe78da52b3730fa53fc6bf6a2 /ranger/gui/widgets
parent7ec262f86c81c4df4360643b05dfb788d294a8ae (diff)
downloadranger-e48e3c5c5046bf992a563d112629f10a3adc8168.tar.gz
fixed CD command / tab completion
Diffstat (limited to 'ranger/gui/widgets')
-rw-r--r--ranger/gui/widgets/console.py17
1 files changed, 5 insertions, 12 deletions
diff --git a/ranger/gui/widgets/console.py b/ranger/gui/widgets/console.py
index 25341e00..7421db98 100644
--- a/ranger/gui/widgets/console.py
+++ b/ranger/gui/widgets/console.py
@@ -140,7 +140,7 @@ class CommandConsole(Console):
 	prompt = ':'
 
 	def execute(self):
-		self._exec_cmd()
+		commands.execute(self._get_cmd(), self.line)
 		Console.execute(self)
 	
 	def tab(self, n=1):
@@ -163,26 +163,19 @@ class CommandConsole(Console):
 			self.line = self.tab_deque[0]
 			self.pos = len(self.line)
 
-	def _get_tab(self):
-		cmd = self._get_cmd()
-		try:
-			return commands.tab(cmd, self.line)
-		except KeyError:
-			return None
-	
 	def _get_cmd(self):
 		try:
 			return self.line.split()[0]
 		except:
 			return ''
 	
-	def _exec_cmd(self):
+	def _get_tab(self):
 		cmd = self._get_cmd()
 		try:
-			commands.execute(cmd, self.line)
+			return commands.tab(cmd, self.line)
 		except KeyError:
-			pass # command not found!
-			
+			return commands.tab(None, self.line)
+
 
 class QuickCommandConsole(Console):
 	prompt = '>'