PDA

View Full Version : Detecting Escape



silcreval
6 Jun 2010, 8:03 AM
I'd like to use the escape key in an app based in an Ext.Window - but even though I capture the key_down
event and call e.PreventDefault(), escape seems to get passed up and often results in the Ext.Window
closing. This seems to be the case in Firefox and Chrome. Havent checked the other browsers.

Any idea how I can stop this?

6 Jun 2010, 11:43 AM
events start from the top down (capture) to the originating (focused) node then back up the dom hierarchy (bubble). Try e.stopEvent();

silcreval
6 Jun 2010, 12:06 PM
Perfect - thanks for that!