Project

General

Profile

Bug #20532 » 11224_v2-pre-cleanup.diff

Administrator Admin, 2009-09-18 16:34

View differences:

typo3/sysext/cms/tslib/class.tslib_menu.php (working copy)
// Setting "nextActive": This is the page uid + MPvar of the NEXT page in rootline. Used to expand the menu if we are in the right branch of the tree
// Notice: The automatic expansion of a menu is designed to work only when no "special" modes (except "directory") are used.
$startLevel = $directoryLevel?$directoryLevel:$this->entryLevel;
if (is_array($this->tmpl->rootLine[$startLevel+$this->menuNumber])) {
$startLevel = $directoryLevel ? $directoryLevel : $this->entryLevel;
$currentLevel = $startLevel + $this->menuNumber;
if (is_array($this->tmpl->rootLine[$currentLevel])) {
$nextMParray = $this->MP_array;
if ($this->tmpl->rootLine[$startLevel+$this->menuNumber]['_MOUNT_OL']) { // In overlay mode, add next level MPvars as well:
$nextMParray[] = $this->tmpl->rootLine[$startLevel+$this->menuNumber]['_MP_PARAM'];
if ($this->tmpl->rootLine[$currentLevel]['_MOUNT_OL']) { // In overlay mode, add next level MPvars as well:
$nextMParray[] = $this->tmpl->rootLine[$currentLevel]['_MP_PARAM'];
}
$this->nextActive = $this->tmpl->rootLine[$startLevel+$this->menuNumber]['uid'].(count($nextMParray)?':'.implode(',',$nextMParray):'');
$this->nextActive = $this->tmpl->rootLine[$currentLevel]['uid'] . (count($nextMParray) ? ':' . implode(',', $nextMParray) : '');
} else {
$this->nextActive = '';
}
(2-2/3)