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 766643 - Frozen windows when unmapped with pending configure event
Frozen windows when unmapped with pending configure event
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: Other
3.18.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks: 426246
 
 
Reported: 2016-05-19 06:35 UTC by Karl Tomlinson
Modified: 2016-05-25 00:51 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Karl Tomlinson 2016-05-19 06:35:15 UTC
When GtkWindows are resized, gtk_window_move_resize() will call
gdk_window_freeze_toplevel_updates() [1].  The intention is that
gdk_window_thaw_toplevel_updates() will be called when the associated
(or another) configure event is received [2].

However, when gtk_window_unmap() is called before the configure event is
received, it resets configure_request_count to zero [3], and so
gtk_window_configure_event() will not call gdk_window_thaw_toplevel_updates().

Remapping the window just provides a frozen window.

Discovered by Andrew Comminos [4].

Looks like this goes back to [5].

[1] https://git.gnome.org/browse/gtk+/tree/gtk/gtkwindow.c?h=3.18.9#n9484
[2] https://git.gnome.org/browse/gtk+/tree/gtk/gtkwindow.c?h=3.18.9#n7544
[3] https://git.gnome.org/browse/gtk+/tree/gtk/gtkwindow.c?h=3.18.9#n6198
[4] https://bugzilla.mozilla.org/show_bug.cgi?id=1225044#c16
[5] https://git.gnome.org/browse/gtk+/commit/?id=eab3ef31455b8ce2c410d2c45240a77bdd9f5bd2
Comment 1 Benjamin Otte (Company) 2016-05-24 23:20:46 UTC
Pushed this fix in the hope that it solves things. Please test and reopen if not.

commit b9f55dfd634808ddec5b1a82769890e217b8eb46
Author: Benjamin Otte <otte@redhat.com>
Date:   Wed May 25 01:16:52 2016 +0200

    window: Unfreeze window on unmap
    
    Make sure to keep parity with the number of times we froze the window
    when we unmap it.
    Otherwise it will permanently stay frozen after being remapped.
Comment 2 Karl Tomlinson 2016-05-25 00:51:26 UTC
Works perfectly, thanks Benjamin!