From a1513dd6830b1004b8e949a0fd70a16f69371a6a Mon Sep 17 00:00:00 2001 From: Daryl Koopersmith Date: Wed, 1 Aug 2012 02:27:18 +0000 Subject: [PATCH] When the browser property is not provided to wp.Uploader, hide Plupload's auto-created file input and call Plupload's disableBrowse. see #21437, [21379]. git-svn-id: https://develop.svn.wordpress.org/trunk@21380 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/js/plupload/wp-plupload.dev.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/wp-includes/js/plupload/wp-plupload.dev.js b/wp-includes/js/plupload/wp-plupload.dev.js index d2f6a07df8..d9cd829ffa 100644 --- a/wp-includes/js/plupload/wp-plupload.dev.js +++ b/wp-includes/js/plupload/wp-plupload.dev.js @@ -113,8 +113,13 @@ if ( typeof wp === 'undefined' ) }); }( this.dropzone, this.supports.dragdrop )); - if ( this.browser ) + if ( this.browser ) { this.browser.on( 'mouseenter', this.refresh ); + } else { + this.uploader.disableBrowse( true ); + // If HTML5 mode, hide the auto-created file container. + $('#' + this.uploader.id + '_html5_container').hide(); + } this.uploader.bind( 'UploadProgress', this.progress );