You are here

function brightcove_field_theme in Brightcove Video Connect 7.2

Same name and namespace in other branches
  1. 7.3 brightcove_field/brightcove_field.module \brightcove_field_theme()
  2. 7.4 brightcove_field/brightcove_field.module \brightcove_field_theme()
  3. 7.5 brightcove_field/brightcove_field.module \brightcove_field_theme()

Implementation of hook_theme().

File

brightcove_field/brightcove_field.module, line 757
Brightcove field module provides a Content Construction Kit module to developers, allowing them to browse videos in their Brightcove Studio and upload them.

Code

function brightcove_field_theme() {
  $theme = array(
    'brightcove_field_browser' => array(
      'variables' => array(
        'element' => NULL,
      ),
    ),
    'brightcove_field_formatter_default' => array(
      'variables' => array(
        'element' => NULL,
        'instance' => array(),
        'width' => BRIGHTCOVE_DEFAULT_VIDEO_WIDTH,
        'height' => BRIGHTCOVE_DEFAULT_VIDEO_HEIGHT,
      ),
      'file' => 'brightcove_field.formatters.inc',
    ),
    'brightcove_field_player' => array(
      'variables' => array(
        'player' => NULL,
        'video_id' => NULL,
      ),
      'template' => 'brightcove-field-player',
      'pattern' => 'brightcove-field-player',
    ),
    'brightcove_field_dialog' => array(
      'variables' => array(
        'output' => NULL,
        'video_id' => NULL,
        'video_width' => NULL,
        'video_height' => NULL,
        'dialog_width' => NULL,
        'dialog_height' => NULL,
        'destination' => NULL,
        'image_field' => NULL,
        'field_name' => NULL,
        'entity_type' => NULL,
        'style' => NULL,
      ),
      'template' => 'brightcove-field-dialog',
      'pattern' => 'brightcove_field_dialog__',
    ),
    'brightcove_field_entity_link' => array(
      'variables' => array(
        'output' => NULL,
        'video_id' => NULL,
        'destination' => NULL,
        'image_field' => NULL,
        'field_name' => NULL,
        'entity_type' => NULL,
        'style' => NULL,
      ),
      'template' => 'brightcove-field-entity-link',
      'pattern' => 'brightcove_field_entity_link__',
    ),
    'brightcove_field_entity_image' => array(
      'variables' => array(
        'output' => NULL,
        'video_id' => NULL,
        'entity_id' => NULL,
        'image_field' => NULL,
        'field_name' => NULL,
        'entity_type' => NULL,
      ),
      'template' => 'brightcove-field-entity-image',
      'pattern' => 'brightcove_field_entity_image__',
    ),
    'brightcove_field_dialog_image' => array(
      'variables' => array(
        'output' => NULL,
        'video_id' => NULL,
        'video_width' => NULL,
        'video_height' => NULL,
        'dialog_width' => NULL,
        'dialog_height' => NULL,
        'destination' => NULL,
        'image_field' => NULL,
        'field_name' => NULL,
        'entity_type' => NULL,
      ),
      'template' => 'brightcove-field-dialog-image',
      'pattern' => 'brightcove_field_dialog_image__',
    ),
    'brightcove_field_browse_button' => array(
      'variables' => array(
        'element' => NULL,
      ),
      'function' => 'theme_brightcove_field_browse_button',
      'file' => 'theme.inc',
    ),
    'brightcove_field_browse_item' => array(
      'variables' => array(
        'item' => NULL,
      ),
      'file' => 'theme.inc',
    ),
    'brightcove_field_browse_items' => array(
      'variables' => array(
        'item' => NULL,
      ),
      'file' => 'theme.inc',
    ),
    'brightcove_field_embed' => array(
      // TODO when submitting the admin form, do a theme rebuild (form_alter)
      'variables' => array(
        'type' => 'video',
        'player' => NULL,
        'video_id' => NULL,
        'params' => array(),
        'width' => BRIGHTCOVE_DEFAULT_VIDEO_WIDTH,
        'height' => BRIGHTCOVE_DEFAULT_VIDEO_HEIGHT,
      ),
      'function' => 'theme_brightcove_field_embed',
      'file' => 'theme.inc',
    ),
  );
  $theme['brightcove_field_formatter_entity_link_thumbnailURL'] = array(
    'variables' => array(
      'element' => NULL,
      'image' => NULL,
      'style' => NULL,
      'entity_type' => NULL,
      'entity' => NULL,
      'field' => NULL,
      'instance' => NULL,
      'display' => NULL,
      'delta' => NULL,
    ),
    'function' => 'theme_brightcove_field_entity_link',
    'file' => 'brightcove_field.formatters.inc',
  );
  $theme['brightcove_field_formatter_entity_link_videoStillURL'] = array(
    'variables' => array(
      'element' => NULL,
      'image' => NULL,
      'style' => NULL,
      'entity_type' => NULL,
      'entity' => NULL,
      'field' => NULL,
      'instance' => NULL,
      'display' => NULL,
      'delta' => NULL,
    ),
    'function' => 'theme_brightcove_field_entity_link',
    'file' => 'brightcove_field.formatters.inc',
  );
  $theme['brightcove_field_formatter_entity_image_thumbnailURL'] = array(
    'variables' => array(
      'element' => NULL,
      'image' => NULL,
      'style' => NULL,
      'entity_type' => NULL,
      'entity' => NULL,
      'field' => NULL,
      'instance' => NULL,
      'display' => NULL,
      'delta' => NULL,
    ),
    'function' => 'theme_brightcove_field_entity_image',
    'file' => 'brightcove_field.formatters.inc',
  );
  $theme['brightcove_field_formatter_entity_image_videoStillURL'] = array(
    'variables' => array(
      'element' => NULL,
      'image' => NULL,
      'style' => NULL,
      'entity_type' => NULL,
      'entity' => NULL,
      'field' => NULL,
      'instance' => NULL,
      'display' => NULL,
      'delta' => NULL,
    ),
    'function' => 'theme_brightcove_field_entity_image',
    'file' => 'brightcove_field.formatters.inc',
  );
  $theme['brightcove_field_formatter_dialog_player_thumbnailURL'] = array(
    'variables' => array(
      'element' => NULL,
      'image' => NULL,
      'style' => NULL,
      'entity_type' => NULL,
      'entity' => NULL,
      'field' => NULL,
      'instance' => NULL,
      'display' => NULL,
      'delta' => NULL,
    ),
    'function' => 'theme_brightcove_field_dialog_player',
    'file' => 'brightcove_field.formatters.inc',
  );
  $theme['brightcove_field_formatter_dialog_player_videoStillURL'] = array(
    'variables' => array(
      'element' => NULL,
      'image' => NULL,
      'style' => NULL,
      'entity_type' => NULL,
      'entity' => NULL,
      'field' => NULL,
      'instance' => NULL,
      'display' => NULL,
      'delta' => NULL,
    ),
    'function' => 'theme_brightcove_field_dialog_player',
    'file' => 'brightcove_field.formatters.inc',
  );
  $styles = image_styles();
  foreach ($styles as $style) {
    $theme['brightcove_field_formatter_dialog_image_' . $style['name'] . '__thumbnailURL'] = array(
      'variables' => array(
        'element',
      ),
      'function' => 'theme_brightcove_field_dialog_image',
      'file' => 'brightcove_field.formatters.inc',
    );
    $theme['brightcove_field_formatter_dialog_image_' . $style['name'] . '__videoStillURL'] = array(
      'variables' => array(
        'element',
      ),
      'function' => 'theme_brightcove_field_dialog_image',
      'file' => 'brightcove_field.formatters.inc',
    );
    $theme['brightcove_field_formatter_entity_link_image_' . $style['name'] . '__thumbnailURL'] = array(
      'variables' => array(
        'element',
      ),
      'function' => 'theme_brightcove_field_entity_link_image',
      'file' => 'brightcove_field.formatters.inc',
    );
    $theme['brightcove_field_formatter_entity_link_image_' . $style['name'] . '__videoStillURL'] = array(
      'variables' => array(
        'element',
      ),
      'function' => 'theme_brightcove_field_entity_link_image',
      'file' => 'brightcove_field.formatters.inc',
    );
    $theme['brightcove_field_formatter_entity_image_image_' . $style['name'] . '__thumbnailURL'] = array(
      'variables' => array(
        'element',
      ),
      'function' => 'theme_brightcove_field_entity_image_style',
      'file' => 'brightcove_field.formatters.inc',
    );
    $theme['brightcove_field_formatter_entity_image_image_' . $style['name'] . '__videoStillURL'] = array(
      'variables' => array(
        'element',
      ),
      'function' => 'theme_brightcove_field_entity_image_style',
      'file' => 'brightcove_field.formatters.inc',
    );
  }
  $theme["brightcove_field_formatter_metadata"] = array(
    'variables' => array(
      'video' => NULL,
      // video object
      'key' => NULL,
      'label' => NULL,
    ),
    'function' => 'theme_brightcove_field_formatter_metadata',
    'file' => 'brightcove_field.formatters.inc',
  );
  return $theme;
}