public function ViewUI::isDefaultDisplayShown in Views (for Drupal 7) 8.3
Controls whether or not the default display should have its own tab on edit.
1 call to ViewUI::isDefaultDisplayShown()
- ViewUI::getDisplayTabs in views_ui/
lib/ Drupal/ views_ui/ ViewUI.php - Adds tabs for navigating across Displays when editing a View.
File
- views_ui/
lib/ Drupal/ views_ui/ ViewUI.php, line 548 - Definition of Drupal\views_ui\ViewUI.
Class
- ViewUI
- Stores UI related temporary settings.
Namespace
Drupal\views_uiCode
public function isDefaultDisplayShown() {
// Always show the default display for advanced users who prefer that mode.
$advanced_mode = config('views.settings')
->get('ui.show.master_display');
// For other users, show the default display only if there are no others, and
// hide it if there's at least one "real" display.
$additional_displays = count($this->displayHandlers) == 1;
return $advanced_mode || $additional_displays;
}