TinyMCE: use the actual image node when calculating the position of the toolbar. Fixes a bug in old IE. See #30147.

git-svn-id: https://develop.svn.wordpress.org/trunk@30558 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Ozz 2014-11-25 01:21:35 +00:00
parent 4537217cf1
commit c2c0eee75a

View File

@ -166,7 +166,7 @@ tinymce.PluginManager.add( 'wpeditimage', function( editor ) {
adminbar = tinymce.$( '#wpadminbar' )[0],
mceToolbar = tinymce.$( '.mce-tinymce .mce-toolbar-grp' )[0],
adminbarHeight = 0,
boundary = editor.selection.getRng().getBoundingClientRect(),
boundary = editor.selection.getNode().getBoundingClientRect(),
boundaryMiddle = ( boundary.left + boundary.right ) / 2,
boundaryVerticalMiddle = ( boundary.top + boundary.bottom ) / 2,
spaceTop = boundary.top,