Bug 219052 - When I press F8 to compile project, keyboard focus gets stolen from source editor
Summary: When I press F8 to compile project, keyboard focus gets stolen from source ed...
Status: RESOLVED FIXED
Alias: None
Product: kdevplatform
Classification: Developer tools
Component: outputview (show other bugs)
Version: git master
Platform: unspecified Linux
: VHI normal
Target Milestone: 1.0.0
Assignee: kdevelop-bugs-null
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-12-17 11:47 UTC by Dmitry Suzdalev
Modified: 2010-01-13 08:23 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
Don't change focus when activating dock widgets (1.58 KB, patch)
2009-12-31 16:13 UTC, Olivier.jg
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dmitry Suzdalev 2009-12-17 11:47:59 UTC
Version:           3.9.97 (using KDevPlatform 0.9.97) (using 4.3.82 (KDE 4.3.82 (KDE 4.4 >= 20091211)), compiled sources)
Compiler:          gcc
OS:                Linux (i686) release 2.6.31-ARCH

Whenever I press F8 to perform building, the build output toolview gets open and keyboard input focus gets stolen from the source editor, so I'm unable to continue editing while building - without reaching my mouse and clicking back in the source editor.

This is rather inconvenient :)

Steps to reproduce:
1. Have some source file opened
2. Press F8 to start building
3. Build tool view will be activated to show building progress 
4. Try to continue editing source - keyboard focus is not in source view => not possible

Expected results:
- I press F8, build starts
- I continue editing my program, with keyboard focus remaining in source editor

KDE: from trunk, Revision: 1063170
Qt: 4.6.0 kde-qt/master
Comment 1 Olivier.jg 2009-12-31 16:13:41 UTC
Created attachment 39483 [details]
Don't change focus when activating dock widgets

The problem is on sublime. When those dock widgets are requested to be shown or hidden in any way, Sublime will trigger a checked action that will end with the dock widget getting setFocus()ed.
The patch attached will change that behavior so that dock widgets don't get activated when shown. I view this as reasonable for two reasons:
1. If it steals my focus, I may get angry, if I request it with a click, my mouse is close enough to make another, if indeed I even wanted to select the contents of the widget, and not just view them.
2. It so happens that none of the dock widgets do a setProxyFocus. That means that when these dock widgets are shown, you don't get a useful focus anyhow.

IOW, as it stands, this is a clear improvement, and IMO, this is the way things should be going forward.

Unless anyone has any objections, I'll commit this.
Comment 2 Olivier.jg 2010-01-13 08:23:43 UTC
SVN commit 1073899 by olivierjg:

Don't setFocus when showing toolviews.
BUG: 219052


 M  +1 -1      ideal.cpp  
 M  +4 -2      ideallayout.cpp  
 M  +1 -1      ideallayout.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1073899