Mercurial > libervia-web
diff libervia.py @ 336:629c99bbd031
browser + server side: refactored menus:
- getMenus is added to Register class, so it can be used before being logged
- dynamic menus are added to main menu bar
- security limit is used
- menus use i18n
author | Goffi <goffi@goffi.org> |
---|---|
date | Tue, 04 Feb 2014 16:49:20 +0100 |
parents | 835a8ae799e7 |
children | 2067d6241927 |
line wrap: on
line diff
--- a/libervia.py Tue Feb 04 16:49:20 2014 +0100 +++ b/libervia.py Tue Feb 04 16:49:20 2014 +0100 @@ -113,7 +113,7 @@ class RegisterCall(LiberviaJsonProxy): def __init__(self): LiberviaJsonProxy.__init__(self, "/register_api", - ["isRegistered", "isConnected", "connect", "registerParams"]) + ["isRegistered", "isConnected", "connect", "registerParams", "getMenus"]) class BridgeCall(LiberviaJsonProxy): @@ -127,7 +127,7 @@ "getWaitingSub", "subscription", "delContact", "updateContact", "getCard", "getEntityData", "getParamsUI", "asyncGetParamA", "setParam", "launchAction", "disconnect", "chatStateComposing", "getNewAccountDomain", "confirmationAnswer", - "syntaxConvert" + "syntaxConvert", ]) @@ -184,6 +184,7 @@ self.notification = Notification() DOM.addEventPreview(self) self._register = RegisterCall() + self._register.call('getMenus', self.panel.menu.createMenus) self._register.call('registerParams', None) self._register.call('isRegistered', self._isRegisteredCB) self.initialised = False