1 menu.module menu_block_view($delta = '', $settings = array())

Implements hook_block_view().

File

core/modules/menu/menu.module, line 516
Allows administrators to customize the site's menus.

Code

function menu_block_view($delta = '', $settings = array()) {
  module_load_include('inc', 'system', 'system.menu');
  $settings += system_menu_block_defaults($delta);
  $data = system_menu_block_build($settings);
  $block['subject'] = $data['subject'];
  $block['content'] = $data['content'];
  // Add contextual links for this block.
  if (!empty($block['content'])) {
    $block['content']['#contextual_links']['menu'] = array('admin/structure/menu/manage', array($delta));
  }
  return $block;
}