Core: Handle IE11 bug with document.activeElement in iframes

Fixes #11539
Closes gh-1518
This commit is contained in:
Scott González 2015-03-24 14:10:37 -04:00
parent 1696405c09
commit 76c27556f4

View File

@ -63,6 +63,13 @@ $.extend( $.ui, {
activeElement = document.body;
}
// Support: IE 11 only
// IE11 returns a seemingly empty object in some cases when accessing
// document.activeElement from an <iframe>
if ( !activeElement.nodeName ) {
activeElement = document.body;
}
return activeElement;
},