Reference for FotoSpin CS

Method

Description

nexItem()Move to next item.
prevItem()Move to previous item.
load()Load xml source.
start()Start the tunnel.
stop()Stop the tunnel.
playVideo()Play video when the item have video.
pauseVideo()Pause video.
stopVideo()Complete stop the video.

 

FotoSpin.nextItem()

Availability Flash Player 9.

Edition Flash CS3.

Usage FotoSpin.nextItem()

Returns None

Description Method; Move to next Item.

Code Example :

photospin_mc.nextItem();

 

FotoSpin.prevItem()

Availability Flash Player 9.

Edition Flash CS3.

Usage FotoSpin.prevItem()

Returns None

Description Method; Move to previous item.

Code Example :

photospin_mc.prevItem();

 

FotoSpin.load()

Availability Flash Player 9.

Edition Flash CS3.

Usage FotoSpin.load(xml)

Parameters

xml: URL of external xml file. Or XML object.

Returns None

Description Method; Load the xml source and setup FotoSpin

Code Example :

//Load the source xml named photo.xml.  
photospin_mc.load("photo.xml");

 

FotoSpin.start()

Availability Flash Player 9.

Edition Flash CS3.

Usage FotoSpin.start()

Returns None

Description Method; Start the tunnel if xml is loaded and the tunnel not started yet.

Code Example :

//Load the xml   photospin_mc.load("photo.xml"); //Start
photospin_mc.start();

 

FotoSpin.stop()

Availability Flash Player 9.

Edition Flash CS3.

Usage FotoSpin.start()

Returns None

Description Method; Stop the tunnel when the tunnel is in started state.

Code Example :


photospin_mc.stop();

FotoSpin.playVideo()

Availability Flash Player 9.

Edition Flash CS3.

Usage FotoSpin.playVideo()

Returns None

Description Method; Start playing the video.

Code Example :

photospin_mc.playVideo();

 

FotoSpin.pauseVideo()

Availability Flash Player 9.

Edition Flash CS3.

Usage FotoSpin.pauseVideo()

Returns None

Description Method; Pause the video.

Code Example :


photospin_mc.pauseVideo();

 

FotoSpin.stopVideo()

Availability Flash Player 9.

Edition Flash CS3.

Usage FotoSpin.stopVideo()

Returns None

Description Method; Stop the video.

Code Example :


photospin_mc.stopVideo();

To use event, you need to import the library:

import com.digicrafts.events.*;

Event

Object

Description

itemClickItemEvent.CLICK

Broadcast when mouse clicked on the item.

itemMouseOverItemEvent.MOUSE_OVERBroadcast when mouse over on the item.
itemMouseOutItemEvent.MOUSE_OUTBroadcast when mouse move outside the item after mouse over.
 itemSelect ItemEvent.SELECTBroadcast when the photo appear in front.
completeEvent.COMPLETEBroadcast when the all buffer images loaded.


Code Example :

import com.digicrafts.events.*;    
function itemH(event:ItemEvent):void {
switch(event.type) {
//Mouse Over Event
case ItemEvent.MOUSE_OVER:
//do something when mouse over an item
//You can get the item item by
trace(event.index);
//You can get the data object by
trace(event.item);
// You can get parameter inside data object by
trace(event.item.source);
trace(event.item.title);
trace(event.item.description);
trace(event.item.link);
trace(event.item.contentURL);
trace(event.item.width);
trace(event.item.height);
break;
//Mouse Out Event
case ItemEvent.MOUSE_OUT:
//do something when mouse out an item
break;
//Mouse Click Event
case ItemEvent.CLICK:
//do something when mouse click an item
break;
//Photo Selected
case ItemEvent.SELECT:
//do something when the thumbnail selected
break;
//Photo complete loaded
case ItemEvent.CLOSE:
//do something when all photo loaded
break;
}
}
album_mc.addEventListener(ItemEvent.MOUSE_OVER,itemH);
album_mc.addEventListener(ItemEvent.MOUSE_OUT,itemH);
album_mc.addEventListener(ItemEvent.CLICK,itemH);
album_mc.addEventListener(ItemEvent.SELECT,itemH);
album_mc.addEventListener(ItemEvent.COMPLETE,itemH);

Property

Type

Description

Default Value

Possible Value

