Skip to content

Commit

Permalink
3.7 regression: Fix the width of captioned images inserted into the v…
Browse files Browse the repository at this point in the history
…isual editor.

Pulls some arithmetic outside of some string concatenation to avoid a nasty uglify.js regression: mishoo/UglifyJS#330.

props LucP.
fixes #25700 for trunk.


git-svn-id: https://develop.svn.wordpress.org/trunk@25921 602fd350-edb4-49c9-b593-d223f7449a82
  • Loading branch information
nacin committed Oct 26, 2013
1 parent f764c6d commit e6f0f55
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,8 @@
if ( cls == 'aligncenter' )
div_cls += ' mceIEcenter';

return '<div class="'+div_cls+'"><dl id="'+id+'" class="wp-caption '+cls+'" style="width: '+( 10 + parseInt(w) )+
w = parseInt( w, 10 ) + 10;
return '<div class="'+div_cls+'"><dl id="'+id+'" class="wp-caption '+cls+'" style="width: '+w+
'px"><dt class="wp-caption-dt">'+img+'</dt><dd class="wp-caption-dd">'+cap+'</dd></dl></div>';
});
},
Expand Down

0 comments on commit e6f0f55

Please sign in to comment.