aboutsummaryrefslogtreecommitdiff
path: root/src/qt/signverifymessagedialog.cpp
diff options
context:
space:
mode:
authorHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2021-04-08 12:37:25 +0300
committerHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2021-05-01 15:07:09 +0300
commitc054720e08b5549913f54b9b4bc4e4002617ff23 (patch)
tree4713c2d747531e00208e1e3c0c363246109b42f8 /src/qt/signverifymessagedialog.cpp
parent0dcc3fac433b341eb6e1d3a2fb4d2de1595e8e88 (diff)
qt: Make SignVerifyMessageDialog aware of runtime palette change
This change fixes the GUI when changing appearance on macOS.
Diffstat (limited to 'src/qt/signverifymessagedialog.cpp')
-rw-r--r--src/qt/signverifymessagedialog.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/qt/signverifymessagedialog.cpp b/src/qt/signverifymessagedialog.cpp
index 2e7df60574..b982cc577d 100644
--- a/src/qt/signverifymessagedialog.cpp
+++ b/src/qt/signverifymessagedialog.cpp
@@ -283,3 +283,19 @@ bool SignVerifyMessageDialog::eventFilter(QObject *object, QEvent *event)
}
return QDialog::eventFilter(object, event);
}
+
+void SignVerifyMessageDialog::changeEvent(QEvent* e)
+{
+#ifdef Q_OS_MACOS
+ if (e->type() == QEvent::PaletteChange) {
+ ui->addressBookButton_SM->setIcon(platformStyle->SingleColorIcon(QStringLiteral(":/icons/address-book")));
+ ui->pasteButton_SM->setIcon(platformStyle->SingleColorIcon(QStringLiteral(":/icons/editpaste")));
+ ui->copySignatureButton_SM->setIcon(platformStyle->SingleColorIcon(QStringLiteral(":/icons/editcopy")));
+ ui->signMessageButton_SM->setIcon(platformStyle->SingleColorIcon(QStringLiteral(":/icons/edit")));
+ ui->clearButton_SM->setIcon(platformStyle->SingleColorIcon(QStringLiteral(":/icons/remove")));
+ ui->addressBookButton_VM->setIcon(platformStyle->SingleColorIcon(QStringLiteral(":/icons/address-book")));
+ ui->verifyMessageButton_VM->setIcon(platformStyle->SingleColorIcon(QStringLiteral(":/icons/transaction_0")));
+ ui->clearButton_VM->setIcon(platformStyle->SingleColorIcon(QStringLiteral(":/icons/remove")));
+ }
+#endif
+}