Dialogs: move destructor to bottom

This commit is contained in:
tobtoht 2021-06-27 14:25:10 +02:00
parent 6921d7b1a7
commit 482ad9cd7e
No known key found for this signature in database
GPG key ID: 1CADD27F41F45C3C
6 changed files with 16 additions and 17 deletions

View file

@ -25,12 +25,12 @@ ContactsDialog::ContactsDialog(QWidget *parent, const QString &address, const QS
this->adjustSize();
}
ContactsDialog::~ContactsDialog() = default;
QString ContactsDialog::getAddress() {
return m_address;
}
QString ContactsDialog::getName() {
return m_name;
}
}
ContactsDialog::~ContactsDialog() = default;

View file

@ -40,8 +40,6 @@ PasswordChangeDialog::PasswordChangeDialog(QWidget *parent, Wallet *wallet)
this->adjustSize();
}
PasswordChangeDialog::~PasswordChangeDialog() = default;
void PasswordChangeDialog::passwordsMatch() {
bool match = ui->lineEdit_newPassword->text() == ui->lineEdit_confirmPassword->text();
ui->btn_OK->setEnabled(match);
@ -66,4 +64,6 @@ void PasswordChangeDialog::setPassword() {
else {
QMessageBox::warning(this, "Error", QString("Error: %1").arg(m_wallet->errorString()));
}
}
}
PasswordChangeDialog::~PasswordChangeDialog() = default;

View file

@ -27,8 +27,6 @@ QrCodeDialog::QrCodeDialog(QWidget *parent, const QrCode &qrCode, const QString
this->adjustSize();
}
QrCodeDialog::~QrCodeDialog() = default;
void QrCodeDialog::setQrCode(const QrCode &qrCode) {
m_pixmap = qrCode.toPixmap(1).scaled(500, 500, Qt::KeepAspectRatio);
ui->QrCode->setPixmap(m_pixmap);
@ -49,4 +47,6 @@ void QrCodeDialog::saveImage() {
file.open(QIODevice::WriteOnly);
m_pixmap.save(&file, "PNG");
QMessageBox::information(this, "Information", "QR code saved to file");
}
}
QrCodeDialog::~QrCodeDialog() = default;

View file

@ -226,5 +226,4 @@ TxProof TxProofDialog::getProof() {
return proof;
}
TxProofDialog::~TxProofDialog() = default;
TxProofDialog::~TxProofDialog() = default;

View file

@ -53,8 +53,6 @@ VerifyProofDialog::VerifyProofDialog(Wallet *wallet, QWidget *parent)
ui->input_formattedProof->setFont(ModelUtils::getMonospaceFont());
}
VerifyProofDialog::~VerifyProofDialog() = default;
void VerifyProofDialog::checkProof() {
switch (ui->tabWidget->currentIndex()) {
case 0:
@ -170,4 +168,6 @@ void VerifyProofDialog::proofStatus(bool success, const QString &message) {
success ? QMessageBox::information(this, "Information", message)
: QMessageBox::warning(this, "Warning", message);
}
}
}
VerifyProofDialog::~VerifyProofDialog() = default;

View file

@ -27,10 +27,10 @@ WalletInfoDialog::WalletInfoDialog(QSharedPointer<AppContext> ctx, QWidget *pare
this->adjustSize();
}
WalletInfoDialog::~WalletInfoDialog() = default;
void WalletInfoDialog::openWalletDir() {
QFileInfo file(m_ctx->wallet->keysPath());
QDesktopServices::openUrl(QUrl(QString("file://%1").arg(file.absolutePath()), QUrl::TolerantMode));
}
}
WalletInfoDialog::~WalletInfoDialog() = default;