You are here

function hook_views_slideshow_widget_info in Views Slideshow 7.3

Same name and namespace in other branches
  1. 8.3 views_slideshow.api.inc \hook_views_slideshow_widget_info()
  2. 6.3 views_slideshow.api.php \hook_views_slideshow_widget_info()

Define new widgets (pagers, controls, counters).

Available events for accepts and calls

  • pause
  • play
  • nextSlide
  • previousSlide
  • goToSlide
  • transitionBegin
  • transitionEnd.

Return value

array Array keyed by the widget names.

Related topics

1 function implements hook_views_slideshow_widget_info()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

views_slideshow_views_slideshow_widget_info in ./views_slideshow.module
Implements hook_views_slideshow_widget_info().
3 invocations of hook_views_slideshow_widget_info()
template_preprocess_views_slideshow in theme/views_slideshow.theme.inc
Implements hook_preprocess_views_slideshow().
views_slideshow_plugin_style_slideshow::options_form in ./views_slideshow_plugin_style_slideshow.inc
Build the settings form for the view.
views_slideshow_views_slideshow_option_definition in ./views_slideshow.module
Implements hook_views_slideshow_option_definition().

File

./views_slideshow.api.php, line 136
Hooks provided by Views Slideshow.

Code

function hook_views_slideshow_widget_info() {
  return array(
    'views_slideshow_pager' => array(
      'name' => t('Pager'),
      'accepts' => array(
        'transitionBegin' => array(
          'required' => TRUE,
        ),
        'goToSlide' => array(),
        'previousSlide' => array(),
        'nextSlide' => array(),
      ),
      'calls' => array(
        'goToSlide',
        'pause',
        'play',
      ),
    ),
    'views_slideshow_controls' => array(
      'name' => t('Controls'),
      'accepts' => array(
        'pause' => array(
          'required' => TRUE,
        ),
        'play' => array(
          'required' => TRUE,
        ),
      ),
      'calls' => array(
        'nextSlide',
        'pause',
        'play',
        'previousSlide',
      ),
    ),
    'views_slideshow_slide_counter' => array(
      'name' => t('Slide Counter'),
      'accepts' => array(
        'transitionBegin' => array(
          'required' => TRUE,
        ),
        'goToSlide' => array(),
        'previousSlide' => array(),
        'nextSlide' => array(),
      ),
      'calls' => array(),
    ),
  );
}