1114rk
Content Type
Profiles
Forums
Store
Blog
Product
Showcase
FAQ
Downloads
Posts posted by 1114rk
-
-
i'm trying to centre the AutoFitArea object to stage that would update on Event.RESIZE but for some reason it goes off centre on resizing the window...
essentially like the LiquidStage functionality, although maybe that's why there is the LiquidStage because "it doesn't work straight out of box" ???
the code I'm using is as follows (with all the declarations and imports...)
autoFitArea.attach(attachedImage, ScaleMode.PROPORTIONAL_INSIDE, AlignMode.CENTER, AlignMode.CENTER); stage.addEventListener(Event.RESIZE, onStageResize); function onStageResize(e:Event):void { autoFitArea.width = stage.stageWidth; autoFitArea.height = stage.stageHeight; autoFitArea.x = stage.stageWidth/2 - autoFitArea.width/2; autoFitArea.y = stage.stageHeight/2 - autoFitArea.height/2; }
any ideas are much appreciated
-
adding the content (images) to the stage I believe
centre AutoFitArea to stage?
in TransformManager (Flash)
Posted
thanks very much for your prompt reply.
actually with
it works as expected