User Agent: Mozilla/5.0 (X11; Linux i686; rv:42.0) Gecko/20100101 Firefox/42.0 Build ID: 20151029151421 Steps to reproduce: Attempt to set focus on an iframe via its focus() method from within an event listener (here, keydown). Test case here: http://jsfiddle.net/120ys896/1/ Actual results: Pressing "1", which calls focus() from within the event handler, fails to focus on the iframe. Pressing "2", which uses a setTimeout hack, succeeds in changing focus. Expected results: Both "1" and "2" should move focus from the body to the iframe.
Created attachment 8690496 [details] test case, URL changed to https://example.com/ The attachment version of the test case isn't working because the iframe at http://example.com/ won't load from https://bug1226835.bmoattachments.org/, and apparently the bug doesn't happen if the iframe doesn't load. I've changed the URL to https://example.com/.
You need to log in before you can comment on or make changes to this bug.