Fix TOTP Dialog not closing on lock

This commit is contained in:
Jonathan White 2019-12-31 12:39:50 -05:00
parent 181ad76ec9
commit 7250fd9313

View File

@ -1,5 +1,5 @@
/* /*
* Copyright (C) 2017 Weslly Honorato <weslly@protonmail.com> * Copyright (C) 2017 Weslly Honorato <weslly@protonmail.com>
* Copyright (C) 2017 KeePassXC Team <team@keepassxc.org> * Copyright (C) 2017 KeePassXC Team <team@keepassxc.org>
* *
* This program is free software: you can redistribute it and/or modify * This program is free software: you can redistribute it and/or modify
@ -42,7 +42,7 @@ TotpDialog::TotpDialog(QWidget* parent, Entry* entry)
resetCounter(); resetCounter();
updateProgressBar(); updateProgressBar();
connect(parent, SIGNAL(lockedDatabase()), SLOT(close())); connect(parent, SIGNAL(databaseLocked()), SLOT(close()));
connect(&m_totpUpdateTimer, SIGNAL(timeout()), this, SLOT(updateProgressBar())); connect(&m_totpUpdateTimer, SIGNAL(timeout()), this, SLOT(updateProgressBar()));
connect(&m_totpUpdateTimer, SIGNAL(timeout()), this, SLOT(updateSeconds())); connect(&m_totpUpdateTimer, SIGNAL(timeout()), this, SLOT(updateSeconds()));
m_totpUpdateTimer.start(m_step * 10); m_totpUpdateTimer.start(m_step * 10);