You are here

function panels_required_context::filter in Panels 5.2

Same name and namespace in other branches
  1. 6.3 includes/plugins.inc \panels_required_context::filter()
  2. 6.2 includes/plugins.inc \panels_required_context::filter()
1 call to panels_required_context::filter()
panels_optional_context::filter in includes/plugins.inc
1 method overrides panels_required_context::filter()
panels_optional_context::filter in includes/plugins.inc

File

includes/plugins.inc, line 78
plugins.inc

Class

panels_required_context
This is used to explain to Panels what context is required.

Code

function filter($contexts) {
  $result = array();

  // See which of these contexts are valid
  foreach ($contexts as $cid => $context) {
    if ($context
      ->is_type($this->keywords)) {
      $result[$cid] = $context;
    }
  }
  return $result;
}