summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnne Jan Brouwer <brouwer@annejan.com>2015-05-27 02:24:03 +0200
committerAnne Jan Brouwer <brouwer@annejan.com>2015-05-27 02:24:03 +0200
commit45b7744e1eadbad557e7ac0a085c0164a0821159 (patch)
treea3e8af20ce4045dd1aa9a5b504c9e00a2104d6c6
parentcbb502768a28642de2458603cf79e70d4cc078ca (diff)
randomfixes
-rw-r--r--dialog.cpp3
-rw-r--r--mainwindow.cpp4
2 files changed, 5 insertions, 2 deletions
diff --git a/dialog.cpp b/dialog.cpp
index bb3a5912..e8ba9a99 100644
--- a/dialog.cpp
+++ b/dialog.cpp
@@ -4,6 +4,7 @@
#include "keygendialog.h"
#include <QDebug>
#include <QMessageBox>
+#include <QDir>
/**
* @brief Dialog::Dialog
@@ -164,6 +165,7 @@ QString Dialog::selectExecutable() {
QString Dialog::selectFolder() {
QFileDialog dialog(this);
dialog.setFileMode(QFileDialog::Directory);
+ dialog.setFilter(QDir::NoFilter);
dialog.setOption(QFileDialog::ShowDirsOnly);
if (dialog.exec()) {
return dialog.selectedFiles().first();
@@ -386,6 +388,7 @@ void Dialog::wizard()
tr("The folder %1 doesn't seem to be a password store or is not yet initialised.").arg(passStore));
while(!QFile(passStore).exists()) {
on_toolButtonStore_clicked();
+ passStore = ui->storePath->text();
}
if (!QFile(passStore + ".gpg-id").exists()) {
// apears not to be store
diff --git a/mainwindow.cpp b/mainwindow.cpp
index edb2a976..381d4e18 100644
--- a/mainwindow.cpp
+++ b/mainwindow.cpp
@@ -269,10 +269,10 @@ void MainWindow::config() {
settings.setValue("hideContent", hideContent ? "true" : "false");
settings.setValue("addGPGId", addGPGId ? "true" : "false");
- ui->treeView->setRootIndex(model.setRootPath(passStore));
+ ui->treeView->setRootIndex(proxyModel.mapFromSource(model.setRootPath(passStore)));
if (firstRun && Util::checkConfig(passStore, passExecutable, gpgExecutable)) {
- config(); // loop !!
+ config();
}
updateEnv();
}