Hi mates,
I have following issue: System.capabilities.screenResolutionX and System.capabilities.screenResolutionY doesnt seem to refresh realtime while the movie is playing and user changes the resolution of the desktop… Although this is somehow unprobable - that user will change resolution of the desktop while viewing websites - i would like to detect this user’s action and resize the website content accordingly.
Here is the code i use to check the change in desktop resolution:
var nScrResY:Number = System.capabilities.screenResolutionY;
// onChangeDesktopResolution can be an onEnterFrame function.. (comparing actual res. with initial res.)
var nIntResChange:Number = setInterval(scrResChange, 500);
function scrResChange():Void {
[COLOR=Red]**trace(**[/COLOR]System.capabilities.screenResolutionY[COLOR=Red]**)**;[/COLOR] // traces SAME number even if i change desktop resolution
if(nScrResY != System.capabilities.screenResolutionY) {
nScrResY = System.capabilities.screenResolutionY;
// refresh other objects which depend on nScrResY
holder.slider.refreshSlider();
}
};
so as shown above, the trace statement outputs all the time the same resolution, no matter if the resolution of the desktop changes during the movie playback… Any ideas how i can detect change in desktop resolution realtime [not just when the movie starts]?
And if there are, they are apprecciated