feature 1515: the new admin menu organization implies to tell the accordion

menu which section to open on page load.

I've moved the single function in functions_themes.inc.php to function.php to
avoid misunderstanding with theme manager.

Ability to preset the active menu (in the future, a plugin may add its admin
page anywhere in the menu, this features needs other change to be possible)

git-svn-id: http://piwigo.org/svn/trunk@5173 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
plegall 2010-03-17 23:50:53 +00:00
commit cd00dffa72
6 changed files with 79 additions and 69 deletions

View file

@ -1,12 +1,7 @@
<?php
if (!function_exists('selected_admin_menu'))
{
include_once(PHPWG_ROOT_PATH.'admin/include/functions_themes.inc.php');
}
$themeconf = array(
'theme' => 'clear',
'parent' => 'default',
'admin_icon_dir' => 'admin/themes/clear/icon',
'selected_admin_menu' => selected_admin_menu(),
);
?>

View file

@ -7,7 +7,7 @@ jQuery().ready(function(){ldelim}
jQuery('#menubar').accordion({ldelim}
header: "dt.rdion",
event: "click",
active: {$U_ACTIVE_MENU|default:$themeconf.selected_admin_menu}
active: {$ACTIVE_MENU}
});
});
</script>

View file

@ -1,11 +1,6 @@
<?php
if (!function_exists('selected_admin_menu'))
{
include_once(PHPWG_ROOT_PATH.'admin/include/functions_themes.inc.php');
}
$themeconf = array(
'theme' => 'roma',
'parent' => 'default',
'selected_admin_menu' => selected_admin_menu(),
);
?>