diff options
author | Arno <arno@disconnect.de> | 2018-02-03 04:19:54 +0100 |
---|---|---|
committer | Arno <arno@disconnect.de> | 2018-02-03 04:20:57 +0100 |
commit | 65c61cf5ef74ef4be386e0e6a9bc056f34bc6adc (patch) | |
tree | 0681f3e281b2331f3aebb68aea881dff1d7e11d0 /filewidget.cpp | |
parent | a36cd9c8b352e94fd9e3be4f90ea6255b0c40618 (diff) | |
download | ShemovCleaner-65c61cf5ef74ef4be386e0e6a9bc056f34bc6adc.tar.gz ShemovCleaner-65c61cf5ef74ef4be386e0e6a9bc056f34bc6adc.tar.bz2 ShemovCleaner-65c61cf5ef74ef4be386e0e6a9bc056f34bc6adc.zip |
Add keyboard shortcuts in SearchDialog
CTRL+F: search filename
CTRL+L: select all and focus search
CTRL+M: search actor
CTRL+T: search title
CTRL+X: hide
Unfortunately, it's surprisingly hard to capture CTRL+A, so I chose CTRL
+M (m for model) for actor search. CTRL+A is consumed by some other
Widget and never reaches SearchDialog. Maybe an EventFilter in the
parent or the MainWindow would work, but that's not worth it.
Diffstat (limited to 'filewidget.cpp')
-rw-r--r-- | filewidget.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/filewidget.cpp b/filewidget.cpp index 51426a4..a56d1fa 100644 --- a/filewidget.cpp +++ b/filewidget.cpp @@ -924,6 +924,7 @@ void FileWidget::keyPressEvent(QKeyEvent *e){ if(e->key() == Qt::Key_S && (e->modifiers() & Qt::ControlModifier)){ mSearchDlg->show(); mSearchDlg->raise(); + mSearchDlg->setFocus(); goto exit; } if(e->key() == Qt::Key_D && (e->modifiers() & Qt::ControlModifier)){ |