GNOME Bugzilla – Bug 786363
_NET_RESTACK_WINDOW call does nothing
Last modified: 2017-09-29 16:36:25 UTC
Created attachment 357715 [details] Test program While adapting MSEide+MSEgui https://sourceforge.net/projects/mseide-msegui/ to Gnome I found on OpenSUSE Leap 42.2 that _NET_RESTACK_WINDOW functionality seems not to be implemented. The Z-order of the windows does not change while running the attached program. See also http://bugzilla.suse.com/show_bug.cgi?id=1052058
Created attachment 357898 [details] [review] Implement _NET_RESTACK_WINDOW and sibling-relative stacking Based on metacity commit 0b5a50c8 Please review. The original metacity patch implemented a new function meta_window_stack_just_above(), but I think below / above placement can be handled with the existing meta_window_stack_just_below() In terms of adding a test in src/tests, options are - Adding the attached program - adding an old gtk2+ stacking test: https://svn.code.sf.net/p/view/code/trunk/wm-test-suite/ - I also see some stacking .metatest tests in src/tests/stacking, could these be changed to test __NET_RESTACK_WINDOW? Let me know which test addition is preferred.
Review of attachment 357898 [details] [review]: Thanks, the code looks fine. Can you re-submit with a commit message following the existing convention? just something like: x11/window: Implement _NET_RESTACK_WINDOW "sibling-relative stacking" sounds like this implements support XConfigureWindow's sibling argument which isn't the case
Does the white window change the Z-order between top and between the black windows with the test program? Because there is also https://bugzilla.gnome.org/show_bug.cgi?id=786365
Created attachment 357911 [details] [review] x11/window: Implement _NET_RESTACK_WINDOW Update of the patch. This does not implement XConfigureWindow (I think that is needed for https://bugzilla.gnome.org/show_bug.cgi?id=786365). I will also try to look at that.
Review of attachment 357911 [details] [review]: looks good
Created attachment 358589 [details] [review] x11/window: Respect XConfigureRequestEvent sibling This is for bgo#786365. I am posting here because it should be applied on top of the "x11/window: Implement _NET_RESTACK_WINDOW" patch (comment#5), as it uses a function defined in that patch (restack_window). Please review. I am not sure if patch of comment#5 has been queued for master. If not, and if this one looks good, I can also spin one final patch for both issues. Also, if you have suggestions for adding tests (See questions on comment#1) please let me know.
Created attachment 360616 [details] [review] x11/window: Implement _NET_RESTACK_WINDOW and XConfigureRequestEvent sibling Updated patch with fix for the second testcase, which posted in bug#786365. Both testcases should work now. The new function for meta_window_stack_just_above() from original metacity commit was needed after all. Otherwise (with old patch), we always lower windowA to its lower sibling windowB position, even if the original request was to raise windowB to its higher sibling windowA position. This patch covers both this bug and bug#786365. Posted to both bugs for completion. Please review.
*** This bug has been marked as a duplicate of bug 786365 ***
Attachment 360616 [details] pushed as e3d5983 - x11/window: Implement _NET_RESTACK_WINDOW and XConfigureRequestEvent sibling