function dashboard_system_info_alter
Implements hook_system_info_alter().
Add regions to each theme to store the dashboard blocks.
File
-
modules/
dashboard/ dashboard.module, line 207
Code
function dashboard_system_info_alter(&$info, $file, $type) {
if ($type == 'theme') {
// Add the dashboard regions (the "inactive" region should always appear
// last in the list, for usability reasons).
$dashboard_regions = dashboard_region_descriptions();
if (isset($dashboard_regions['dashboard_inactive'])) {
$inactive_region = $dashboard_regions['dashboard_inactive'];
unset($dashboard_regions['dashboard_inactive']);
$dashboard_regions['dashboard_inactive'] = $inactive_region;
}
$info['regions'] += $dashboard_regions;
// Indicate that these regions are intended to be displayed whenever the
// dashboard is displayed in an overlay. This information is provided for
// any module that might need to use it, not just the core Overlay module.
$info['overlay_regions'] = !empty($info['overlay_regions']) ? array_merge($info['overlay_regions'], dashboard_regions()) : dashboard_regions();
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.