From 7e3e8d14402833295ab83ff1591ecbe46867518b Mon Sep 17 00:00:00 2001 From: hut Date: Tue, 5 Jan 2010 02:21:21 +0100 Subject: pager: added narg for move_horizontal --- ranger/gui/widgets/pager.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ranger/gui/widgets/pager.py b/ranger/gui/widgets/pager.py index 5e9ef3c8..48492573 100644 --- a/ranger/gui/widgets/pager.py +++ b/ranger/gui/widgets/pager.py @@ -90,7 +90,13 @@ class Pager(Widget): self.scroll_begin = i - def move_horizontal(self, relative=0, absolute=None): + def move_horizontal(self, relative=0, absolute=None, narg=None): + if narg is not None: + if absolute is None: + relative = relative < 0 and -narg or narg + else: + absolute = narg + self.startx = move_between( current=self.startx, minimum=0, -- cgit 1.4.1-2-gfad0