I'd like to create a window which is not allowed to move. Is this possible?
0
votes
4 Answers
1
votes
You just create a NativeWindow with it's systemChrome property set to NativeWindowSystemChrome.NONE. That way there is no possibility to move the window by native methods (dragging the title bar, etc.).
0
votes
0
votes
0
votes
Alternatively, if you want to still have the system Chrome and everything, you can listen for the NativeWindowBoundsEvent that you don't want (NativeWindowBoundsEvent.MOVE, RESIZE, etc) and make a listening function like this...
private function onWindowBoundsChange(evt:NativeWindowBoundsEvent):void {
evt.preventDefault();
}
That way, you could turn it on or off whenever you want.