You are here

protected function AddVariantStaticContextConfigure::disableMachineName in Page Manager 8

Same name and namespace in other branches
  1. 8.4 page_manager_ui/src/Form/AddVariantStaticContextConfigure.php \Drupal\page_manager_ui\Form\AddVariantStaticContextConfigure::disableMachineName()

Determines if the machine_name should be disabled.

Parameters

$cached_values:

Return value

bool

Overrides ContextConfigure::disableMachineName

File

page_manager_ui/src/Form/AddVariantStaticContextConfigure.php, line 74
Contains \Drupal\page_manager_ui\Form\AddVariantStaticContextConfigure.

Class

AddVariantStaticContextConfigure

Namespace

Drupal\page_manager_ui\Form

Code

protected function disableMachineName($cached_values, $machine_name) {
  if ($machine_name) {
    return !empty($this
      ->getContexts($cached_values)[$machine_name]);
  }
  return FALSE;
}