diff options
author | Arno <arno@disconnect.de> | 2015-06-07 05:04:42 +0200 |
---|---|---|
committer | Arno <arno@disconnect.de> | 2015-06-07 05:04:42 +0200 |
commit | 99be8eab42d06e662357b2d99e6da6d9d0ff5926 (patch) | |
tree | 52ca125e3e4214e78a4c1d6ce144b2bb6395bc12 /filesystemwidget.cpp | |
parent | 7ffee99071517f5f5533f067850e732efe171991 (diff) | |
download | SheMov-99be8eab42d06e662357b2d99e6da6d9d0ff5926.tar.gz SheMov-99be8eab42d06e662357b2d99e6da6d9d0ff5926.tar.bz2 SheMov-99be8eab42d06e662357b2d99e6da6d9d0ff5926.zip |
Usability fixes
* start maximized
* focus MappingTree when showing NewPicsDialog
* Keyboard Shortcuts for FilesystemWidget:
CTRL+UP: go to parent dir
CTRL+LEFT: go back
CTRL+U: unpack
* close UnpackDialog when done
Diffstat (limited to 'filesystemwidget.cpp')
-rw-r--r-- | filesystemwidget.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/filesystemwidget.cpp b/filesystemwidget.cpp index 461780f..619944a 100644 --- a/filesystemwidget.cpp +++ b/filesystemwidget.cpp @@ -22,6 +22,7 @@ #include <QProgressDialog> #include <QToolBar> #include <QInputDialog> +#include <QKeyEvent> #include "filesystemwidget.h" #include "filesystemdirproxy.h" @@ -689,6 +690,22 @@ const QString FilesystemWidget::selectedDir(){ return QString(); } +void FilesystemWidget::keyPressEvent(QKeyEvent *e){ + if(e->key() == Qt::Key_Left && (e->modifiers() & Qt::ControlModifier)){ + goBack(); + return; + } + if(e->key() == Qt::Key_Up && (e->modifiers() & Qt::ControlModifier)){ + parentDir(); + return; + } + if(e->key() == Qt::Key_U && (e->modifiers() & Qt::ControlModifier)){ + unpack(); + return; + } + QWidget::keyPressEvent(e); +} + void FilesystemWidget::dirExpanded(const QModelIndex &idx){ QModelIndex real = mDirProxy->mapToSource(idx); if(real.isValid()){ |