shortcut_preprocess_block

shortcut_preprocess_block(&$variables) Implements hook_preprocess_HOOK() for block templates. File core/modules/shortcut/shortcut.module, line 294 Allows users to manage customizable lists of shortcut links. Code function shortcut_preprocess_block(&$variables) { if ($variables['configuration']['provider'] == 'shortcut') { $variables['attributes']['role'] = 'navigation'; } }

shortcut_renderable_links

shortcut_renderable_links($shortcut_set = NULL) Returns an array of shortcut links, suitable for rendering. Parameters \Drupal\shortcut\ShortcutSetInterface $shortcut_set: (optional) An object representing the set whose links will be displayed. If not provided, the user's current set will be displayed. Return value \Drupal\shortcut\ShortcutInterface[] An array of shortcut links, in the format returned by the menu system. File core/modules/shortcut/shortcut.module, line 254 Allows users to man

shortcut_current_displayed_set

shortcut_current_displayed_set($account = NULL) Returns the current displayed shortcut set for the provided user account. Parameters $account: (optional) The user account whose shortcuts will be returned. Defaults to the currently logged-in user. Return value An object representing the shortcut set that should be displayed to the current user. If the user does not have an explicit shortcut set defined, the default set is returned. File core/modules/shortcut/shortcut.module, line 164 Allows us

shortcut_help

shortcut_help($route_name, RouteMatchInterface $route_match) Implements hook_help(). File core/modules/shortcut/shortcut.module, line 19 Allows users to manage customizable lists of shortcut links. Code function shortcut_help($route_name, RouteMatchInterface $route_match) { switch ($route_name) { case 'help.page.shortcut': $output = '<h3>' . t('About') . '</h3>'; $output .= '<p>' . t('The Shortcut module allows users to create sets of <em>shortcut<

shortcut_preprocess_page_title

shortcut_preprocess_page_title(&$variables) Implements hook_preprocess_HOOK() for page title templates. File core/modules/shortcut/shortcut.module, line 303 Allows users to manage customizable lists of shortcut links. Code function shortcut_preprocess_page_title(&$variables) { // Only display the shortcut link if the user has the ability to edit // shortcuts and if the page's actual content is being shown (for example, // we do not want to display it on "access denied" or "page

ShortcutSetStorageInterface::getAssignedToUser

public ShortcutSetStorageInterface::getAssignedToUser($account) Get the name of the set assigned to this user. Parameters \Drupal\user\Entity\User $account: The user account. Return value string The name of the shortcut set assigned to this user. File core/modules/shortcut/src/ShortcutSetStorageInterface.php, line 55 Class ShortcutSetStorageInterface Defines an interface for shortcut_set entity storage classes. Namespace Drupal\shortcut Code public function getAssignedToUser($account

ShortcutSetStorageInterface::deleteAssignedShortcutSets

public ShortcutSetStorageInterface::deleteAssignedShortcutSets(ShortcutSetInterface $entity) Delete shortcut sets assigned to users. Parameters \Drupal\shortcut\ShortcutSetInterface $entity: Delete the user assigned sets belonging to this shortcut. File core/modules/shortcut/src/ShortcutSetStorageInterface.php, line 44 Class ShortcutSetStorageInterface Defines an interface for shortcut_set entity storage classes. Namespace Drupal\shortcut Code public function deleteAssignedShortcutSet

ShortcutSetStorageInterface::getDefaultSet

public ShortcutSetStorageInterface::getDefaultSet(AccountInterface $account) Gets the default shortcut set for a given user account. Parameters \Drupal\Core\Session\AccountInterface $account: The user account whose default shortcut set will be returned. Return value \Drupal\shortcut\ShortcutSetInterface An object representing the default shortcut set. File core/modules/shortcut/src/ShortcutSetStorageInterface.php, line 77 Class ShortcutSetStorageInterface Defines an interface for shortcu

ShortcutSetStorageInterface::countAssignedUsers

public ShortcutSetStorageInterface::countAssignedUsers(ShortcutSetInterface $shortcut_set) Get the number of users who have this set assigned to them. Parameters \Drupal\shortcut\ShortcutSetInterface $shortcut_set: The shortcut to count the users assigned to. Return value int The number of users who have this set assigned to them. File core/modules/shortcut/src/ShortcutSetStorageInterface.php, line 66 Class ShortcutSetStorageInterface Defines an interface for shortcut_set entity storage

ShortcutSetStorageInterface::unassignUser

public ShortcutSetStorageInterface::unassignUser($account) Unassigns a user from any shortcut set they may have been assigned to. The user will go back to using whatever default set applies. Parameters $account: A user account that will be removed from the shortcut set assignment. Return value bool TRUE if the user was previously assigned to a shortcut set and has been successfully removed from it. FALSE if the user was already not assigned to any set. File core/modules/shortcut/src/ShortcutS