diff --git a/wp-includes/class-wp-editor.php b/wp-includes/class-wp-editor.php index 3fd51c2313..e36b3fe583 100644 --- a/wp-includes/class-wp-editor.php +++ b/wp-includes/class-wp-editor.php @@ -317,6 +317,7 @@ final class _WP_Editors { 'paste_remove_spans' => true, 'paste_strip_class_attributes' => 'all', 'paste_text_use_dialog' => true, + 'webkit_fake_resize' => false, 'spellchecker_rpc_url' => self::$baseurl . '/plugins/spellchecker/rpc.php', 'extended_valid_elements' => 'article[*],aside[*],audio[*],canvas[*],command[*],datalist[*],details[*],embed[*],figcaption[*],figure[*],footer[*],header[*],hgroup[*],keygen[*],mark[*],meter[*],nav[*],output[*],progress[*],section[*],source[*],summary,time[*],video[*],wbr', 'wpeditimage_disable_captions' => $no_captions, diff --git a/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin_src.js b/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin_src.js index 71819e25ec..c02a2ec0f0 100644 --- a/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin_src.js +++ b/wp-includes/js/tinymce/plugins/wpeditimage/editor_plugin_src.js @@ -14,11 +14,14 @@ ed.addCommand('WP_EditImage', t._editImage); ed.onInit.add(function(ed) { - ed.dom.events.add(ed.getBody(), 'dragstart', function(e) { + ed.dom.events.add(ed.getBody(), 'mousedown', function(e) { var parent; if ( e.target.nodeName == 'IMG' && ( parent = ed.dom.getParent(e.target, 'div.mceTemp') ) ) { - ed.selection.select(parent); + if ( tinymce.isGecko ) + ed.selection.select(parent); + else if ( tinymce.isWebKit ) + ed.dom.events.cancel(e); } }); @@ -44,7 +47,7 @@ }); }); - // resize the caption
when the image is soft-resized by the user (only possible in Firefox and IE) + // resize the caption
when the image is soft-resized by the user ed.onMouseUp.add(function(ed, e) { if ( tinymce.isWebKit || tinymce.isOpera ) return;