[wp-trac] [WordPress Trac] #22785: Gallery placeholder buttons sometimes appear overlaid on the wrong editor
WordPress Trac
noreply at wordpress.org
Thu Dec 6 08:30:54 UTC 2012
#22785: Gallery placeholder buttons sometimes appear overlaid on the wrong editor
--------------------------+------------------------------
Reporter: helenyhou | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Media | Version: 3.4.2
Severity: normal | Resolution:
Keywords: |
--------------------------+------------------------------
Old description:
> If you have multiple visual editors on a screen, the edit/remove buttons
> that overlay on the gallery placeholder can appear in the right position,
> but in the wrong editor. To reproduce:
>
> * Enable a second editor. Code (`edit_form_after_editor` is new to 3.5):
> {{{
> add_action( 'edit_form_after_editor', 'hhs_edit_form_after_editor' );
> function hhs_edit_form_after_editor() {
> wp_editor( '', 'hhs_test_editor' );
> }
> }}}
> * Insert a gallery or two into one of the editors.
> * Click inside the editor without the galleries.
> * Single click a gallery placeholder in the other. Note that the buttons
> appear overlaid on the gallery-less editor.
>
> Double clicking a placeholder will bring the buttons to the right place.
> Clicking within the same editor instance keeps the buttons in the right
> place. It seems specific to clicking a placeholder in an editor that did
> not previously have focus, including on page load. On page load, clicking
> a placeholder in the first (top) editor seems to show the buttons in the
> lower editor, whereas clicking a placeholder in the lower editor works
> just fine.
>
> Reproduced in 3.4.2. Probably goes back farther.
New description:
If you have multiple visual editors on a screen, the edit/remove buttons
that overlay on the gallery placeholder can appear in the right position,
but in the wrong editor. If you click the edit button that appeared in the
wrong place, the new-to-3.5 media modal shows the image set for the
previously clicked placeholder. To reproduce:
* Enable a second editor. Code (`edit_form_after_editor` is new to 3.5):
{{{
add_action( 'edit_form_after_editor', 'hhs_edit_form_after_editor' );
function hhs_edit_form_after_editor() {
wp_editor( '', 'hhs_test_editor' );
}
}}}
* Insert a gallery or two into one of the editors.
* Click inside the editor without the galleries.
* Single click a gallery placeholder in the other. Note that the buttons
appear overlaid on the gallery-less editor.
Double clicking a placeholder will bring the buttons to the right place.
Clicking within the same editor instance keeps the buttons in the right
place. It seems specific to clicking a placeholder in an editor that did
not previously have focus, including on page load. On page load, clicking
a placeholder in the first (top) editor seems to show the buttons in the
lower editor, whereas clicking a placeholder in the lower editor works
just fine.
Reproduced in 3.4.2. Probably goes back farther. It probably wouldn't have
been noticed in 3.4.2 since the old modal wouldn't have displayed much of
anything differently.
--
Comment (by helenyhou):
Reported here, in the context of the button displaying stuff for the wrong
gallery: http://wordpress.org/support/topic/gallery-shortcode-problems-
with-multiple-tinymce-editors-in-35?replies=1
--
Ticket URL: <http://core.trac.wordpress.org/ticket/22785#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list