From 47cfdb5cedd84ff8fb5351f2dd67f5a05d924eba Mon Sep 17 00:00:00 2001 From: Andrew Ozz Date: Fri, 9 Jan 2015 21:46:03 +0000 Subject: [PATCH] Media modal: do not attempt to focus the hidden file input field added by Plupload when tabbing. Props afercia, fixes #30392. git-svn-id: https://develop.svn.wordpress.org/trunk@31117 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/js/media-views.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/wp-includes/js/media-views.js b/src/wp-includes/js/media-views.js index 8b4dff41d3..416e62e1b1 100644 --- a/src/wp-includes/js/media-views.js +++ b/src/wp-includes/js/media-views.js @@ -3767,7 +3767,8 @@ return; } - tabbables = this.$( ':tabbable' ); + // Skip the file input added by Plupload. + tabbables = this.$( ':tabbable' ).not( '.moxie-shim input[type="file"]' ); // Keep tab focus within media modal while it's open if ( tabbables.last()[0] === event.target && ! event.shiftKey ) {