diff options
author | hut <hut@lavabit.com> | 2009-12-17 19:55:46 +0100 |
---|---|---|
committer | hut <hut@lavabit.com> | 2009-12-17 19:55:46 +0100 |
commit | d672cbcb3eaef39222fd3902b8ffcb80a21f48f1 (patch) | |
tree | 7f325fe01cb09971401acb8d70beef8aaf64359c | |
parent | 277a7026164384ec453bbb8c59c91996e8262d18 (diff) | |
download | ranger-d672cbcb3eaef39222fd3902b8ffcb80a21f48f1.tar.gz |
fixed history (fast_forward worked reversed)
-rw-r--r-- | ranger/container/history.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ranger/container/history.py b/ranger/container/history.py index 355c7c72..80fe8b4a 100644 --- a/ranger/container/history.py +++ b/ranger/container/history.py @@ -29,7 +29,7 @@ class History(object): def top(self): try: - return self.history_forward[0] + return self.history_forward[-1] except IndexError: try: return self.history[-1] @@ -44,7 +44,7 @@ class History(object): def back(self): if len(self.history) > 1: - self.history_forward.append( self.history.pop() ) + self.history_forward.appendleft( self.history.pop() ) return self.current() def move(self, n): @@ -61,7 +61,7 @@ class History(object): def forward(self): if len(self.history_forward) > 0: - self.history.append( self.history_forward.pop() ) + self.history.append( self.history_forward.popleft() ) return self.current() def fast_forward(self): |