X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/9e77185fafaf4e60e2b73821e0e4b9b1a11fb85f..e0feb3b2e5b436a06bbb04fbc838d1cd6ec95399:/wp-includes/js/tinymce/plugins/tabfocus/plugin.js diff --git a/wp-includes/js/tinymce/plugins/tabfocus/plugin.js b/wp-includes/js/tinymce/plugins/tabfocus/plugin.js index 47ddfdee..7a9b5c8a 100644 --- a/wp-includes/js/tinymce/plugins/tabfocus/plugin.js +++ b/wp-includes/js/tinymce/plugins/tabfocus/plugin.js @@ -1,8 +1,8 @@ /** * plugin.js * - * Copyright, Moxiecode Systems AB * Released under LGPL License. + * Copyright (c) 1999-2015 Ephox Corp. All rights reserved * * License: http://www.tinymce.com/license * Contributing: http://www.tinymce.com/contributing @@ -35,12 +35,8 @@ tinymce.PluginManager.add('tabfocus', function(editor) { e.style.visibility != "hidden" && canSelectRecursive(e.parentNode)); } - function canSelectInOldIe(el) { - return el.tabIndex || el.nodeName == "INPUT" || el.nodeName == "TEXTAREA"; - } - function canSelect(el) { - return ((!canSelectInOldIe(el))) && el.getAttribute("tabindex") != '-1' && canSelectRecursive(el); + return /INPUT|TEXTAREA|BUTTON/.test(el.tagName) && tinymce.get(e.id) && el.tabIndex != -1 && canSelectRecursive(el); } each(el, function(e, i) { @@ -115,7 +111,6 @@ tinymce.PluginManager.add('tabfocus', function(editor) { editor.on('keyup', tabCancel); - // Add later so other plugins can preventDefault() if (tinymce.Env.gecko) { editor.on('keypress keydown', tabHandler); } else {