Jump to content

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


  • Posts

  • Joined

  • Last visited

Everything posted by zrfting

  1. Hi I have a sprite in UIComponent. When the UIComponent 's Scale change. TransformManager 's handler changed also. How to keep handler not scale? public var manager:TransformManager = new TransformManager(); protected function initApp(event:FlexEvent):void { var sprite:Sprite = new Sprite(); sprite.graphics.beginFill(0xffdd00); sprite.graphics.drawRect(0,0,100,100); cont.addChild(sprite); var clipItem:TransformItem = manager.addItem(sprite); } protected function resizehandler(event:Event):void { cont.scaleX = nativeWindow.width/200; cont.scaleY = nativeWindow.height/200; } protected function cont_creationCompleteHandler(event:FlexEvent):void { nativeWindow.addEventListener(Event.RESIZE,resizehandler); } ]]> </fx:Script> <mx:UIComponent id="cont" width="200" height="200" creationComplete="cont_creationCompleteHandler(event)"/>