class BlockPlaceEventSubscriber implements EventSubscriberInterface (View source)

Properties

protected RequestStack $requestStack

The request stack.

protected AccountInterface $account

The current user.

Methods

__construct(RequestStack $request_stack, AccountInterface $account)

Constructs a \Drupal\block_place\EventSubscriber\BlockPlaceEventSubscriber object.

onBlockPageDisplayVariantSelected(PageDisplayVariantSelectionEvent $event)

Selects the block place override of the block page display variant.

static 
getSubscribedEvents()

{@inheritdoc}

Details

__construct(RequestStack $request_stack, AccountInterface $account)

Constructs a \Drupal\block_place\EventSubscriber\BlockPlaceEventSubscriber object.

Parameters

RequestStack $request_stack

The request stack used to retrieve the current request.

AccountInterface $account

The current user.

onBlockPageDisplayVariantSelected(PageDisplayVariantSelectionEvent $event)

Selects the block place override of the block page display variant.

Parameters

PageDisplayVariantSelectionEvent $event

The event to process.

static getSubscribedEvents()

{@inheritdoc}