Adobe Air for IOS- issue in Orientaitation on ORIENTATION_CHANGING event
I'm working on Adobe Air for IOS version..
Problem is that I not getting correct value of orientation while detecting ORIENTATION_CHANGING event.But Getting correct value only after ORIENTATION_CHANGE event
Here is the code,
import flash.events. StageOrientationEvent
stage.addEventListener(StageOrientationEvent.ORIENTATION_CHANGING,onOrientationChanging);
stage.addEventListener(StageOrientationEvent.ORIENTATION_CHANGE,onOrientationChange);
function onOrientationChanging(e:StageOrientationEvent):void
{
trace(e.afterOrientation) /// not getting correct orientation value according to how we rotate device
}
function onOrientationChange(e:StageOrientationEvent):void
{
trace(e.afterOrientation) /// getting correct orientation value according to how we rotate device
}
How can I get correct value while changing device orientation?