Summary: | Shortcut to switch focus to file/folder view after using filter bar | ||
---|---|---|---|
Product: | [Applications] dolphin | Reporter: | Jens Rutschmann <Jens.Rutschmann> |
Component: | bars: filter | Assignee: | Dolphin Bug Assignee <dolphin-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | wishlist | ||
Priority: | NOR | ||
Version: | 2.0 | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | http://commits.kde.org/kde-baseapps/2f0114730d1f5c3dfaee833300168b8e16b068f2 | Version Fixed In: | 4.11.0 |
Attachments: | Patch for suggestion in comment #1 |
Description
Jens Rutschmann
2012-03-30 20:39:05 UTC
Can't we simply switch focus back to the file/folder view when pressing the return key ? Filtering itself is done on the fly when entering some characters, so pressing return could 'confirm' the filter results and switch the focus back. I think this would improve keyboard-only usage of the filter bar greatly. Created attachment 73089 [details] Patch for suggestion in comment #1 The attached patch returns focus back to the file/folder view when pressing return in the filter bar. I don't know if this is the perfect way to do this as I'm not really an experienced C++ programmer, but it works :-) It is better to use reviewboard.kde.org for submitting patch. Patches attached in bugzilla are easily to b flood by many other messages and forgotton. Resetting assignee to default as per bug #305719 (In reply to comment #3) > It is better to use reviewboard.kde.org for submitting patch. Patches > attached in bugzilla are easily to b flood by many other messages and > forgotton. Hi, I signed up to git.reviewboard.kde.org and tried to submit the patch, but reviewboard insists on telling me that my patch file is no diff :-( Even after I renamed it to .diff ... Thanks for the report and the patch! I was not aware of this report at all - I am only notified about all new comments to existing bug reports since the assignee change on August 24. I have no idea why ReviewBoard doesn't like your patch :-( Anyway, I think that the idea to focus the view when Return is pressed in the filter bar is nice :-) Some notes on the implementation: 1. We should not only test for the "Return" key, but also for "Enter". These are considered mostly equivalent by users, so we should treat them equally. 2. The cleaner solution (even though it requires more code) would be to use signals and slots to tell the DolphinViewContainer to change the focus. Look how the Escape key is handled - maybe we could do something similar here and add a new signal "focusViewRequest" which is connected to a new slot in the view container that focuses the view. (In reply to comment #6) I finally found some time and adapted the patch to your suggestions. You may find it here: https://git.reviewboard.kde.org/r/109020/ Git commit 2f0114730d1f5c3dfaee833300168b8e16b068f2 by Frank Reininghaus, on behalf of Jens Rutschmann. Committed on 19/02/2013 at 22:42. Pushed by freininghaus into branch 'master'. Return the focus from the filter bar to the view if Enter is pressed FIXED-IN: 4.11.0 REVIEW: 109020 M +8 -0 dolphin/src/dolphinviewcontainer.cpp M +5 -0 dolphin/src/dolphinviewcontainer.h M +12 -1 dolphin/src/filterbar/filterbar.cpp M +5 -0 dolphin/src/filterbar/filterbar.h http://commits.kde.org/kde-baseapps/2f0114730d1f5c3dfaee833300168b8e16b068f2 |