From f3643e16acdb33f7a05ef3ce3faa45142a727e37 Mon Sep 17 00:00:00 2001 From: Stefan Pluecken Date: Wed, 11 Jan 2006 20:03:06 +0000 Subject: menu positioning for the plugins works now example: def getMenuRegistrationList(): list = [] list.append(("setup", 2, "Softwareupdate", "Example")) list.append(("mainmenu", 0, "Foo", "Bar")) return list this means, that we have 2 menu entries: a menu entry "Softwareupdate" is added to the setup menu on position 2 which calls the Example screen of the plugin and a menu entry Foo is added to the main menu on the first position which calls the screen Bar --- lib/python/Components/PluginComponent.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/python/Components') diff --git a/lib/python/Components/PluginComponent.py b/lib/python/Components/PluginComponent.py index e0cc90a4..adfc98a0 100644 --- a/lib/python/Components/PluginComponent.py +++ b/lib/python/Components/PluginComponent.py @@ -57,11 +57,11 @@ class PluginComponent: def menuDelete(self): for menuEntry in self.menuEntries: - menuupdater.delMenuItem(menuEntry[0][0], menuEntry[0][2], menuEntry[1], menuEntry[0][3]) + menuupdater.delMenuItem(menuEntry[0][0], menuEntry[0][1], menuEntry[0][2], menuEntry[1], menuEntry[0][3]) def menuUpdate(self): for menuEntry in self.menuEntries: - menuupdater.addMenuItem(menuEntry[0][0], menuEntry[0][2], menuEntry[1], menuEntry[0][3]) + menuupdater.addMenuItem(menuEntry[0][0], menuEntry[0][1], menuEntry[0][2], menuEntry[1], menuEntry[0][3]) def runPlugin(self, plugin, session): try: -- cgit v1.2.3