You are here

class VideoFilter in Video Filter 8

Same name in this branch
  1. 8 src/Controller/VideoFilter.php \Drupal\video_filter\Controller\VideoFilter
  2. 8 src/Annotation/VideoFilter.php \Drupal\video_filter\Annotation\VideoFilter
  3. 8 src/Plugin/Filter/VideoFilter.php \Drupal\video_filter\Plugin\Filter\VideoFilter
  4. 8 src/Plugin/CKEditorPlugin/VideoFilter.php \Drupal\video_filter\Plugin\CKEditorPlugin\VideoFilter

Defines the "VideoFilter" plugin.

Plugin annotation


@CKEditorPlugin(
  id = "video_filter",
  label = @Translation("Video Filter")
)

Hierarchy

Expanded class hierarchy of VideoFilter

File

src/Plugin/CKEditorPlugin/VideoFilter.php, line 18

Namespace

Drupal\video_filter\Plugin\CKEditorPlugin
View source
class VideoFilter extends PluginBase implements CKEditorPluginInterface, CKEditorPluginButtonsInterface {

  /**
   * {@inheritdoc}
   */
  public function getDependencies(Editor $editor) {
    return [];
  }

  /**
   * {@inheritdoc}
   */
  public function getLibraries(Editor $editor) {
    return [
      'core/drupal.ajax',
    ];
  }

  /**
   * {@inheritdoc}
   */
  public function isInternal() {
    return FALSE;
  }

  /**
   * {@inheritdoc}
   */
  public function getFile() {
    return drupal_get_path('module', 'video_filter') . '/assets/video_filter.js';
  }

  /**
   * {@inheritdoc}
   */
  public function getButtons() {
    return [
      'video_filter' => [
        'label' => t('Video Filter'),
        'image' => drupal_get_path('module', 'video_filter') . '/assets/icon.png',
      ],
    ];
  }

  /**
   * {@inheritdoc}
   */
  public function getConfig(Editor $editor) {
    return [
      'video_filter_dialog_title' => t('Video Filter'),
    ];
  }

}

Members

Namesort descending Modifiers Type Description Overrides
PluginBase::$configuration protected property Configuration information passed into the plugin. 1
PluginBase::$pluginDefinition protected property The plugin implementation definition. 1
PluginBase::$pluginId protected property The plugin_id.
PluginBase::DERIVATIVE_SEPARATOR constant A string which is used to separate base plugin IDs from the derivative ID.
PluginBase::getBaseId public function Gets the base_plugin_id of the plugin instance. Overrides DerivativeInspectionInterface::getBaseId
PluginBase::getDerivativeId public function Gets the derivative_id of the plugin instance. Overrides DerivativeInspectionInterface::getDerivativeId
PluginBase::getPluginDefinition public function Gets the definition of the plugin implementation. Overrides PluginInspectionInterface::getPluginDefinition 3
PluginBase::getPluginId public function Gets the plugin_id of the plugin instance. Overrides PluginInspectionInterface::getPluginId
PluginBase::isConfigurable public function Determines if the plugin is configurable.
PluginBase::__construct public function Constructs a \Drupal\Component\Plugin\PluginBase object. 92
VideoFilter::getButtons public function Returns the buttons that this plugin provides, along with metadata. Overrides CKEditorPluginButtonsInterface::getButtons
VideoFilter::getConfig public function Returns the additions to CKEDITOR.config for a specific CKEditor instance. Overrides CKEditorPluginInterface::getConfig
VideoFilter::getDependencies public function Returns a list of plugins this plugin requires. Overrides CKEditorPluginInterface::getDependencies
VideoFilter::getFile public function Returns the Drupal root-relative file path to the plugin JavaScript file. Overrides CKEditorPluginInterface::getFile
VideoFilter::getLibraries public function Returns a list of libraries this plugin requires. Overrides CKEditorPluginInterface::getLibraries
VideoFilter::isInternal public function Indicates if this plugin is part of the optimized CKEditor build. Overrides CKEditorPluginInterface::isInternal