1
A Shadowbox "player" is a class that is used specifically for displaying a
2
particular medium. For example, an image player is included for displaying
3
images, a Flash video player is included for playing FLV files, etc.
5
All players should implement the same interface. This makes it easy for the
6
Shadowbox script to know what methods to call and properties to check on player
9
The interface is described here, with some simple explanations of how each
10
method and/or property is to be used.
12
METHOD/PROPERTY DESCRIPTION
14
markup() Produces the HTML markup for the object.
16
onLoad() (optional) Called after the content is loaded and the
17
loading layer is hidden.
19
remove() Removes this object from the DOM.
21
height (number) The height of the object (in pixels).
23
width (number) The width of the object (in pixels).
25
ready (optional, boolean) True if the content is ready to be
26
loaded, false otherwise. Useful when the script should wait
27
until the content loads before proceeding (see below).
29
resizable (optional, boolean) True if the content can be dynamically
30
resized by the script (e.g. images, but not most movie
33
If the ready property is set to false, the script will wait until it is no
34
set to true. This should be set in some callback function within the player
35
class itself. In this case, the object's height and width do not need to be made
36
available immediately (because they may not initially be known). However, in the
37
same callback, the height and width should be set. See the Shadowbox.img class
38
for an example of this behavior.