Bug 503522 - metacity prevents applications from changing stacking order for wins of different groups
metacity prevents applications from changing stacking order for wins of diffe...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: metacity (Show other bugs)
5.3
All Linux
urgent Severity urgent
: rc
: ---
Assigned To: Owen Taylor
desktop-bugs@redhat.com
: Patch, ZStream
Depends On:
Blocks: 499522 537023
  Show dependency treegraph
 
Reported: 2009-06-01 10:55 EDT by Olivier Fourdan
Modified: 2013-03-03 21:48 EST (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 658494 (view as bug list)
Environment:
Last Closed: 2010-03-30 04:25:21 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Proposed patch (allows windows sharing the same client leader to change stacking) (813 bytes, patch)
2009-06-01 10:55 EDT, Olivier Fourdan
no flags Details | Diff
Patch proposed by our customer (8.12 KB, patch)
2009-06-01 11:00 EDT, Olivier Fourdan
no flags Details | Diff


External Trackers
Tracker ID Priority Status Summary Last Updated
GNOME Desktop 567528 None None None Never

  None (edit)
Description Olivier Fourdan 2009-06-01 10:55:14 EDT
Created attachment 346086 [details]
Proposed patch (allows windows sharing the same client leader to change stacking)

Description of problem:

Metacity focus stealing prevention mechanism does not allow applications to manipulate the Z-order between windows that are not from the same group.

This is a problem for modular applications that may use windows from different groups. In the case of our customer, this prevents modular tools built for Maya from manipulating the stacking which causes a lot of manual interactions with the windows, and it it severely hampers the work flow for our customer.

Version-Release number of selected component (if applicable):

metacity-2.16

How reproducible:

100% reproducible for the customer

Steps to Reproduce:
1. Install Maya
2. Install RealFlow (http://www.realflow.com/), qualoth (http://qualoth.com/), or syflex (http://www.syflex.biz/) plug-ins
  
Actual results:

Plugins that are launched from the "Shelf" (or from a menu) are not getting raised when their icon is clicked.

Expected results:

Plugins' windows appear on top of the stack

Additional info:

I think this related to the following upstream bug #567528:

    http://bugzilla.gnome.org/show_bug.cgi?id=567528

The xprop showed that the windows would not belong to the same group but would share the same client leader:

One one window:
   WM_CLIENT_LEADER(WINDOW): window id # 0x340000c

And on the other:
   WM_CLIENT_LEADER(WINDOW): window id # 0x340000c

So I wrote a first patch to also use the client_leader field to determine if two different windows are related to the same application (that's metacity-2.16.0-client-leader-same-application.patch)

Unfortunately, that worked with some of the modules but not all according to our customer.

Our customer is proposing another patch instead, metacity-2.16.0-allow-nonmember-focus.patch, that adds a gconf option to allow stacking request for windows that are not from the same group.
Comment 1 Olivier Fourdan 2009-06-01 11:00:08 EDT
Created attachment 346087 [details]
Patch proposed by our customer

Allowing only windows form the same group or sharing the same client leader is not sufficient in all cases, as some Maya and its plugins' windows may not even share the same client leader ID.

Therefore our customer is proposing this patch which would add a GConf key to optionally disable the mechanism that prevents windows from any group to manipulate the stack.
Comment 11 Owen Taylor 2009-10-19 19:55:08 EDT
I've attached a patch upstream that I like a bit better; it has similar functionality, but it should be both safer (more restricted in the code paths it affects) and more general (works around some cases that the other patch doesn't)
Comment 26 Owen Taylor 2009-11-11 15:41:32 EST
built in dist-5E-qu-candidate as metacity-2.16.0-15.el5
Comment 31 errata-xmlrpc 2010-03-30 04:25:21 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2010-0245.html

Note You need to log in before you can comment on or make changes to this bug.