You are here

function hook_ds_layout_region_alter in Display Suite 7

Same name and namespace in other branches
  1. 8.4 ds.api.php \hook_ds_layout_region_alter()
  2. 8.2 ds.api.php \hook_ds_layout_region_alter()
  3. 8.3 ds.api.php \hook_ds_layout_region_alter()
  4. 7.2 ds.api.php \hook_ds_layout_region_alter()

Alter the region options in the field UI screen.

This function is only called when a layout has been chosen.

Parameters

$context: A collection of keys for the context. The keys are 'entity_type', 'bundle' and 'view_mode'.

$region_info: A collection of info for regions. The keys are 'region_options' and 'table_regions'.

1 function implements hook_ds_layout_region_alter()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

ds_extras_ds_layout_region_alter in modules/ds_extras/ds_extras.module
Implements hook_ds_layout_region_alter().
2 invocations of hook_ds_layout_region_alter()
ds_field_ui_layout_change in ./ds.field_ui.inc
Change a layout for a given entity.
ds_field_ui_regions in ./ds.field_ui.inc
Add Regions to 'Manage fields' or 'Manage display' screen.

File

./ds.api.php, line 435
Hooks provided by Display Suite module.

Code

function hook_ds_layout_region_alter($context, &$region_info) {
  $region_info['region_options'][$block_key] = $block['title'];
  $region_info['table_regions'][$block_key] = array(
    'title' => check_plain($block['title']),
    'message' => t('No fields are displayed in this region'),
  );
}