forked from osmocom/wireshark
Qt: fix role check in AStringListListUrlProxyModel::data
Change-Id: I7c683449155f7dcb63731e6575cf92c30be78934 Fixes: v2.5.0rc0-1841-gd865871627 ("Qt: About Dialog move to QTreeView and fix copy") Reviewed-on: https://code.wireshark.org/review/24637 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Michael Mann <mmann78@netscape.net>
This commit is contained in:
parent
18b240d7d2
commit
e29378b030
|
@ -175,7 +175,7 @@ QVariant AStringListListUrlProxyModel::data(const QModelIndex &index, int role)
|
|||
|
||||
if ( urls_.contains(index.column()) )
|
||||
{
|
||||
if ( Qt::ForegroundRole )
|
||||
if ( role == Qt::ForegroundRole )
|
||||
{
|
||||
if ( result.canConvert(QVariant::Brush) )
|
||||
{
|
||||
|
@ -183,7 +183,7 @@ QVariant AStringListListUrlProxyModel::data(const QModelIndex &index, int role)
|
|||
selected.setColor(QApplication::palette().link().color());
|
||||
return selected;
|
||||
}
|
||||
} else if ( Qt::TextColorRole ) {
|
||||
} else if ( role == Qt::TextColorRole ) {
|
||||
return QApplication::palette().link().color();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue