Flex -> app.swf -> [movieclip].getObjectsUnderPoint: returns fail things
Solution is to always call getObjectsUnderPoint on the stage instance!
Flex -> app.swf -> [stage].getObjectsUnderPoint: returns good things
But watch out to stage instance, because when swf is loaded and the creator of the main class is called, there is no stage property set!
Implement an init() method that is about to call from flex on the SWFLoader.complete event.
// flex:
private function swfLoaderComplete(event:Event):void
{
contentLoader.content["init"].apply();
}
// SWF main class:
public function init():void
{
stage.addEventListener(MouseEvent.MOUSE_MOVE, stageMouseMove);
}
Nincsenek megjegyzések:
Megjegyzés küldése