After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 747553 - Popovers inside local plugs don't get size_allocate() called
Popovers inside local plugs don't get size_allocate() called
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: Other
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2015-04-09 12:08 UTC by Carlos Garnacho
Modified: 2015-04-13 10:40 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
plug: Remove size_allocate handler (2.87 KB, patch)
2015-04-09 12:13 UTC, Carlos Garnacho
none Details | Review

Description Carlos Garnacho 2015-04-09 12:08:50 UTC
gtk_plug_size_allocate() does minimal handling of size allocation in the local case (when the plug is not a toplevel, but embedded in the widget hierarchy), this path does the bare minimal, but doesn't chain up. This results in popover_size_allocate() being never called for popovers contained inside such plugs.

Since windows can be intermediate containers, it looks to me like _gtk_window_set_allocation() will currently do roughly the same for GtkPlugs than that branch in gtk_plug_size_allocate, plus allocating popovers, so it does look to me like we can just stop overriding size_allocate at all.

This can be seen on testsocket, choosing either of the local options, the entries inside the plug will be unable to show any of the magnifier/handles/selection popovers.
Comment 1 Carlos Garnacho 2015-04-09 12:13:49 UTC
Created attachment 301202 [details] [review]
plug: Remove size_allocate handler

Since windows can be intermediate containers this is somewhat redundant,
plus gtk_window_size_allocate() will do additional things like allocating
the popovers, which was mistakenly skipped by local plugs not chaining up.
Comment 2 Carlos Garcia Campos 2015-04-10 11:56:50 UTC
I confirm this fixes the problems I was having with popovers in browser plugins with ephy.
Comment 3 Matthias Clasen 2015-04-10 13:55:54 UTC
needs cherry-picking to 3.16 and 3.14, I assume ?
Comment 4 Carlos Garcia Campos 2015-04-10 16:00:55 UTC
(In reply to Matthias Clasen from comment #3)
> needs cherry-picking to 3.16 and 3.14, I assume ?

Please :-)
Comment 5 Carlos Garnacho 2015-04-13 10:40:22 UTC
Attachment 301202 [details] pushed as fe7bc84 - plug: Remove size_allocate handler