Same name in other branches
- 8.x-4.x src/ViewsSlideshowWidgetBase.php \Drupal\views_slideshow\ViewsSlideshowWidgetBase
Provides basic functionality for Views slideshow widgets.
Hierarchy
- class \Drupal\views_slideshow\ViewsSlideshowWidgetBase extends \Drupal\Component\Plugin\PluginBase implements \Drupal\views_slideshow\ViewsSlideshowWidgetInterface uses \Drupal\Core\StringTranslation\StringTranslationTrait
Expanded class hierarchy of ViewsSlideshowWidgetBase
3 files declare their use of ViewsSlideshowWidgetBase
- ControlsText.php in src/
Plugin/ ViewsSlideshowWidget/ ControlsText.php - PagerBullets.php in src/
Plugin/ ViewsSlideshowWidget/ PagerBullets.php - PagerFields.php in src/
Plugin/ ViewsSlideshowWidget/ PagerFields.php
File
-
src/
ViewsSlideshowWidgetBase.php, line 12
Namespace
Drupal\views_slideshowView source
abstract class ViewsSlideshowWidgetBase extends PluginBase implements ViewsSlideshowWidgetInterface {
use StringTranslationTrait;
/**
* {@inheritdoc}
*/
public function __construct(array $configuration, $plugin_id, $plugin_definition) {
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this->setConfiguration($configuration);
}
/**
* {@inheritdoc}
*/
public function getTitle() {
return $this->pluginDefinition['title'];
}
/**
* {@inheritdoc}
*/
public function buildConfigurationForm(array $form, FormStateInterface $form_state) {
return [];
}
/**
* {@inheritdoc}
*/
public function validateConfigurationForm(array &$form, FormStateInterface $form_state) {
}
/**
* {@inheritdoc}
*/
public function defaultConfiguration() {
return [];
}
/**
* {@inheritdoc}
*/
public function getConfiguration() {
return [
'id' => $this->getPluginId(),
] + $this->configuration;
}
/**
* {@inheritdoc}
*/
public function setConfiguration(array $configuration) {
$this->configuration = $configuration + $this->defaultConfiguration();
return $this;
}
/**
* {@inheritdoc}
*/
public function submitConfigurationForm(array &$form, FormStateInterface $form_state) {
}
/**
* {@inheritdoc}
*/
public function calculateDependencies() {
return [];
}
/**
* {@inheritdoc}
*/
public function checkCompatiblity($view) {
return TRUE;
}
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overriden Title | Overrides |
---|---|---|---|---|---|
ViewsSlideshowWidgetBase::buildConfigurationForm | public | function | 2 | ||
ViewsSlideshowWidgetBase::calculateDependencies | public | function | |||
ViewsSlideshowWidgetBase::checkCompatiblity | public | function | Check if the widget is compatible with the current view configuration. | Overrides ViewsSlideshowWidgetInterface::checkCompatiblity | 1 |
ViewsSlideshowWidgetBase::defaultConfiguration | public | function | 2 | ||
ViewsSlideshowWidgetBase::getConfiguration | public | function | |||
ViewsSlideshowWidgetBase::getTitle | public | function | |||
ViewsSlideshowWidgetBase::setConfiguration | public | function | |||
ViewsSlideshowWidgetBase::submitConfigurationForm | public | function | |||
ViewsSlideshowWidgetBase::validateConfigurationForm | public | function | |||
ViewsSlideshowWidgetBase::__construct | public | function |