Fork me on GitHub

API Documentation


Extends GLGE.Events.
FilePreloader class
Defined in: glge_filepreloader.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
Field Summary
Field Attributes Field Name and Description
 
0 - 100
 
Specifies how many file sizes has been collected
Method Summary
Method Attributes Method Name and Description
 
addFile(url, type, callback)
Add a file which has to be loaded
 
addFileRef(file)
Same as addFile.
 
getFile(url)
This function returns information about one file.
 
This function returns a list (an array) of all loaded files.
 
Start loading
Methods borrowed from class GLGE.Events:
addEventListener, fireEvent, removeEventListener
Class Detail
GLGE.FilePreloader()
Field Detail
files
0 - 100

progress
Specifies how many file sizes has been collected
Method Detail
addFile(url, type, callback)
Add a file which has to be loaded
Parameters:
{string} url
The url of the file.
{string} type
Defines the type of the requested file. "image" or "xml"
{function} callback Optional
Call this function when the file is loaded and pass the loaded content.

addFileRef(file)
Same as addFile. But instead of creating a new file object use an existing one.
Parameters:
{object} file
The file to add.

getFile(url)
This function returns information about one file.
Parameters:
{string} url
The url of the file.

getLoadedFiles()
This function returns a list (an array) of all loaded files.

start()
Start loading

Documentation generated by JsDoc Toolkit 2.4.0 on Sun Feb 12 2012 14:20:23 GMT+0000 (GMT)