diff --git a/src/wp-includes/js/wpdialog.js b/src/wp-includes/js/wpdialog.js index 9f5c19bae4..baf1f2f01a 100644 --- a/src/wp-includes/js/wpdialog.js +++ b/src/wp-includes/js/wpdialog.js @@ -1,3 +1,6 @@ +/* + * Wrap the jQuery UI Dialog open function remove focus from tinyMCE. + */ ( function($) { $.widget('wp.wpdialog', $.ui.dialog, { open: function() { @@ -8,6 +11,7 @@ // Open the dialog. this._super(); + // WebKit leaves focus in the TinyMCE editor unless we shift focus. this.element.focus(); this._trigger('refresh');