TinyMCE: select the iframe element by id. Needed as some browser extensions insert extra elements in the page.

Props iseulde.
Merges [31180] to the 4.1 branch.
Fixes #30785.

Built from https://develop.svn.wordpress.org/branches/4.1@31436


git-svn-id: http://core.svn.wordpress.org/branches/4.1@31417 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Dion Hulse 2015-02-12 06:00:23 +00:00
parent 0c28c25442
commit 1c36669bce
3 changed files with 2 additions and 2 deletions

View File

@ -185,7 +185,7 @@ tinymce.PluginManager.add( 'wpeditimage', function( editor ) {
windowWidth = window.innerWidth;
toolbarWidth = toolbarNode.offsetWidth;
toolbarHalf = toolbarWidth / 2;
iframe = editor.getContentAreaContainer().firstChild;
iframe = document.getElementById( editor.id + '_ifr' );
iframePos = DOM.getPos( iframe );
iframeWidth = iframe.offsetWidth;
iframeHeigth = iframe.offsetHeight;

File diff suppressed because one or more lines are too long