Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
K1978

Create custom Loader which returns a given object (no actual loading)

Recommended Posts

Hi,

 

I want to create a custom Loader which will behave as the SWFLoader except that you provide an object when you create an instance of it, and that object is what is returned by target.rawContent in the onComplete callback. Is that at all possible? Could I get a hint on how to do it?

 

In my case I have made an API where you can ask for a group of files and get a normal LoaderMax loader event back. Some of the files being asked for will not always be available. The API I've created will know this by reading a bunch of XML files. For that case I want to return an object instance so that some files in the event oncomplete callback will actually have been loaded by SWFLoader, while others would be "loaded" by my SWFImpersonator. They can all be retireved by getContent(url or name).

 

Any ideas on how to do it?

 

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×