From fc22367830f2988d76978a91506b3a71c97bdcfa Mon Sep 17 00:00:00 2001 From: koopersmith Date: Wed, 28 Mar 2012 09:33:32 +0000 Subject: [PATCH] Theme Customizer: Properly bind the 'upload new' and 'remove image' actions in the image picker. see #19910. This occurred because we weren't calling UploadControl.ready (where the actions are declared and the uploader is initialized) in ImageControl.ready. git-svn-id: http://svn.automattic.com/wordpress/trunk@20301 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/js/customize-controls.dev.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/wp-includes/js/customize-controls.dev.js b/wp-includes/js/customize-controls.dev.js index d16b91514..359bf35d9 100644 --- a/wp-includes/js/customize-controls.dev.js +++ b/wp-includes/js/customize-controls.dev.js @@ -160,9 +160,11 @@ }); api.ImageControl = api.UploadControl.extend({ - ready: function( id, value, options ) { + ready: function() { var control = this; + api.UploadControl.prototype.ready.call( this ); + this.thumbnail = this.container.find('.thumbnail img'); this.thumbnailSrc = $.proxy( this.thumbnailSrc, this ); this.setting.bind( this.thumbnailSrc );