Ctrl-H shortcut to toggle hidden files' visibility
[case] / src / case.cpp
index 6770447..231e230 100644 (file)
@@ -97,6 +97,15 @@ void Case::switchActivePane() {
 }
 
 
+void Case::keyPressEvent(QKeyEvent *e) {
+    if(e->key() == Qt::Key_H && e->modifiers() == Qt::ControlModifier) {
+        activePane->toggleShowHiddenFiles();
+    } else {
+        QMainWindow::keyPressEvent(e);
+    }
+}
+
+
 void Case::clonePane() {
     inactivePane->changePath(activePane->path());
 }