Bug 291916

Summary: [JJ] Select next window with arrow key in Alt+Tab
Product: [Plasma] kwin Reporter: eric.erfanian
Component: tabboxAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED FIXED    
Severity: wishlist Keywords: junior-jobs
Priority: NOR    
Version: 4.7.4   
Target Milestone: 4.9   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed In: 4.9.0
Sentry Crash Report:
Bug Depends on: 178595    
Bug Blocks:    

Description eric.erfanian 2012-01-19 01:13:58 UTC
Version:           4.7.4 (using KDE 4.7.4) 
OS:                Linux

It's great that I can switch through open windows with alt + tab or alt + shift + tab, but I think it would be even better if one could press the left or right arrow keys to switch windows while the window switcher is open, as well. 

I know you can set additional key-bindings for the action, but being able to push the left or right arrow key while the switcher is open would be great, and wouldn't interfere with other desktop functions.

Reproducible: Always

Steps to Reproduce:
1) Open the window switcher
2) Attempt to switch windows with the arrow key

Actual Results:  
3) No action occurs.

Expected Results:  
Windows should move left or right with the arrow keys when the window switcher is open.
Comment 1 Martin Flöser 2012-01-19 06:54:40 UTC
In the layout based switchers the up and down keys are supported. In Present Windows all arrow keys are supported. So only left/right in layout based switcher is needed (in fact the layout itself should decide what is useful) and Cover/Flip Switch do not support arrow keys.
Comment 2 eric.erfanian 2012-01-19 13:42:00 UTC
Thanks, that is good to know. It was in the cover switch that I thought this functionality would be useful.
Comment 3 Martin Flöser 2012-03-25 10:52:23 UTC
Commit was not picked up due to unresolved bug dependency.

Git commit 760c4deff24414ab13e2265103791275db474d78 by Martin Gräßlin.
Committed on 20/03/2012 at 20:01.
Pushed by graesslin into branch 'master'.

Add proper key navigation to layout based window switchers

The grabbed key events inside TabBox are forwarded to the declarative
view which passes it to the normal keyPressedEvent() method. This
allows the QML files to handle keyboard navigation themselves.

The views support key navigation natively, though this cannot be
used as we need to update the ModelIndex when a new item is selected.
Also there seems to be a problem if the tabbox is shown again, in
that case the focus seems to be somehow lost. Because of that the
navigation is handled in the Item embedding the list.

REVIEW: 104357
FEATURE: 291916
FIXED-IN: 4.9.0

M  +5    -0    kwin/tabbox/declarative.cpp
M  +1    -0    kwin/tabbox/declarative.h
M  +15   -0    kwin/tabbox/qml/IconTabBox.qml
M  +15   -0    kwin/tabbox/qml/clients/compact/contents/ui/main.qml
M  +15   -0    kwin/tabbox/qml/clients/informative/contents/ui/main.qml
M  +21   -0    kwin/tabbox/qml/clients/present_windows/contents/ui/main.qml
M  +15   -0    kwin/tabbox/qml/clients/text/contents/ui/main.qml
M  +15   -0    kwin/tabbox/qml/clients/thumbnails/contents/ui/main.qml
M  +1    -0    kwin/tabbox/qml/tabbox.qml
M  +2    -1    kwin/tabbox/tabbox.cpp
M  +5    -47   kwin/tabbox/tabboxhandler.cpp
M  +1    -6    kwin/tabbox/tabboxhandler.h

http://commits.kde.org/kde-workspace/760c4deff24414ab13e2265103791275db474d78
Comment 4 Martin Flöser 2012-04-01 06:10:20 UTC
and the blocking bug is fixed, so this one is also closed :-)