From 03c01fa4f0ceb264c2830cb8c15d826eb4af34b7 Mon Sep 17 00:00:00 2001 From: Martin Hawlisch Date: Mon, 16 Apr 2007 13:57:03 +0000 Subject: [PATCH] * src/ViewManager.py (create_pages): fix off-by-one error when preselecting last view svn: r8391 --- ChangeLog | 4 ++++ src/ViewManager.py | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 99cad21ed..a1c239c4b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2007-04-16 Martin Hawlisch + * src/ViewManager.py (create_pages): fix off-by-one error when + preselecting last view + 2007-04-14 Brian Matherly * src/plugins/NarrativeWeb.py * src/ReportBase/_ReportUtils.py diff --git a/src/ViewManager.py b/src/ViewManager.py index d3504678b..9625a322a 100644 --- a/src/ViewManager.py +++ b/src/ViewManager.py @@ -793,7 +793,7 @@ class ViewManager: use_current = Config.get(Config.USE_LAST_VIEW) if use_current: current_page = Config.get(Config.LAST_VIEW) - if current_page > len(self.pages): + if current_page >= len(self.pages): current_page = 0 else: current_page = 0