Bug 87989
Summary: | New windows stealing focus | ||
---|---|---|---|
Product: | [Retired] Red Hat Linux | Reporter: | David Balažic <david.balazic> |
Component: | metacity | Assignee: | Havoc Pennington <hp> |
Status: | CLOSED UPSTREAM | QA Contact: | |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 9 | CC: | mitr, wtanaka |
Target Milestone: | --- | Keywords: | MoveUpstream, Triaged |
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2003-06-09 14:26:19 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
David Balažic
2003-04-04 13:15:14 UTC
This is especially bad in the following situation: 0) run some IM program like gaim 1) start typing password into terminal window 2) someone writes you a message. their window steals the focus 3) you finish typing your password in the chat window and send it to them. There's a reasonably general solution here using startup notification; it's only going to work with GTK/Qt apps that use the new startup notification stuff though. This should fix Mozilla. For GAIM though, GAIM should be fixed, it's about that simple. kwin has some work in this area, see http://webcvs.kde.org/cgi-bin/cvsweb.cgi/kdebase/kwin/workspace.cpp?rev=1.398.2.59&content-type=text/x-cvsweb-markup&only_with_tag=kwin_iii Search for "Prevention of focus stealing" Yes, KWin work is the startup notification based stuff I'm talking about. I thought the simple solution is "the window manager should not change focus, unless the user requests it" 95% of the time if someone chooses a menu item or button that opens a new window, they intend to immediately use said window. So the default should be to focus the window - the user has requested to use that window. Which is why Windows, Mac Classic, Mac OS X, etc. all have this default. For menus, yes, that is normal, but if a pre-existing window suddenly decides to jump in my face, that is different. It should not steal focus. The difference in this two cases is obvious and should not be hard to implement either. Same thing for newly created windows. They should appear in the background, or wait until the user "approves" their apperance or whatever. Just don't let them steal the focus. The WM can keep existing windows from raising themselves, but that breaks a lot of apps that have legitimate reasons to do that. Not all windows in X are what you think of as windows - tooltips, popup menus, etc. are also windows. Metacity originally did not allow apps to raise windows and it broke various apps. You just need to file bugs against those apps that do things wrongly, because to allow the legitimate uses the WM must allow the illegitimate ones also. New windows are just what I'm talking about with the 95%. People should not have to explicitly focus new windows, because they almost always want them focused. So the computer should just do that. For the cases where you opened the window but aren't planning to use it, it's simple enough to move the focus back. Anyway, duplicate of http://bugzilla.gnome.org/show_bug.cgi?id=82921 |