FieldTitleSource.php in Lightgallery 8
File
src/Field/FieldTitleSource.php
View source
<?php
namespace Drupal\lightgallery\Field;
use Drupal\lightgallery\Group\GroupLightgalleryCore;
class FieldTitleSource extends FieldBase {
public function appliesToViews() {
return FALSE;
}
protected function setDefaultValue() {
return NULL;
}
protected function setOptions() {
return [
'Drupal\\lightgallery\\Manager\\LightgalleryManager',
'getImageSourceFields',
];
}
protected function setName() {
return 'title_source';
}
protected function setTitle() {
return 'Title source';
}
protected function setType() {
return FieldTypesEnum::SELECT;
}
protected function setDescription() {
return 'The image value that should be used for the title.';
}
protected function setGroup() {
return new GroupLightgalleryCore();
}
}