Jump to content
Search Community

Can you change a loader's property after the fact?

junky test
Moderator Tag

Recommended Posts

is it possible to change the settings of a loader after the files been loaded? Take for instance a loader with these params:

 

{name:"why_video1", bgColor:0xffffff, width:stage.stageWidth, height:stage.stageHeight, scaleMode:"proportionalInside", hAlign:"left", vAlign:"top", crop:true})

 

and say you wanted to change hAlign to center and vAlign to center when the file goes into fullscreen. Is it possible to change these on the fly? Or once their set their set?

Link to comment
Share on other sites

And it appears that you can:

 

why_video1.content.vAlign = "center"

why_video1.content.bgAlpha = 0 //Changes the bgColor to zero alpha.

 

Love it. What can loaderMax not do!

Indeed, you can set those properties directly on the ContentDisplay object (as you discovered) anytime.

 

You can see all the other properties available by inspecting at the ASDocs: http://www.greensock.com/as/docs/tween/ ... splay.html

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.
×
×
  • Create New...