mirror of
https://github.com/moodle/moodle.git
synced 2025-01-31 04:33:13 +01:00
04e67878f9
YUI Dialogues were using an older method for locking focus to modals, but this way conflicts with the way in which we lock focus for AMD modules. As a result, when an AMD dialogue launches a YUI dialogue the focus is not correctly locked and it is not possible to focus on anything in the YUI dialogue. This includes a minor changes to the focuslock AMD module to ensure that it is possible to loop the focus in both directions. Many of our older YUI dialogues are themselves focusable. As a result we need to include the lock region in the calculation when calculating the possible descendants. If we do not do so then the reverse looping does not work.