Just found an incompatibly with module menu_position:
menu_position is adding some stuff into the menu tree php object (which are not really menu_item...) menu_block get confused during the building process of the renderable array (function menu_block_tree_output): The result is that the active menu item will have automatically the css class "expanded" if he has a "menu_position" rule on itself, even if it is not really expanded.

Whereas the "core" default way of building renderable array for menu work fine in the same situation. So I suggest a change in the way menu_block is building menu structure, to make it similar to the core menu:

  • menu core is doing: if ($data['link']['has_children'] && $data['below']) {$class[] = 'expanded';}
  • block_menu is doing: if ($data['below']) {$class[] = 'expanded';}

Issue already notice here http://drupal.org/node/1266816 with detailed explanations (but issue has since changed subject and has been closed)

Comments

Title:Imcompatible with module like menu_positionIncompatible with modules like menu_position

typo

Status:Needs work» Needs review
StatusFileSize
new459 bytes

here is the proposed patch.

Title:Incompatible with modules like menu_positionIncompatibility with modules like menu_position
Status:Needs review» Fixed

Fixed!

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.