summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnne Jan Brouwer <brouwer@annejan.com>2015-08-07 00:29:32 +0200
committerAnne Jan Brouwer <annejan@noprotocol.com>2015-08-07 00:29:32 +0200
commit7afcf1ec6c83905bffd66b770eb8dad144fe0e57 (patch)
tree6c6546806224a1af85efed1b39a908bda706a6e2
parent603dcc4655f67f000b29669aa0540ac449bf478d (diff)
file name in title
-rw-r--r--mainwindow.cpp1
-rw-r--r--passworddialog.cpp4
-rw-r--r--passworddialog.h1
-rw-r--r--passworddialog.ui4
4 files changed, 8 insertions, 2 deletions
diff --git a/mainwindow.cpp b/mainwindow.cpp
index 000ce336..6d9a759c 100644
--- a/mainwindow.cpp
+++ b/mainwindow.cpp
@@ -948,6 +948,7 @@ void MainWindow::setPassword(QString file, bool overwrite, bool isNew = false)
return;
}
PasswordDialog d(this);
+ d.setFile(file);
d.setTemplate(passTemplate);
d.setPassword(lastDecrypt);
if (!d.exec()) {
diff --git a/passworddialog.cpp b/passworddialog.cpp
index 537628a2..8f01b811 100644
--- a/passworddialog.cpp
+++ b/passworddialog.cpp
@@ -82,3 +82,7 @@ void PasswordDialog::setTemplate(QString rawFields) {
ui->formLayout->addRow(new QLabel(field), line);
}
}
+
+void PasswordDialog::setFile(QString file) {
+ this->setWindowTitle(this->windowTitle()+" "+file);
+}
diff --git a/passworddialog.h b/passworddialog.h
index b53c5917..4ba57a50 100644
--- a/passworddialog.h
+++ b/passworddialog.h
@@ -18,6 +18,7 @@ public:
void setPassword(QString);
QString getPassword();
void setTemplate(QString);
+ void setFile(QString);
private slots:
void on_checkBoxShow_stateChanged(int arg1);
diff --git a/passworddialog.ui b/passworddialog.ui
index c38dc105..e4f405fb 100644
--- a/passworddialog.ui
+++ b/passworddialog.ui
@@ -15,13 +15,13 @@
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<property name="leftMargin">
- <number>6</number>
+ <number>4</number>
</property>
<property name="topMargin">
<number>6</number>
</property>
<property name="rightMargin">
- <number>6</number>
+ <number>0</number>
</property>
<property name="bottomMargin">
<number>6</number>