mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-07-02 19:52:01 +02:00
overviewpage: make some code Qt5 compatible
- that changes will be fine for Qt4 also
This commit is contained in:
@ -46,9 +46,10 @@ public:
|
||||
bool confirmed = index.data(TransactionTableModel::ConfirmedRole).toBool();
|
||||
QVariant value = index.data(Qt::ForegroundRole);
|
||||
QColor foreground = option.palette.color(QPalette::Text);
|
||||
if(qVariantCanConvert<QColor>(value))
|
||||
if(value.canConvert<QBrush>())
|
||||
{
|
||||
foreground = qvariant_cast<QColor>(value);
|
||||
QBrush brush = qvariant_cast<QBrush>(value);
|
||||
foreground = brush.color();
|
||||
}
|
||||
|
||||
painter->setPen(foreground);
|
||||
|
Reference in New Issue
Block a user