diff options
author | Sami Vänttinen <sami.vanttinen@protonmail.com> | 2022-01-30 18:59:29 +0300 |
---|---|---|
committer | Jonathan White <support@dmapps.us> | 2022-02-24 01:48:50 +0300 |
commit | 67910249952e4e77535d8ecde2fe589fe32f64da (patch) | |
tree | 961ebe77f74e3e3694b809498d5ca66cd9e6bac1 /src/gui | |
parent | 4f0710350fb53c25db6824f96961d8d17a29347c (diff) |
Fix new password generator closed reply with Browser Integration (#7359)
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/PasswordGeneratorWidget.cpp | 8 | ||||
-rw-r--r-- | src/gui/PasswordGeneratorWidget.h | 4 |
2 files changed, 10 insertions, 2 deletions
diff --git a/src/gui/PasswordGeneratorWidget.cpp b/src/gui/PasswordGeneratorWidget.cpp index 32e559418..1fd6cc972 100644 --- a/src/gui/PasswordGeneratorWidget.cpp +++ b/src/gui/PasswordGeneratorWidget.cpp @@ -1,6 +1,6 @@ /* * Copyright (C) 2013 Felix Geyer <debfx@fobos.de> - * Copyright (C) 2021 KeePassXC Team <team@keepassxc.org> + * Copyright (C) 2022 KeePassXC Team <team@keepassxc.org> * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -294,6 +294,7 @@ void PasswordGeneratorWidget::updatePasswordStrength(const QString& password) void PasswordGeneratorWidget::applyPassword() { saveSettings(); + m_passwordGenerated = true; emit appliedPassword(m_ui->editNewPassword->text()); emit closed(); } @@ -341,6 +342,11 @@ bool PasswordGeneratorWidget::isPasswordVisible() const return m_ui->editNewPassword->isPasswordVisible(); } +bool PasswordGeneratorWidget::isPasswordGenerated() const +{ + return m_passwordGenerated; +} + void PasswordGeneratorWidget::deleteWordList() { if (m_ui->comboBoxWordList->currentIndex() < m_firstCustomWordlistIndex) { diff --git a/src/gui/PasswordGeneratorWidget.h b/src/gui/PasswordGeneratorWidget.h index 57b331bb8..80b3f26de 100644 --- a/src/gui/PasswordGeneratorWidget.h +++ b/src/gui/PasswordGeneratorWidget.h @@ -1,6 +1,6 @@ /* * Copyright (C) 2013 Felix Geyer <debfx@fobos.de> - * Copyright (C) 2021 KeePassXC Team <team@keepassxc.org> + * Copyright (C) 2022 KeePassXC Team <team@keepassxc.org> * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -53,6 +53,7 @@ public: void setStandaloneMode(bool standalone); QString getGeneratedPassword(); bool isPasswordVisible() const; + bool isPasswordGenerated() const; static PasswordGeneratorWidget* popupGenerator(QWidget* parent = nullptr); @@ -82,6 +83,7 @@ private slots: private: bool m_standalone = false; + bool m_passwordGenerated = false; int m_firstCustomWordlistIndex; void closeEvent(QCloseEvent* event); |