protected function StaticContextConfigure::getContexts in Page Manager 8.4
Same name and namespace in other branches
- 8 page_manager_ui/src/Form/StaticContextConfigure.php \Drupal\page_manager_ui\Form\StaticContextConfigure::getContexts()
Custom logic for retrieving the contexts array from cached_values.
Parameters
$cached_values:
Return value
\Drupal\Core\Plugin\Context\ContextInterface[]
Overrides ContextConfigure::getContexts
File
- page_manager_ui/
src/ Form/ StaticContextConfigure.php, line 73
Class
Namespace
Drupal\page_manager_ui\FormCode
protected function getContexts($cached_values) {
/** @var $page_variant \Drupal\page_manager\PageVariantInterface */
$page_variant = !empty($cached_values['page_variant']) ? $cached_values['page_variant'] : NULL;
if (is_null($page_variant)) {
$page_variant = $this
->getPageVariant($cached_values);
}
return $page_variant
->getContexts();
}