In an application I am building I need to detect whether the (right) alt-key was pressed in combination with another (letter) and make sure that the control key isn't being pressed at the same time.
But it looks like the Keyboard events for both MOUSE_DOWN and MOUSE_UP always return true for ctrlKey (when it is not actual pressed!) while the Alt key is pressed. Simplified test code: import flash.events.KeyboardEvent; stage.addEventListener(KeyboardEvent.KEY_DOWN, onKeyDownHandler); stage.addEventListener(KeyboardEvent.KEY_UP, onKeyUpHandler); function onKeyDownHandler(e:KeyboardEvent):void { trace("onKeyDown: e.ctrlKey=" + e.ctrlKey + ", e.altKey=" + e.altKey); } function onKeyUpHandler(e:KeyboardEvent):void { trace("onKeyUp: e.ctrlKey=" + e.ctrlKey + ", e.altKey=" + e.altKey); } When I test the code (tested on 2 PC's with Flash 10 or 10.1 Debug player in Flash pro CS5 or via same version debug players in MSIE/FF browsers) and press only the right alt key or a key combi e.g. right-alt-5 the traces report always true for the ctrlKey, so even when it isn't pressed!? I checked the Adobe bug base, tried Google, but didn't find anything related so far. What am I missing? Thanks. - Benny _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders