From 0af382cf1ef77e79d3330208b872ce0931f1c0be Mon Sep 17 00:00:00 2001 From: Brian Matherly Date: Wed, 9 Jan 2008 05:36:37 +0000 Subject: [PATCH] 0001539: Tab order incorrect - Statistics Chart configuration svn: r9759 --- ChangeLog | 4 ++++ src/PluginUtils/_MenuOptions.py | 9 +++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 180328ebd..13ee1a054 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-08 Brian Matherly + * src/PluginUtils/_MenuOptions.py: + Fix 0001539: Tab order incorrect - Statistics Chart configuration + 2008-01-08 Brian Matherly * src/ReportBase/_GraphvizReportDialog.py: Fix 0001515: GraphViz reports don't register page margins on diff --git a/src/PluginUtils/_MenuOptions.py b/src/PluginUtils/_MenuOptions.py index b252ff7d1..776a855da 100644 --- a/src/PluginUtils/_MenuOptions.py +++ b/src/PluginUtils/_MenuOptions.py @@ -1015,7 +1015,10 @@ class Menu: the user. """ def __init__(self): + # __options holds all the options by their category self.__options = {} + # __categories holds the order of all categories + self.__categories = [] def add_option(self,category,name,option): """ @@ -1033,6 +1036,7 @@ class Menu: @return: nothing """ if not self.__options.has_key(category): + self.__categories.append(category) self.__options[category] = [] self.__options[category].append((name,option)) @@ -1042,10 +1046,7 @@ class Menu: @return: a list of strings """ - categories = [] - for category in self.__options: - categories.append(category) - return categories + return self.__categories def get_option_names(self,category): """