Method | Description |
---|---|
load() | Load source. |
Availability Flash Player 9.
Edition Flash CS3.
Usage SimpleLoader.load(url)
Parameters
url: URL of external png, jpg or swf.
Returns None
Description Method; Load the image or movie.
Code Example :
//oad the image or movie.
loader_mc.load("photo.jpg");
To use event, you need to import the library:
import flash.events.*;
Event | Object | Description |
---|---|---|
complete | Event.COMPLETE | Broadcast when the image/movie just loaded. |
change | Event.CHANGE | Broadcast when the fade in just completed and the image apply. |
init | Event.INIT | Dispatched when the properties and methods of a loaded SWF file are accessible. |
ioError | IOErrorEvent.IO_ERROR | Dispatched when an input or output error occurs that causes a load operation to fail. |
progress | ProgressEvent.PROGRESS | Dispatched when data is received as the download operation progresses. |
Code Example :
import com.digicrafts.controls.*;
function itemH(event:ItemEvent):void {
switch(event.type) {
//Event when load completed
case Event.COMPLETE:
brea;
}
}
loader_mc.addEventListener(Event.COMPLETE,itemH);
Property | Type | Description | Default Value | Possible Value |
---|---|---|---|---|
source | String | The path to the jpg, png or swf. | "" | url to the file |
content | DisplayObject | The content of the loaded item. | readonly | readonly |
autoLoad | Boolean | Auto load the source when the loader start. | true | true/false |
border | Number | The value of border | 1 | Positive Number |
borderColor | Number | Set the color of glow when mouse over. | 0x000000 | Color Value |
shadow | Number | The value of shadow effect | 4 | Positive Number |
resizeType | String | The type of auto resize of the content | AUTO | AUTO, AUTO_HEIGHT, AUTO_WIDTH, NONE |
fadeTime | Number | The transition time of the animation. ( in seconds) | 1 sec | Positive Number |
fadeTransitionType | String | The transition type of the animation. | easeOutSine | Any String |
resizeTime | Number | The transition time of the animation. ( in seconds) | 1 sec | Positive Number |
resizeTransitionType | String | The transition type of the animation. | easeOutSine | Any String |
fcConnect | String | The instance name of Digicrafts component which support FcConnect | "" | Any instance name of component |
loaderSkin | String | The class name use of the skin for the loading animation | "" | Any class name of movieclip symbol |
![]() |
| |||||||||||||||||||||
![]() |
| |||||||||||||||||||||
![]() |
| |||||||||||||||||||||
![]() |
|