summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2011-07-11 08:43:08 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2011-07-11 08:43:08 (GMT)
commit2f1e44e42f9ac399ed5c3625df5316073317b0e9 (patch)
tree6b372da0a2a1833bfec369c1625b15e5707746d0
parentdbf13a822e18b3c14bf2b9917a7f81e71e2eca5b (diff)
parentd6e0a50e443f869c4ced17453f0ea269a86ca453 (diff)
downloadQt-2f1e44e42f9ac399ed5c3625df5316073317b0e9.zip
Qt-2f1e44e42f9ac399ed5c3625df5316073317b0e9.tar.gz
Qt-2f1e44e42f9ac399ed5c3625df5316073317b0e9.tar.bz2
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-water-team
* 'master' of git://scm.dev.nokia.troll.no/qt/qt-water-team: QProgressBar: transparent background on Windows Vista (partId: PP_BAR -> PP_TRANSPARENTBAR)
-rw-r--r--src/gui/styles/qwindowsvistastyle.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gui/styles/qwindowsvistastyle.cpp b/src/gui/styles/qwindowsvistastyle.cpp
index da484ba..b894eb4 100644
--- a/src/gui/styles/qwindowsvistastyle.cpp
+++ b/src/gui/styles/qwindowsvistastyle.cpp
@@ -76,6 +76,10 @@ static const int windowsRightBorder = 15; // right border on windows
# define CMDLGS_PRESSED 3
# define CMDLGS_DISABLED 4
#endif
+#ifndef PP_TRANSPARENTBAR
+# define PP_TRANSPARENTBAR 11
+# define PP_TRANSPARENTBARVERT 12
+#endif
// Runtime resolved theme engine function calls
@@ -1059,6 +1063,19 @@ void QWindowsVistaStyle::drawControl(ControlElement element, const QStyleOption
}
break;
#ifndef QT_NO_PROGRESSBAR
+ case CE_ProgressBarGroove:
+ {
+ Qt::Orientation orient = Qt::Horizontal;
+ if (const QStyleOptionProgressBarV2 *pb2 = qstyleoption_cast<const QStyleOptionProgressBarV2 *>(option))
+ orient = pb2->orientation;
+ partId = (orient == Qt::Horizontal) ? PP_TRANSPARENTBAR : PP_TRANSPARENTBARVERT;
+ name = QLatin1String("PROGRESS");
+ stateId = 1;
+
+ XPThemeData theme(widget, painter, name, partId, stateId, rect);
+ d->drawBackground(theme);
+ }
+ break;
case CE_ProgressBarContents:
if (const QStyleOptionProgressBar *bar
= qstyleoption_cast<const QStyleOptionProgressBar *>(option)) {