summaryrefslogtreecommitdiff
path: root/includes
diff options
context:
space:
mode:
authorAngie Byron <webchick@24967.no-reply.drupal.org>2010-01-08 07:30:34 +0000
committerAngie Byron <webchick@24967.no-reply.drupal.org>2010-01-08 07:30:34 +0000
commit2d632d1a187e687eed1e3a6e732aeb97f3ceebdb (patch)
treef9ff44189d5c1fd7abd92eb5f72923c83de89e43 /includes
parent0e3fda75df2279ab867452b04908144438dcf067 (diff)
downloadbrdo-2d632d1a187e687eed1e3a6e732aeb97f3ceebdb.tar.gz
brdo-2d632d1a187e687eed1e3a6e732aeb97f3ceebdb.tar.bz2
#634472 by sun and effulgentsia: Allow menu template file suggestions.
Diffstat (limited to 'includes')
-rw-r--r--includes/menu.inc6
1 files changed, 4 insertions, 2 deletions
diff --git a/includes/menu.inc b/includes/menu.inc
index 361b8dc19..5e4ee1001 100644
--- a/includes/menu.inc
+++ b/includes/menu.inc
@@ -921,7 +921,8 @@ function menu_tree_output($tree) {
$data['localized_options']['attributes']['class'][] = 'active-trail';
}
- $element['#theme'] = 'menu_link';
+ // Allow menu-specific theme overrides.
+ $element['#theme'] = 'menu_link__' . $data['link']['menu_name'];
$element['#attributes']['class'] = $class;
$element['#title'] = $data['link']['title'];
$element['#href'] = $data['link']['href'];
@@ -935,7 +936,8 @@ function menu_tree_output($tree) {
// Make sure drupal_render() does not re-order the links.
$build['#sorted'] = TRUE;
// Add the theme wrapper for outer markup.
- $build['#theme_wrappers'][] = 'menu_tree';
+ // Allow menu-specific theme overrides.
+ $build['#theme_wrappers'][] = 'menu_tree__' . $data['link']['menu_name'];
}
return $build;