aboutsummaryrefslogtreecommitdiffstats
path: root/ui/core.js
diff options
context:
space:
mode:
Diffstat (limited to 'ui/core.js')
-rw-r--r--ui/core.js30
1 files changed, 1 insertions, 29 deletions
diff --git a/ui/core.js b/ui/core.js
index beb3fcbcb..f0eef1328 100644
--- a/ui/core.js
+++ b/ui/core.js
@@ -29,6 +29,7 @@
"./labels",
"./jquery-1-7",
"./plugin",
+ "./safe-active-element",
"./version"
], factory );
} else {
@@ -41,35 +42,6 @@
$.extend( $.ui, {
// Internal use only
- safeActiveElement: function( document ) {
- var activeElement;
-
- // Support: IE 9 only
- // IE9 throws an "Unspecified error" accessing document.activeElement from an <iframe>
- try {
- activeElement = document.activeElement;
- } catch ( error ) {
- activeElement = document.body;
- }
-
- // Support: IE 9 - 11 only
- // IE may return null instead of an element
- // Interestingly, this only seems to occur when NOT in an iframe
- if ( !activeElement ) {
- 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;
- },
-
- // Internal use only
safeBlur: function( element ) {
// Support: IE9 - 10 only