Issue #2590605 by yched: Followup for [#2322503]

8.0.x
Alex Pott 2015-10-17 06:08:46 -07:00
parent 19adf84475
commit ba11b09456
3 changed files with 5 additions and 5 deletions

View File

@ -1132,7 +1132,7 @@ class EntityManager extends DefaultPluginManager implements EntityManagerInterfa
}
/**
* Returns an array of display mode options by bundle.
* Returns an array of enabled display mode options by bundle.
*
* @param $display_type
* The display type to be retrieved. It can be "view_mode" or "form_mode".

View File

@ -450,7 +450,7 @@ interface EntityManagerInterface extends PluginManagerInterface, EntityTypeListe
public function getFormModeOptions($entity_type_id);
/**
* Returns an array of view mode options by bundle.
* Returns an array of enabled view mode options by bundle.
*
* @param string $entity_type_id
* The entity type whose view mode options should be returned.
@ -463,7 +463,7 @@ interface EntityManagerInterface extends PluginManagerInterface, EntityTypeListe
public function getViewModeOptionsByBundle($entity_type_id, $bundle);
/**
* Returns an array of form mode options by bundle.
* Returns an array of enabled form mode options by bundle.
*
* @param string $entity_type_id
* The entity type whose form mode options should be returned.

View File

@ -211,8 +211,8 @@ abstract class EntityDisplayFormBase extends EntityForm {
);
// Prepare default values for the 'Custom display settings' checkboxes.
$default = array();
if ($display_statuses = array_filter($this->getDisplayStatuses())) {
$default = array_keys(array_intersect_key($display_mode_options, $display_statuses));
if ($enabled_displays = array_filter($this->getDisplayStatuses())) {
$default = array_keys(array_intersect_key($display_mode_options, $enabled_displays));
}
$form['modes']['display_modes_custom'] = array(
'#type' => 'checkboxes',