public function VideoEmbedField::__construct in Magnific Popup 8
Same name and namespace in other branches
- 8.2 src/Plugin/Field/FieldFormatter/VideoEmbedField.php \Drupal\magnific_popup\Plugin\Field\FieldFormatter\VideoEmbedField::__construct()
Constructs a new instance of the plugin.
Parameters
string $plugin_id: The plugin_id for the formatter.
mixed $plugin_definition: The plugin implementation definition.
\Drupal\Core\Field\FieldDefinitionInterface $field_definition: The definition of the field to which the formatter is associated.
array $settings: The formatter settings.
string $label: The formatter label display setting.
string $view_mode: The view mode.
array $third_party_settings: Third party settings.
\Drupal\Core\Render\RendererInterface $renderer: The renderer.
\Drupal\Core\Field\FormatterInterface $thumbnail_formatter: The field formatter for thumbnails.
\Drupal\Core\Field\FormatterInterface $video_formatter: The field formatter for videos.
Overrides FormatterBase::__construct
File
- src/
Plugin/ Field/ FieldFormatter/ VideoEmbedField.php, line 73
Class
- VideoEmbedField
- Magnific Popup FieldFormatter for Video Embed Field.
Namespace
Drupal\magnific_popup\Plugin\Field\FieldFormatterCode
public function __construct($plugin_id, $plugin_definition, FieldDefinitionInterface $field_definition, array $settings, $label, $view_mode, array $third_party_settings, RendererInterface $renderer, FormatterInterface $thumbnail_formatter, FormatterInterface $video_formatter) {
parent::__construct($plugin_id, $plugin_definition, $field_definition, $settings, $label, $view_mode, $third_party_settings);
$this->thumbnailFormatter = $thumbnail_formatter;
$this->videoFormatter = $video_formatter;
$this->renderer = $renderer;
}