diff options
author | Olivier Goffart <olivier.goffart@nokia.com> | 2010-05-17 18:00:03 (GMT) |
---|---|---|
committer | Olivier Goffart <olivier.goffart@nokia.com> | 2010-05-17 18:00:03 (GMT) |
commit | 91a1f7a1c408052b1d284d6b901819964e338fe5 (patch) | |
tree | df7103f0ea0cb9d98f4b641d72c0f8b0ebdf2498 /src/gui/widgets/qcombobox.cpp | |
parent | 94a3356d5eb7b255d439efe2699bf3a9b025e8eb (diff) | |
parent | 509ef11ab4ba6165c16d9d311c4a1bf7cdfd2528 (diff) | |
download | Qt-91a1f7a1c408052b1d284d6b901819964e338fe5.zip Qt-91a1f7a1c408052b1d284d6b901819964e338fe5.tar.gz Qt-91a1f7a1c408052b1d284d6b901819964e338fe5.tar.bz2 |
Merge remote branch 'origin/4.6' into qt-4.7-from-4.6
Conflicts:
demos/demos.pro
mkspecs/features/resources.prf
mkspecs/features/uic.prf
src/corelib/io/qurl.cpp
src/corelib/tools/qlocale_symbian.cpp
src/gui/graphicsview/qgraphicsscene.cpp
src/gui/graphicsview/qgraphicswidget_p.cpp
src/gui/graphicsview/qgraphicswidget_p.h
src/gui/util/qsystemtrayicon_win.cpp
src/multimedia/audio/qaudioinput.cpp
tests/auto/qhostinfo/qhostinfo.pro
Diffstat (limited to 'src/gui/widgets/qcombobox.cpp')
-rw-r--r-- | src/gui/widgets/qcombobox.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gui/widgets/qcombobox.cpp b/src/gui/widgets/qcombobox.cpp index e0b09aa..1504066 100644 --- a/src/gui/widgets/qcombobox.cpp +++ b/src/gui/widgets/qcombobox.cpp @@ -152,7 +152,10 @@ QStyleOptionMenuItem QComboMenuDelegate::getStyleOption(const QStyleOptionViewIt menuOption.icon = qvariant_cast<QPixmap>(variant); break; } - + if (qVariantCanConvert<QBrush>(index.data(Qt::BackgroundRole))) { + menuOption.palette.setBrush(QPalette::All, QPalette::Background, + qvariant_cast<QBrush>(index.data(Qt::BackgroundRole))); + } menuOption.text = index.model()->data(index, Qt::DisplayRole).toString() .replace(QLatin1Char('&'), QLatin1String("&&")); menuOption.tabWidth = 0; |