<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[19180] trunk/wp-includes/js/tinymce: Fix js error on mousedown in the editor, props joehoyle, fixes #19165</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg > ul, #logmsg > ol { margin-left: 0; margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://core.trac.wordpress.org/changeset/19180">19180</a></dd>
<dt>Author</dt> <dd>azaozz</dd>
<dt>Date</dt> <dd>2011-11-05 19:49:42 +0000 (Sat, 05 Nov 2011)</dd>
</dl>

<h3>Log Message</h3>
<pre>Fix js error on mousedown in the editor, props joehoyle, fixes <a href="http://core.trac.wordpress.org/ticket/19165">#19165</a></pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkwpincludesjstinymcepluginswpeditimageeditor_plugindevjs">trunk/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin.dev.js</a></li>
<li><a href="#trunkwpincludesjstinymcepluginswpeditimageeditor_pluginjs">trunk/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin.js</a></li>
<li><a href="#trunkwpincludesjstinymcewptinymcejsgz">trunk/wp-includes/js/tinymce/wp-tinymce.js.gz</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkwpincludesjstinymcepluginswpeditimageeditor_plugindevjs"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin.dev.js (19179 => 19180)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin.dev.js        2011-11-05 18:35:49 UTC (rev 19179)
+++ trunk/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin.dev.js        2011-11-05 19:49:42 UTC (rev 19180)
</span><span class="lines">@@ -78,7 +78,7 @@
</span><span class="cx">                         // show editimage buttons
</span><span class="cx">                         ed.onMouseDown.add(function(ed, e) {
</span><span class="cx"> 
</span><del>-                                if ( e.target &amp;&amp; (e.target.nodeName == 'IMG' || e.target.firstChild.nodeName == 'IMG') ) {
</del><ins>+                                if ( e.target &amp;&amp; ( e.target.nodeName == 'IMG' || (e.target.firstChild &amp;&amp; e.target.firstChild.nodeName == 'IMG') ) ) {
</ins><span class="cx">                                         mouse = {
</span><span class="cx">                                                 x: e.clientX,
</span><span class="cx">                                                 y: e.clientY,
</span></span></pre></div>
<a id="trunkwpincludesjstinymcepluginswpeditimageeditor_pluginjs"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin.js (19179 => 19180)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin.js        2011-11-05 18:35:49 UTC (rev 19179)
+++ trunk/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin.js        2011-11-05 19:49:42 UTC (rev 19180)
</span><span class="lines">@@ -1 +1 @@
</span><del>-(function(){tinymce.create(&quot;tinymce.plugins.wpEditImage&quot;,{init:function(a,c){var d=this,b={};d.url=c;d._createButtons();a.addCommand(&quot;WP_EditImage&quot;,function(){var i=a.selection.getNode(),g=tinymce.DOM.getViewPort(),h=g.h,e=(720&lt;g.w)?720:g.w,f=a.dom.getAttrib(i,&quot;class&quot;);if(f.indexOf(&quot;mceItem&quot;)!=-1||f.indexOf(&quot;wpGallery&quot;)!=-1||i.nodeName!=&quot;IMG&quot;){return}tb_show(&quot;&quot;,c+&quot;/editimage.html?ver=321&amp;TB_iframe=true&quot;);tinymce.DOM.setStyles(&quot;TB_window&quot;,{width:(e-50)+&quot;px&quot;,height:(h-45)+&quot;px&quot;,&quot;margin-left&quot;:&quot;-&quot;+parseInt(((e-50)/2),10)+&quot;px&quot;});if(!tinymce.isIE6){tinymce.DOM.setStyles(&quot;TB_window&quot;,{top:&quot;20px&quot;,marginTop:&quot;0&quot;})}tinymce.DOM.setStyles(&quot;TB_iframeContent&quot;,{width:(e-50)+&quot;px&quot;,height:(h-75)+&quot;px&quot;});tinymce.DOM.setStyle([&quot;TB_overlay&quot;,&quot;TB_window&quot;,&quot;TB_loa
 d&quot;],&quot;z-index&quot;,&quot;999999&quot;)});a.onInit.add(function(e){tinymce.dom.Event.add(e.getBody(),&quot;dragstart&quot;,function(f){if(!tinymce.isGecko&amp;&amp;f.target.nodeName==&quot;IMG&quot;&amp;&amp;e.dom.getParent(f.target,&quot;dl.wp-caption&quot;)){return tinymce.dom.Event.cancel(f)}})});a.onMouseUp.add(function(f,g){if(tinymce.isWebKit||tinymce.isOpera){return}if(b.x&amp;&amp;(g.clientX!=b.x||g.clientY!=b.y)){var h=f.selection.getNode();if(&quot;IMG&quot;==h.nodeName){window.setTimeout(function(){var e,i;if(h.width!=b.img_w||h.height!=b.img_h){h.className=h.className.replace(/size-[^ &quot;']+/,&quot;&quot;)}if(f.dom.getParent(h,&quot;div.mceTemp&quot;)){e=f.dom.getParent(h,&quot;dl.wp-caption&quot;);if(e){i=f.dom.getAttrib(h,&quot;width&quot;)||h.width;i=parseInt(i,10);f.dom.setStyle(e,&quot;width&quot;,10+i);f.execCommand(&quot;mceRepaint&quot;)}}},100)}}b={}});a.onMouseDown.add(function(f,g){if(g.target&amp;&amp;(g.target.nodeName==&quot;IMG&quot;||g
 .target.firstChild.nodeName==&quot;IMG&quot;)){b={x:g.clientX,y:g.clientY,img_w:g.target.clientWidth,img_h:g.target.clientHeight};if(f.dom.getAttrib(g.target,&quot;class&quot;).indexOf(&quot;mceItem&quot;)==-1){f.plugins.wordpress._showButtons(g.target,&quot;wp_editbtns&quot;)}}});a.onKeyPress.add(function(f,j){var k,g,i,h;if(j.keyCode==13){k=f.selection.getNode();g=f.dom.getParent(k,&quot;dl.wp-caption&quot;);i=f.dom.getParent(g,&quot;div.mceTemp&quot;);if(g&amp;&amp;i){h=f.dom.create(&quot;p&quot;,{},&quot;&amp;nbsp;&quot;);f.dom.insertAfter(h,i);if(h.firstChild){f.selection.select(h.firstChild)}else{f.selection.select(h)}tinymce.dom.Event.cancel(j);return false}}});a.onBeforeSetContent.add(function(e,f){f.content=d._do_shcode(f.content)});a.onPostProcess.add(function(e,f){if(f.get){f.content=d._get_shcode(f.content)}})},_do_shcode:function(a){return a.replace(/(?:&lt;p&gt;)?\[(?:wp_)?caption([^\]]+)\]([\s\S]+?)\[\/(?:wp_)?caption\](?:&lt;\/p&gt;)?[\s\u00a0]*/g,function(g,
 d,k){var j,f,e,h,i;d=d.replace(/\\'|\\&amp;#39;|\\&amp;#039;/g,&quot;&amp;#39;&quot;).replace(/\\&quot;|\\&amp;quot;/g,&quot;&amp;quot;&quot;);k=k.replace(/\\&amp;#39;|\\&amp;#039;/g,&quot;&amp;#39;&quot;).replace(/\\&amp;quot;/g,&quot;&amp;quot;&quot;);j=d.match(/id=['&quot;]([^'&quot;]+)/i);f=d.match(/align=['&quot;]([^'&quot;]+)/i);e=d.match(/width=['&quot;]([0-9]+)/);h=d.match(/caption=['&quot;]([^'&quot;]+)/i);j=(j&amp;&amp;j[1])?j[1]:&quot;&quot;;f=(f&amp;&amp;f[1])?f[1]:&quot;alignnone&quot;;e=(e&amp;&amp;e[1])?e[1]:&quot;&quot;;h=(h&amp;&amp;h[1])?h[1]:&quot;&quot;;if(!e||!h){return k}i=(f==&quot;aligncenter&quot;)?&quot;mceTemp mceIEcenter&quot;:&quot;mceTemp&quot;;return'&lt;div class=&quot;'+i+'&quot; draggable&gt;&lt;dl id=&quot;'+j+'&quot; class=&quot;wp-caption '+f+'&quot; style=&quot;width: '+(10+parseInt(e))+'px&quot;&gt;&lt;dt class=&quot;wp-caption-dt&quot;&gt;'+k+'&lt;/dt&gt;&lt;dd class=&quot;wp-caption-dd&quot;&gt;'+h+&quot;&lt;/dd&gt;&lt;/dl&gt;&lt;/div
 &gt;&quot;})},_get_shcode:function(a){return a.replace(/&lt;div class=&quot;mceTemp[^&quot;]*&quot;&gt;\s*&lt;dl([^&gt;]+)&gt;\s*&lt;dt[^&gt;]+&gt;([\s\S]+?)&lt;\/dt&gt;\s*&lt;dd[^&gt;]+&gt;(.+?)&lt;\/dd&gt;\s*&lt;\/dl&gt;\s*&lt;\/div&gt;\s*/gi,function(g,d,j,h){var i,f,e;i=d.match(/id=['&quot;]([^'&quot;]+)/i);f=d.match(/class=['&quot;]([^'&quot;]+)/i);e=j.match(/width=['&quot;]([0-9]+)/);i=(i&amp;&amp;i[1])?i[1]:&quot;&quot;;f=(f&amp;&amp;f[1])?f[1]:&quot;alignnone&quot;;e=(e&amp;&amp;e[1])?e[1]:&quot;&quot;;if(!e||!h){return j}f=f.match(/align[^ '&quot;]+/)||&quot;alignnone&quot;;h=h.replace(/&lt;\S[^&lt;&gt;]*&gt;/gi,&quot;&quot;).replace(/'/g,&quot;&amp;#39;&quot;).replace(/&quot;/g,&quot;&amp;quot;&quot;);return'[caption id=&quot;'+i+'&quot; align=&quot;'+f+'&quot; width=&quot;'+e+'&quot; caption=&quot;'+h+'&quot;]'+j+&quot;[/caption]&quot;})},_createButtons:function(){var b=this,a=tinyMCE.activeEditor,d=tinymce.DOM,e,c;d.remove(&quot;wp_editbtns&quot;);d.add(document.
 body,&quot;div&quot;,{id:&quot;wp_editbtns&quot;,style:&quot;display:none;&quot;});e=d.add(&quot;wp_editbtns&quot;,&quot;img&quot;,{src:b.url+&quot;/img/image.png&quot;,id:&quot;wp_editimgbtn&quot;,width:&quot;24&quot;,height:&quot;24&quot;,title:a.getLang(&quot;wpeditimage.edit_img&quot;)});tinymce.dom.Event.add(e,&quot;mousedown&quot;,function(g){var f=tinyMCE.activeEditor;f.windowManager.bookmark=f.selection.getBookmark(&quot;simple&quot;);f.execCommand(&quot;WP_EditImage&quot;)});c=d.add(&quot;wp_editbtns&quot;,&quot;img&quot;,{src:b.url+&quot;/img/delete.png&quot;,id:&quot;wp_delimgbtn&quot;,width:&quot;24&quot;,height:&quot;24&quot;,title:a.getLang(&quot;wpeditimage.del_img&quot;)});tinymce.dom.Event.add(c,&quot;mousedown&quot;,function(i){var f=tinyMCE.activeEditor,g=f.selection.getNode(),h;if(g.nodeName==&quot;IMG&quot;&amp;&amp;f.dom.getAttrib(g,&quot;class&quot;).indexOf(&quot;mceItem&quot;)==-1){if((h=f.dom.getParent(g,&quot;div&quot;))&amp;&amp;f.dom.hasClass(h,&
 quot;mceTemp&quot;)){f.dom.remove(h)}else{if((h=f.dom.getParent(g,&quot;A&quot;))&amp;&amp;h.childNodes.length==1){f.dom.remove(h)}else{f.dom.remove(g)}}f.execCommand(&quot;mceRepaint&quot;);return false}})},getInfo:function(){return{longname:&quot;Edit Image&quot;,author:&quot;WordPress&quot;,authorurl:&quot;http://wordpress.org&quot;,infourl:&quot;&quot;,version:&quot;1.0&quot;}}});tinymce.PluginManager.add(&quot;wpeditimage&quot;,tinymce.plugins.wpEditImage)})();
</del><span class="cx">\ No newline at end of file
</span><ins>+(function(){tinymce.create(&quot;tinymce.plugins.wpEditImage&quot;,{init:function(a,c){var d=this,b={};d.url=c;d._createButtons();a.addCommand(&quot;WP_EditImage&quot;,function(){var i=a.selection.getNode(),g=tinymce.DOM.getViewPort(),h=g.h,e=(720&lt;g.w)?720:g.w,f=a.dom.getAttrib(i,&quot;class&quot;);if(f.indexOf(&quot;mceItem&quot;)!=-1||f.indexOf(&quot;wpGallery&quot;)!=-1||i.nodeName!=&quot;IMG&quot;){return}tb_show(&quot;&quot;,c+&quot;/editimage.html?ver=321&amp;TB_iframe=true&quot;);tinymce.DOM.setStyles(&quot;TB_window&quot;,{width:(e-50)+&quot;px&quot;,height:(h-45)+&quot;px&quot;,&quot;margin-left&quot;:&quot;-&quot;+parseInt(((e-50)/2),10)+&quot;px&quot;});if(!tinymce.isIE6){tinymce.DOM.setStyles(&quot;TB_window&quot;,{top:&quot;20px&quot;,marginTop:&quot;0&quot;})}tinymce.DOM.setStyles(&quot;TB_iframeContent&quot;,{width:(e-50)+&quot;px&quot;,height:(h-75)+&quot;px&quot;});tinymce.DOM.setStyle([&quot;TB_overlay&quot;,&quot;TB_window&quot;,&quot;TB_loa
 d&quot;],&quot;z-index&quot;,&quot;999999&quot;)});a.onInit.add(function(e){tinymce.dom.Event.add(e.getBody(),&quot;dragstart&quot;,function(f){if(!tinymce.isGecko&amp;&amp;f.target.nodeName==&quot;IMG&quot;&amp;&amp;e.dom.getParent(f.target,&quot;dl.wp-caption&quot;)){return tinymce.dom.Event.cancel(f)}})});a.onMouseUp.add(function(f,g){if(tinymce.isWebKit||tinymce.isOpera){return}if(b.x&amp;&amp;(g.clientX!=b.x||g.clientY!=b.y)){var h=f.selection.getNode();if(&quot;IMG&quot;==h.nodeName){window.setTimeout(function(){var e,i;if(h.width!=b.img_w||h.height!=b.img_h){h.className=h.className.replace(/size-[^ &quot;']+/,&quot;&quot;)}if(f.dom.getParent(h,&quot;div.mceTemp&quot;)){e=f.dom.getParent(h,&quot;dl.wp-caption&quot;);if(e){i=f.dom.getAttrib(h,&quot;width&quot;)||h.width;i=parseInt(i,10);f.dom.setStyle(e,&quot;width&quot;,10+i);f.execCommand(&quot;mceRepaint&quot;)}}},100)}}b={}});a.onMouseDown.add(function(f,g){if(g.target&amp;&amp;(g.target.nodeName==&quot;IMG&quot;||(
 g.target.firstChild&amp;&amp;g.target.firstChild.nodeName==&quot;IMG&quot;))){b={x:g.clientX,y:g.clientY,img_w:g.target.clientWidth,img_h:g.target.clientHeight};if(f.dom.getAttrib(g.target,&quot;class&quot;).indexOf(&quot;mceItem&quot;)==-1){f.plugins.wordpress._showButtons(g.target,&quot;wp_editbtns&quot;)}}});a.onKeyPress.add(function(f,j){var k,g,i,h;if(j.keyCode==13){k=f.selection.getNode();g=f.dom.getParent(k,&quot;dl.wp-caption&quot;);i=f.dom.getParent(g,&quot;div.mceTemp&quot;);if(g&amp;&amp;i){h=f.dom.create(&quot;p&quot;,{},&quot;&amp;nbsp;&quot;);f.dom.insertAfter(h,i);if(h.firstChild){f.selection.select(h.firstChild)}else{f.selection.select(h)}tinymce.dom.Event.cancel(j);return false}}});a.onBeforeSetContent.add(function(e,f){f.content=d._do_shcode(f.content)});a.onPostProcess.add(function(e,f){if(f.get){f.content=d._get_shcode(f.content)}})},_do_shcode:function(a){return a.replace(/(?:&lt;p&gt;)?\[(?:wp_)?caption([^\]]+)\]([\s\S]+?)\[\/(?:wp_)?caption\](?:&lt;\/p
 &gt;)?[\s\u00a0]*/g,function(g,d,k){var j,f,e,h,i;d=d.replace(/\\'|\\&amp;#39;|\\&amp;#039;/g,&quot;&amp;#39;&quot;).replace(/\\&quot;|\\&amp;quot;/g,&quot;&amp;quot;&quot;);k=k.replace(/\\&amp;#39;|\\&amp;#039;/g,&quot;&amp;#39;&quot;).replace(/\\&amp;quot;/g,&quot;&amp;quot;&quot;);j=d.match(/id=['&quot;]([^'&quot;]+)/i);f=d.match(/align=['&quot;]([^'&quot;]+)/i);e=d.match(/width=['&quot;]([0-9]+)/);h=d.match(/caption=['&quot;]([^'&quot;]+)/i);j=(j&amp;&amp;j[1])?j[1]:&quot;&quot;;f=(f&amp;&amp;f[1])?f[1]:&quot;alignnone&quot;;e=(e&amp;&amp;e[1])?e[1]:&quot;&quot;;h=(h&amp;&amp;h[1])?h[1]:&quot;&quot;;if(!e||!h){return k}i=(f==&quot;aligncenter&quot;)?&quot;mceTemp mceIEcenter&quot;:&quot;mceTemp&quot;;return'&lt;div class=&quot;'+i+'&quot; draggable&gt;&lt;dl id=&quot;'+j+'&quot; class=&quot;wp-caption '+f+'&quot; style=&quot;width: '+(10+parseInt(e))+'px&quot;&gt;&lt;dt class=&quot;wp-caption-dt&quot;&gt;'+k+'&lt;/dt&gt;&lt;dd class=&quot;wp-caption-dd&quot;&gt;'+h+&quot
 ;&lt;/dd&gt;&lt;/dl&gt;&lt;/div&gt;&quot;})},_get_shcode:function(a){return a.replace(/&lt;div class=&quot;mceTemp[^&quot;]*&quot;&gt;\s*&lt;dl([^&gt;]+)&gt;\s*&lt;dt[^&gt;]+&gt;([\s\S]+?)&lt;\/dt&gt;\s*&lt;dd[^&gt;]+&gt;(.+?)&lt;\/dd&gt;\s*&lt;\/dl&gt;\s*&lt;\/div&gt;\s*/gi,function(g,d,j,h){var i,f,e;i=d.match(/id=['&quot;]([^'&quot;]+)/i);f=d.match(/class=['&quot;]([^'&quot;]+)/i);e=j.match(/width=['&quot;]([0-9]+)/);i=(i&amp;&amp;i[1])?i[1]:&quot;&quot;;f=(f&amp;&amp;f[1])?f[1]:&quot;alignnone&quot;;e=(e&amp;&amp;e[1])?e[1]:&quot;&quot;;if(!e||!h){return j}f=f.match(/align[^ '&quot;]+/)||&quot;alignnone&quot;;h=h.replace(/&lt;\S[^&lt;&gt;]*&gt;/gi,&quot;&quot;).replace(/'/g,&quot;&amp;#39;&quot;).replace(/&quot;/g,&quot;&amp;quot;&quot;);return'[caption id=&quot;'+i+'&quot; align=&quot;'+f+'&quot; width=&quot;'+e+'&quot; caption=&quot;'+h+'&quot;]'+j+&quot;[/caption]&quot;})},_createButtons:function(){var b=this,a=tinyMCE.activeEditor,d=tinymce.DOM,e,c;d.remove(&quot;wp_
 editbtns&quot;);d.add(document.body,&quot;div&quot;,{id:&quot;wp_editbtns&quot;,style:&quot;display:none;&quot;});e=d.add(&quot;wp_editbtns&quot;,&quot;img&quot;,{src:b.url+&quot;/img/image.png&quot;,id:&quot;wp_editimgbtn&quot;,width:&quot;24&quot;,height:&quot;24&quot;,title:a.getLang(&quot;wpeditimage.edit_img&quot;)});tinymce.dom.Event.add(e,&quot;mousedown&quot;,function(g){var f=tinyMCE.activeEditor;f.windowManager.bookmark=f.selection.getBookmark(&quot;simple&quot;);f.execCommand(&quot;WP_EditImage&quot;)});c=d.add(&quot;wp_editbtns&quot;,&quot;img&quot;,{src:b.url+&quot;/img/delete.png&quot;,id:&quot;wp_delimgbtn&quot;,width:&quot;24&quot;,height:&quot;24&quot;,title:a.getLang(&quot;wpeditimage.del_img&quot;)});tinymce.dom.Event.add(c,&quot;mousedown&quot;,function(i){var f=tinyMCE.activeEditor,g=f.selection.getNode(),h;if(g.nodeName==&quot;IMG&quot;&amp;&amp;f.dom.getAttrib(g,&quot;class&quot;).indexOf(&quot;mceItem&quot;)==-1){if((h=f.dom.getParent(g,&quot;div&quot
 ;))&amp;&amp;f.dom.hasClass(h,&quot;mceTemp&quot;)){f.dom.remove(h)}else{if((h=f.dom.getParent(g,&quot;A&quot;))&amp;&amp;h.childNodes.length==1){f.dom.remove(h)}else{f.dom.remove(g)}}f.execCommand(&quot;mceRepaint&quot;);return false}})},getInfo:function(){return{longname:&quot;Edit Image&quot;,author:&quot;WordPress&quot;,authorurl:&quot;http://wordpress.org&quot;,infourl:&quot;&quot;,version:&quot;1.0&quot;}}});tinymce.PluginManager.add(&quot;wpeditimage&quot;,tinymce.plugins.wpEditImage)})();
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkwpincludesjstinymcewptinymcejsgz"></a>
<div class="binary"><h4>Modified: trunk/wp-includes/js/tinymce/wp-tinymce.js.gz</h4>
<pre class="diff"><span>
<span class="cx">(Binary files differ)
</span></span></pre></div>
</div>

</body>
</html>