dataProvider
DataProvider
Get the DataProvider for the components 
sourceStringThe path to the xml generate by Photoshop Web Gallery Function, Flickr rss or Youtube rss.
photo/photos.xml
url to the xml file
useThumbnailBooleanDetermine the use of thumbnail image in the xml source as image. truetrue/false
proxyStringThe proxy script for cross domain issue.  url to the proxy script
autostartBooleanEnable auto start when xml and image loaded
true
true/false
itemCountNumberThe item count in for the ablum6Positive Number
itemWidthNumberThe prefer width of each item 100Positive Number
itemHeightNumberThe prefer height of each item 100Positive Number
curvatureNumberThe degree of circular item occupied.90+ 180
cameraXNumberX position of the camera0+/- 180
cameraYNumberY position of the camera0+/- 180
itemShadowNumberThe value of shadow.70.0 - 1.0
itemMirrorNumberThe value of mirror effect.50.0 - 1.0
transitionTimeNumberThe transition time of the animation. ( in seconds)1 secPositive Number
transitionTypeStringThe transition type of the animation.easeOutSineAny String
itemOverColorNumberSet the color of glow when mouse over.0x000000Color Value
camFollowMouseNumberValue of movment for the camera following mouse.0Positive Number
keyboardControlEnabledBooleanEnable/Disable the keyboard control.truetrue/false
touchScrollEnabledBooleanEnable/Disable the touch scroll control.truetrue/false
wheelScrollEnabledBooleanEnable/Disable the mouse wheel control.truetrue/false
itemClickActionStringDetermine the action do when mouse click on the items. "GOTO""GOTO,GETURL"
itemOverActionStringDetermine the action do when mouse over on the items"GLOW""GLOW"
captionTargetNameStringThe instance name of dynamic text field use for hold the caption.  Any instance name of dynamic text field
nextButtonTargetNameStringThe instance name of Button/SimpleButton use to control the move to next item Any instance name of Button/ SimpleButton
prevButtonTargetNameStringThe instance name of Button/SimpleButton use to control the move to previous item Any instance name of Button/ SimpleButton
scrollBarTargetNameStringThe instance name of UIScrollbar/Slider use to control the menu movement Any instance name of Button/ SimpleButton
loaderSkinStringThe class name use of the skin for the loading animation  Any class name of movieclip symbol
 
Item Parameter Name Description
1 source The path to the xml generate by Photoshop Web Gallery Function, Flickr rss or Youtube rss.
2 useThumbnail Enable/disable using thumbnail image defined in the xml for image source.
3 autostart Enable auto start when xml and image loaded
4 proxy The proxy script for cross domain issue.
     
 
Item Parameter Name Description
1 itemCount The item count appear in the screen
2 itemHeight The prefered height of each item
3 itemWidth The prefered width of each item
4 curvature The degree of space which items occupied.
5 cameraX X position of the camera view
6 cameraY Y position of the camera view
     
 
Item Parameter Name Description
1 itemOverAction Enable/disable glow effect when mouse over.
2 itemClickAction Enable/disable getURL action when click on item. Default will link to the image. It will link to url specify in xml <link> tag if <link> is not empty .
3 This enable item goto center when click on item.
4 camFollowMouse Value of movment for the camera following mouse.
5 transitionType The transition type of the animation.
6 transitionTime The transition time of the animation. ( in seconds)
7 itemOverColor The glow color when mouse over.
     
 
Item Parameter Name Description
1 keyboardControlEnabled Enable/Disable the keyboard control.
2 touchScrollEnabled Enable/Disable the touch scroll control.
3 wheelScrollEnabled Enable/Disable the mouse wheel control.
4 nextButtonTargetName The instance name of Button/SimpleButton use to control the move to next item
5 prevButtonTargetName The instance name of Button/SimpleButton use to control the move to previous item
6 scrollBarTargetName The instance name of UIScrollbar/Slider use to control the menu movement
7 captionTargetName The instance name of dynamic text field use for hold the caption.
     
 
Item Parameter Name Description
1 itemMirror The value of mirror effect.
2 itemShadow The value of shadow effect.
3 loaderSkin The class name use of the skin for the loading animation.
     
 
Item Parameter Name Description
1
-
Load Preset Button
2
-
Save Preset Button