Bug 343487

Summary: Context menu on window title brokes the focus
Product: [Plasma] kwin Reporter: Alexander <vo.zaeb>
Component: decorationsAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED DUPLICATE    
Severity: normal    
Priority: NOR    
Version: 5.2.0.1   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: Kwin decorations context menu
Regular context menu

Description Alexander 2015-01-28 23:45:08 UTC
After opening context menu on window title it is impossible to set focus to text fields inside the window.

Reproducible: Always

Steps to Reproduce:
1. Open dolphin.
2. Click on the address bar so it gets transformed into a text field.
2. Right click on Dolphin's title (to open the context menu).
3. Try to type to the address bar.



Also noticed this context menu does not have shadows (see attachments).
Comment 1 Alexander 2015-01-28 23:45:39 UTC
Created attachment 90764 [details]
Kwin decorations context menu
Comment 2 Alexander 2015-01-28 23:46:17 UTC
Created attachment 90765 [details]
Regular context menu
Comment 3 Thomas Lübking 2015-01-28 23:56:05 UTC
Shadows are (likely) an oxygen issue (I get them w/ the virtuality style)

About the popup:
popup menus grab the unput (mouse & focus) - you cannot interact with other windows while _any_ popup menu is open.
Is that the issue or does the window completely refuse focus even after the popup is closed?
Comment 4 Alexander 2015-01-29 00:01:11 UTC
> or does the window completely refuse focus even after the popup is closed?
Yup, that's the case. Even after you close the popup you can't enter text to text fields. For example in amarok I still can switch tracks (even though all tracks I select look like "inactive selection"), but can't focus text field above the playlist to apply a filter.
Comment 5 Thomas Lübking 2015-01-29 00:04:09 UTC
Does it also happen after a
  kwin_x11 --replace &
in the running session (ie. restarting KWin w/o logging out/in)?

*** This bug has been marked as a duplicate of bug 340996 ***
Comment 6 Alexander 2015-01-29 00:08:03 UTC
No, kwin_x11 --replace solves the problem. Might be related to KDE's sessions (I do use "restore manually saved session").
Comment 7 Thomas Lübking 2015-01-29 00:42:46 UTC
Unlikely - the problem is some weird double FocusOut event, see
https://bugs.kde.org/show_bug.cgi?id=340996#c13

We don't know why that occurs and why only on first launch (and obviously the special condition makes it not easier to debug...)
Comment 8 Alexander 2015-01-29 08:43:29 UTC
Not related to sessions, just tried with a clear session and the problem still persists. BTW, kwin replace also solves the shadow issue on this menu.