[ Index ]

PHP Cross Reference of Unnamed Project

title

Body

[close]

/lib/yuilib/2in3/2.9.0/build/yui2-carousel/ -> yui2-carousel.js (summary)

The Carousel module provides a widget for browsing among a set of like objects represented pictorially.

File Size: 4480 lines (148 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 19 functions

  setStyles()
  createElement()
  getStyle()
  getStyleIntVal()
  getStyleFloatVal()
  getCarouselItemSize()
  getRevealSize()
  getCarouselItemPosition()
  getFirstVisibleForPosition()
  getScrollOffset()
  scrollPageBackward()
  scrollPageForward()
  setItemSelection()
  showNavigation()
  syncNavigation()
  syncPagerUi()
  getDimensions()
  syncUi()
  updateStateAfterScroll()

Functions
Functions that are not part of a class:

setStyles(el, styles)   X-Ref
Set multiple styles on one element.

param: el {HTMLElement} The element to set styles on
param: style {Object} top:"10px", left:"0px", etc.

createElement(el, attrs)   X-Ref
Create an element, set its class name and optionally install the element
to its parent.

param: el {String} The element to be created
param: attrs {Object} Configuration of parent, class and id attributes.

getStyle(el, style, type)   X-Ref
Get the computed style of an element.

param: el {HTMLElement} The element for which the style needs to be
param: style {String} The style attribute
param: type {String} "int", "float", etc. (defaults to int)

getStyleIntVal(el, style)   X-Ref
No description

getStyleFloatVal(el, style)   X-Ref
No description

getCarouselItemSize(which)   X-Ref
Compute and return the height or width of a single Carousel item
depending upon the orientation.

param: which {String} "height" or "width" to be returned.  If this is

getRevealSize()   X-Ref
Return the size of a part of the item (reveal).


getCarouselItemPosition(pos)   X-Ref
Compute and return the position of a Carousel item based on its
position.

param: position {Number} The position of the Carousel item.

getFirstVisibleForPosition(pos)   X-Ref
Return the index of the first item in the view port for displaying item
in "pos".

param: pos {Number} The position of the item to be displayed

getScrollOffset(delta)   X-Ref
Return the scrolling offset size given the number of elements to
scroll.

param: delta {Number} The delta number of elements to scroll by.

scrollPageBackward(ev, obj)   X-Ref
Scroll the Carousel by a page backward.

param: {Event} ev The event object
param: {Object} obj The context object

scrollPageForward(ev, obj)   X-Ref
Scroll the Carousel by a page forward.

param: {Event} ev The event object
param: {Object} obj The context object

setItemSelection(newpos, oldpos)   X-Ref
Set the selected item.

param: {Number} newpos The index of the new position
param: {Number} oldpos The index of the previous position

showNavigation(hide)   X-Ref
Show or hide navigation.


syncNavigation()   X-Ref
Fire custom events for enabling/disabling navigation elements.


syncPagerUi(page)   X-Ref
Synchronize and redraw the Pager UI if necessary.


getDimensions(el, which)   X-Ref
Get full dimensions of an element.

param: {Object} el The element to get the dimensions of
param: {String} which Get the height or width of an element

syncUi(o)   X-Ref
Handle UI update.
Call the appropriate methods on events fired when an item is added, or
removed for synchronizing the DOM.

param: {Object} o The item that needs to be added or removed

updateStateAfterScroll(item, sentinel)   X-Ref
Update the state variables after scrolling the Carousel view port.

param: {Integer} item The index to which the Carousel has scrolled to.
param: {Integer} sentinel The last element in the view port.



Generated: Thu Aug 11 10:00:09 2016 Cross-referenced by PHPXref 0.7.1