Summary: | click on an entry of the context menu of systray icons has no effect on Wayland | ||
---|---|---|---|
Product: | [Plasma] plasmashell | Reporter: | Patrick Silva <bugseforuns> |
Component: | System Tray | Assignee: | Plasma Bugs List <plasma-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | kde, meven29, nate |
Priority: | NOR | Keywords: | wayland |
Version: | master | Flags: | kde:
Wayland+
|
Target Milestone: | 1.0 | ||
Platform: | Neon | ||
OS: | Linux | ||
URL: | https://phabricator.kde.org/D26233 | ||
Latest Commit: | https://commits.kde.org/kwin/89024e2bcc1b2c2bae6bd75e85792cc67de9337c | Version Fixed In: | 5.18.0 |
Description
Patrick Silva
2019-12-18 14:29:46 UTC
mouse input also does not work with context menus of kickoff and kicker. menus of Spectacle buttons are also affected. open Spectacle on Wayland click on any button with down arrow on bottom the menu just closes itself when an entry is clicked. Also no hovering affect. Things I have learned so far for the system tray popup case: - Qt menu correctly sends a grab on the popup - kwin correctly receives the grab on the popup in PopupInputFilter - Qt does not get a pointer_enter event to the popup, only the panel underneath - Qt then sends input to the window it has been told has focus Git bisect shows it has being introduced during the big CSD patchset. Can't quite work out which one as they're all tied together and some commits don't work. # good: [c22546868d75e94cd1a31b89daddd002555f1919] [effects] fix mouse wheel detection git bisect good c22546868d75e94cd1a31b89daddd002555f1919 # good: [f62086f9d3518c0c7e0a3cf34981e0aa57b543d1] [effects] Remove unneeded link to KService git bisect good f62086f9d3518c0c7e0a3cf34981e0aa57b543d1 # bad: [754b72d155820a6c8a9ba94b2c0960da1b2f86ce] [x11] Name client pixmap instead of frame pixmap git bisect bad 754b72d155820a6c8a9ba94b2c0960da1b2f86ce # bad: [84d75cb5674577098d584c7f3634ea2a81d8b9f2] [x11] Add support for _GTK_FRAME_EXTENTS git bisect bad 84d75cb5674577098d584c7f3634ea2a81d8b9f2 # good: [6bfa931f2b1d9787e75c4be4e44611d51ba835c3] Associate output transforms and orientations git bisect good 6bfa931f2b1d9787e75c4be4e44611d51ba835c3 Found it!
>void XdgShellClient::handleWindowGeometryChanged(const QRect &windowGeometry)
{
qDebug() << this << "handleWindowGeometryChanged" << windowGeometry;
const QRect boundingRect = subSurfaceTreeRect(surface());
m_windowGeometry = windowGeometry & boundingRect; <--- HERE!!!
m_hasWindowGeometry = true;
Bounding rect is null as we don't have a surface at the time of doing initial placement. We just have a pending initial size.
This gets us in a messed up state, where we think the window is 1x1 with just a really massive giant animating frame.
Also the cause of the weird "ghost" notifications that you can't interact with.
See D26233 Git commit 89024e2bcc1b2c2bae6bd75e85792cc67de9337c by David Edmundson. Committed on 06/01/2020 at 15:10. Pushed by davidedmundson into branch 'master'. Clamp XdgShellClient::clientSize to surface size, not m_windowGeometry Summary: It's perfectly legitimate to call setWindowSize before a buffer is attached. This seems to have happen with plasma surfaces that commit when attaching a shadow, but technically could happen anywhere. By clamping to the applied surface here, we get the wrong window size cached and not re-evaluated when a surface is eventually applied. This leaves us thinking the windowsize is empty but with a massive margin which actually holds the content. We want all internal usages of xdgshellclient to use the window geometry set. Only the wider kwin part needs to care about clamping it to the surface. This fixes popup placement in the plasma panel As well as ghost notification popups with no background contrast that you can't interact with. Test Plan: Ran kwin Reviewers: #kwin, zzag Reviewed By: #kwin, zzag Subscribers: romangg, kwin Tags: #kwin Differential Revision: https://phabricator.kde.org/D26233 M +22 -22 xdgshellclient.cpp https://commits.kde.org/kwin/89024e2bcc1b2c2bae6bd75e85792cc67de9337c |