Method | Description |
---|---|
gotoItem() | Move to the item with specified index number. |
nextItem() | Move to next item. |
prevItem() | Move to previous item. |
load() | Load xml source. |
addItemAt() | Add a new item with specify index. |
addItem() | Add a new item at the end. |
removeItemAt() | Remove an item with specify index from PhotoFLIP CS. |
removeItem() | Remove the last item. |
Availability Flash Player 9.
Edition Flash CS3.
Usage PhotoFLIP.gotoItem(index)
Parameters index: index number of each item. From left to right, 0 to item max.
Returns None
Description Method; Move to the item with specified index.
Code Example :
PhotoFLIP_mc.gotoItem(10);
Availability Flash Player 9.
Edition Flash CS3.
Usage PhotoFLIP.nextItem()
Returns None
Description Method; Move to next item.
Code Example :
PhotoFLIP_mc.nextItem();
Availability Flash Player 9.
Edition Flash CS3.
Usage PhotoFLIP.prevItem()
Returns None
Description Method; Move to previous item.
Code Example :
PhotoFLIP_mc.prevItem();
Availability Flash Player 9.
Edition Flash CS3.
Usage PhotoFLIP.setTextFormat(xml)
Parameters
xml: URL of external xml file. Or XML object.
Returns None
Description Method; Load the xml source and setup photoFLIP
Code Example :
//Load the source xml named photo.xml.
PhotoFLIP_mc.load("photo.xml");
Availability Flash Player 9.
Edition Flash CS3.
Usage PhotoFLIP.addItemAt(object,index)
Parameters object which defined the properties of the item. index: position index which the item add. From left to right, 0 to item max.
Returns None
Description Method; Add a new item with specified index.
Code Example :
//define a item which have linkage name 'p' , type embed bitmap
var item:Object = {source:"p",width:286,height:354,title:"teset", type:"bitmapasset"};
PhotoFLIP_mc.addItemAt(item,10);
Availability Flash Player 9.
Edition Flash CS3.
Usage PhotoFLIP.addItem(item)
Parameters item: object which defined the properties of the item.
Returns None
Description Method; Add a new item at the end.
Code Example :
//define a item which have linkage name 'p' , type embed bitmap
var item:Object = {source:"p",width:286,height:354,title:"teset", type:"bitmapasset"};
PhotoFLIP_mc.addItem(item);
Availability Flash Player 9.
Edition Flash CS3.
Usage PhotoFLIP.removeItemAt(index)
Parameters index: position index which the item add. From left to right, 0 to item max.
Returns None
Description Method; Remove an item with specified index.
Code Example :
PhotoFLIP_mc.removeItemAt(10);
Availability Flash Player 9.
Edition Flash CS3.
Usage PhotoFLIP.removeItem()
Returns None
Description Method; Remove an item from the end.
Code Example :
PhotoFLIP_mc.removeItem();
Event | Constant | Description |
---|---|---|
itemClick | ItemEvent.CLICK | Broadcast when mouse clicked on the item. |
itemMouseOver | ItemEvent.MOUSE_OVER | Broadcast when mouse over on the item. |
itemMouseOut | ItemEvent.MOUSE_OUT | Broadcast when mouse move outside the item after mouse over. |
itemMouseUp | ItemEvent.MOUSE_UP | Broadcast when mouse button up after mouse button down on an item. |
itemMouseDown | ItemEvent.MOUSE_DOWN | Broadcast when mouse button down on an item. |
itemSelect | ItemEvent.SELECT | Broadcast when the item moved to the center and stop. |
itemChange | Event.CHANGE | Broadcast just after change the current focus item by calling gotoItem() function or click on other item. |
complete | Event.COMPLETE | Broadcast 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
trace(event.item.title);
trace(event.item.link);
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;
//Mouse Click Event
case ItemEvent.SELECT:
//do something when an item selected
break;
}
}
menu_mc.addEventListener(ItemEvent.MOUSE_OVER,itemH);
menu_mc.addEventListener(ItemEvent.MOUSE_OUT,itemH);
menu_mc.addEventListener(ItemEvent.CLICK,itemH);
menu_mc.addEventListener(ItemEvent.SELECT,itemH);
Property | Type | Description | Default Value | Possible Value |
---|---|---|---|---|
length | Number | Get number of item in current album. | Read Only | |
source | String | The path to the xml generate by Photoshop Web Gallery Function, Flickr rss or Youtube rss. | photo/photos.xml | url to the xml file |
useThumbnail | Boolean | Determine the use of thumbnail image in the xml source as image. | true | true/false |
proxy | String | The proxy script for cross domain issue. | url to the proxy script | |
buffer | Number | Number of image preloaded before the appear of the photoflip. | 10 | Positive Number |
maxDimension | Number | The maximum dimension of the item. | 120 | Positive Number |
popItemScale | Number | The scale of the center popup item related to the size of other item (maxDimension). | 1.2 | Number |
itemDistance | Number | Distance between each item. | 50 | Any positive number. |
popupItemDistance | Number | Distance between the center popup item and other items. | 80 | Any positive number. |
itemScaleRatio | Number | The ratio of size for each item from the center to the side. | 0.95 | +/- 1 |
initPosition | Number | The initialize selected item. Set to -1 means Auto Center. | -1 | -1 and Any positive number. |
vPerspective | Number | Set the vertical percentage of perspective scale. | 0.6 | 0.0 - 1.0 |
hPerspective | Number | Set the horizontal percentage of perspective scale. | 0.7 | 0.0 - 1.0 |
border | Number | Border size of the item. | 1 | Any positive number. |
borderColor | Number | Border color. | 0xffffff | Number in hex format 0x000000 |
borderHighlight | Number | Border size of the highlighted item. | 1 | Any positive number. |
borderHighlightColor | Number | Border color of the highlighted item.. | 0xffffff | Number in hex format 0x000000 |
shadow | Number | Set the value of shadow effect. | 0.5 | 0.0 - 1.0 |
mirror | Number | Set the value of mirror effect. | 0.3 | 0.0 - 1.0 |
touchScrollEnabled | Boolean | Enable/Disable the touch scroll. | true | true/false |
gotoCenterAction | String | Determine the mouse action to fire the goto center animation action. | NONE | NONE,CLICK |
getURLAction | String | Determine the mouse action to fire the getURL action of each item. | NONE | NONE,CLICK |
captionTargetName | String | The instance name of dynamic text field use for hold the caption. | Any instance name of dynamic text field | |
scrollBarTargetName | String | The instance name of UIScroller/Slider use to control the scrolling of PhotoFLIP | Any instance name of UIScroller/Slider | |
loaderSkin | String | The class name use of the skin for the loading animation | Any class name of movieclip symbol |
| |||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||
|