mirror of
https://github.com/moodle/moodle.git
synced 2025-03-14 20:50:21 +01:00
In certain modal dialogues, we listen on the Escape key to close a dialogue. However, this is still passed to the browser. As a result, if the browser is in full screen mode and that browser respects the escape key as a means to exit full screen. As a result, we need to ensure that we listen for the escape key at keydown rather than keyup, and additionally prevent the default browser behaviour. This is a workaround to http://yuilibrary.com/projects/yui3/ticket/2532616 and, should that issue be fixed, it should be removed.