mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-18 22:35:39 +01:00
Add a menu option to verify a signed message
(Also move 'setAttribute(Qt::WA_DeleteOnClose)' out of QRCodeDialog)
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
#include "addressbookpage.h"
|
||||
#include "sendcoinsdialog.h"
|
||||
#include "messagepage.h"
|
||||
#include "verifymessagedialog.h"
|
||||
#include "optionsdialog.h"
|
||||
#include "aboutdialog.h"
|
||||
#include "clientmodel.h"
|
||||
@@ -255,6 +256,8 @@ void BitcoinGUI::createActions()
|
||||
changePassphraseAction->setToolTip(tr("Change the passphrase used for wallet encryption"));
|
||||
openRPCConsoleAction = new QAction(tr("&Debug window"), this);
|
||||
openRPCConsoleAction->setToolTip(tr("Open debugging and diagnostic console"));
|
||||
verifyMessageAction = new QAction(QIcon(":/icons/transaction_0"), tr("&Verify message..."), this);
|
||||
verifyMessageAction->setToolTip(tr("Verify a message signature"));
|
||||
|
||||
connect(quitAction, SIGNAL(triggered()), qApp, SLOT(quit()));
|
||||
connect(optionsAction, SIGNAL(triggered()), this, SLOT(optionsClicked()));
|
||||
@@ -264,6 +267,7 @@ void BitcoinGUI::createActions()
|
||||
connect(encryptWalletAction, SIGNAL(triggered(bool)), this, SLOT(encryptWallet(bool)));
|
||||
connect(backupWalletAction, SIGNAL(triggered()), this, SLOT(backupWallet()));
|
||||
connect(changePassphraseAction, SIGNAL(triggered()), this, SLOT(changePassphrase()));
|
||||
connect(verifyMessageAction, SIGNAL(triggered()), this, SLOT(verifyMessage()));
|
||||
}
|
||||
|
||||
void BitcoinGUI::createMenuBar()
|
||||
@@ -283,6 +287,7 @@ void BitcoinGUI::createMenuBar()
|
||||
#ifndef FIRST_CLASS_MESSAGING
|
||||
file->addAction(messageAction);
|
||||
#endif
|
||||
file->addAction(verifyMessageAction);
|
||||
file->addSeparator();
|
||||
file->addAction(quitAction);
|
||||
|
||||
@@ -405,6 +410,7 @@ void BitcoinGUI::createTrayIcon()
|
||||
trayIconMenu->addAction(openRPCConsoleAction);
|
||||
trayIconMenu->addSeparator();
|
||||
trayIconMenu->addAction(messageAction);
|
||||
trayIconMenu->addAction(verifyMessageAction);
|
||||
#ifndef FIRST_CLASS_MESSAGING
|
||||
trayIconMenu->addSeparator();
|
||||
#endif
|
||||
@@ -836,6 +842,13 @@ void BitcoinGUI::changePassphrase()
|
||||
dlg.exec();
|
||||
}
|
||||
|
||||
void BitcoinGUI::verifyMessage()
|
||||
{
|
||||
VerifyMessageDialog *dlg = new VerifyMessageDialog(walletModel->getAddressTableModel(), this);
|
||||
dlg->setAttribute(Qt::WA_DeleteOnClose);
|
||||
dlg->show();
|
||||
}
|
||||
|
||||
void BitcoinGUI::unlockWallet()
|
||||
{
|
||||
if(!walletModel)
|
||||
|
||||
Reference in New Issue
Block a user