File tree Expand file tree Collapse file tree 2 files changed +21
-2
lines changed
Expand file tree Collapse file tree 2 files changed +21
-2
lines changed Original file line number Diff line number Diff line change 3737#include < QUrl>
3838#include < QVBoxLayout>
3939
40- TransactionView::TransactionView (const PlatformStyle *platformStyle, QWidget *parent) :
41- QWidget(parent)
40+ TransactionView::TransactionView (const PlatformStyle *platformStyle, QWidget *parent)
41+ : QWidget(parent), m_platform_style{platformStyle}
4242{
4343 // Build filter row
4444 setContentsMargins (0 ,0 ,0 ,0 );
@@ -243,6 +243,20 @@ void TransactionView::setModel(WalletModel *_model)
243243 }
244244}
245245
246+ void TransactionView::changeEvent (QEvent* e)
247+ {
248+ #ifdef Q_OS_MACOS
249+ if (e->type () == QEvent::PaletteChange) {
250+ watchOnlyWidget->setItemIcon (
251+ TransactionFilterProxy::WatchOnlyFilter_Yes,
252+ m_platform_style->SingleColorIcon (QStringLiteral (" :/icons/eye_plus" )));
253+ watchOnlyWidget->setItemIcon (
254+ TransactionFilterProxy::WatchOnlyFilter_No,
255+ m_platform_style->SingleColorIcon (QStringLiteral (" :/icons/eye_minus" )));
256+ }
257+ #endif
258+ }
259+
246260void TransactionView::chooseDate (int idx)
247261{
248262 if (!transactionProxyModel) return ;
Original file line number Diff line number Diff line change @@ -60,6 +60,9 @@ class TransactionView : public QWidget
6060 MINIMUM_COLUMN_WIDTH = 23
6161 };
6262
63+ protected:
64+ void changeEvent (QEvent* e) override ;
65+
6366private:
6467 WalletModel *model{nullptr };
6568 TransactionFilterProxy *transactionProxyModel{nullptr };
@@ -85,6 +88,8 @@ class TransactionView : public QWidget
8588
8689 bool eventFilter (QObject *obj, QEvent *event) override ;
8790
91+ const PlatformStyle* m_platform_style;
92+
8893private Q_SLOTS:
8994 void contextualMenu (const QPoint &);
9095 void dateRangeChanged ();
You can’t perform that action at this time.
0 commit comments