Bug 359683 - Clients can change the VD (and activate) via _NET_ACTIVE_WINDOW messages
Summary: Clients can change the VD (and activate) via _NET_ACTIVE_WINDOW messages
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: core (show other bugs)
Version: git master
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Thomas Lübking
URL: https://git.reviewboard.kde.org/r/127...
Keywords:
Depends on:
Blocks:
 
Reported: 2016-02-22 21:57 UTC by Thomas Lübking
Modified: 2016-02-27 10:28 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 5.6
Sentry Crash Report:
thomas.luebking: ReviewRequest+


Attachments
proof of issue (572 bytes, text/plain)
2016-02-22 21:59 UTC, Thomas Lübking
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Lübking 2016-02-22 21:57:26 UTC
Cause is 

commit 60e904fb0447127a6bc0aa3309e2b98109110dec
Author: Luboš Luňák <l.lunak@kde.org>
Date:   Thu Nov 29 15:01:30 2007 +0000

    Don't refuse explicit window activation request just because the window
    is not on the current desktop.

----------

QDialog or at least QMessageBox does this and I doubt Lubos' idea was to "allow focus stealing if the client nags enough" - switching the VD is a major interrupt and prevented when a new window shows up. It should not be possible to stomp on ground and then receive focus - notably not on the other desktop.

I assume the original idea was to let clients distribute focus *inside* across virtual desktops, maybe also permit when no client was active, but hardly otherwise.

Reproducible: Always
Comment 1 Thomas Lübking 2016-02-22 21:59:00 UTC
Created attachment 97364 [details]
proof of issue
Comment 2 Thomas Lübking 2016-02-27 10:28:04 UTC
Git commit 0e80a16db57cb194431725aa204e1fa871ea87c6 by Thomas Lübking.
Committed on 27/02/2016 at 10:26.
Pushed by luebking into branch 'master'.

restrict cross-vd activation to in-client distrib

QDialog or at least QMessageBox does this and I doubt Lubos' idea was to
"allow focus stealing if the client nags enough" - switching the VD is a
major interrupt and prevented when a new window shows up.
It should not be possible to stomp on ground and then receive
focus - notably not on the other desktop.

I assume the original idea was to let clients distribute focus *inside*
across virtual desktops, maybe also permit when no client was active,
but hardly otherwise.
FIXED-IN: 5.6
REVIEW: 127153

M  +3    -0    activation.cpp

http://commits.kde.org/kwin/0e80a16db57cb194431725aa204e1fa871ea87c6