main menu: set extras according to pandora.site.menuExtras

This commit is contained in:
rolux 2013-08-08 13:02:24 +00:00
parent f06285185b
commit eb89f530c8

View file

@ -9,9 +9,15 @@ pandora.ui.mainMenu = function() {
fromMenu = false, fromMenu = false,
fullscreenState = Ox.Fullscreen.getState(), fullscreenState = Ox.Fullscreen.getState(),
that = Ox.MainMenu({ that = Ox.MainMenu({
extras: [ extras: pandora.site.menuExtras.map(function(menuExtra) {
pandora.$ui.loadingIcon = pandora.ui.loadingIcon() if (menuExtra == 'user') {
], return pandora.$ui.userButton = pandora.ui.userButton();
} else if (menuExtra == 'locale') {
return pandora.$ui.localeButton = pandora.ui.localeButton();
} else if (menuExtra == 'reload') {
return pandora.$ui.loadingIcon = pandora.ui.loadingIcon();
}
}),
id: 'mainMenu', id: 'mainMenu',
menus: [].concat( menus: [].concat(
[ [