diff options
author | Manuel Quiñones <manuq@laptop.org> | 2012-04-30 12:55:45 (GMT) |
---|---|---|
committer | Manuel Quiñones <manuq@laptop.org> | 2012-04-30 13:06:41 (GMT) |
commit | c9e19a4da890cd528e1ff70697f28470aa18217e (patch) | |
tree | f2f235a1b7618766a993ba4b7a244148b3736996 /webtoolbar.py | |
parent | fb09fdb625dde0e90c46a5a19aa8d245b377f6e6 (diff) |
Fix up key navigation in drop-down list of suggested pages SL #3473
This needs a fix for PyGObject, that landed in master in commit
d37680bb9390426f7f58ea3d352c3e5e2106e978 .
Original patch from Manuel Kauffmann.
Signed-off-by: Manuel Quiñones <manuq@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
Diffstat (limited to 'webtoolbar.py')
-rw-r--r-- | webtoolbar.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/webtoolbar.py b/webtoolbar.py index b49cf5a..d0f2dc9 100644 --- a/webtoolbar.py +++ b/webtoolbar.py @@ -178,10 +178,10 @@ class WebEntry(iconentry.IconEntry): selection.select_iter(model[-1].iter) self._set_text(model[-1][0]) else: - index = model.get_path(selected)[0] - if index > 0: - selection.select_path(index - 1) - self._set_text(model[index - 1][0]) + up_iter = model.iter_previous(selected) + if up_iter: + selection.select_iter(up_iter) + self._set_text(model.get(up_iter, 0)[0]) return True elif keyname == 'Down': if selected is None: |