summaryrefslogtreecommitdiffstats
path: root/src/plugins/styles/windowsvista
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/styles/windowsvista')
-rw-r--r--src/plugins/styles/windowsvista/qwindowsvistastyle.cpp11
-rw-r--r--src/plugins/styles/windowsvista/qwindowsvistastyle_p_p.h2
-rw-r--r--src/plugins/styles/windowsvista/qwindowsxpstyle.cpp3
-rw-r--r--src/plugins/styles/windowsvista/windowsvista.pro4
4 files changed, 13 insertions, 7 deletions
diff --git a/src/plugins/styles/windowsvista/qwindowsvistastyle.cpp b/src/plugins/styles/windowsvista/qwindowsvistastyle.cpp
index e213d65946..e8d74180cd 100644
--- a/src/plugins/styles/windowsvista/qwindowsvistastyle.cpp
+++ b/src/plugins/styles/windowsvista/qwindowsvistastyle.cpp
@@ -1365,6 +1365,7 @@ void QWindowsVistaStyle::drawControl(ControlElement element, const QStyleOption
QWindowsStyle::drawControl(element, &copyOpt, painter, widget);
}
break;
+#if QT_CONFIG(dockwidget)
case CE_DockWidgetTitle:
if (const QStyleOptionDockWidget *dwOpt = qstyleoption_cast<const QStyleOptionDockWidget *>(option)) {
const QDockWidget *dockWidget = qobject_cast<const QDockWidget *>(widget);
@@ -1431,6 +1432,7 @@ void QWindowsVistaStyle::drawControl(ControlElement element, const QStyleOption
}
}
break;
+#endif // QT_CONFIG(dockwidget)
#if QT_CONFIG(itemviews)
case CE_ItemViewItem:
{
@@ -2110,7 +2112,7 @@ int QWindowsVistaStyle::styleHint(StyleHint hint, const QStyleOption *option, co
break;
case SH_Table_GridLineColor:
if (option)
- ret = int(option->palette.color(QPalette::Base).darker(118).rgb());
+ ret = int(option->palette.color(QPalette::Base).darker(118).rgba());
else
ret = -1;
break;
@@ -2311,11 +2313,13 @@ void QWindowsVistaStyle::polish(QWidget *widget)
#endif // QT_CONFIG(lineedit)
if (qobject_cast<QGroupBox*>(widget))
widget->setAttribute(Qt::WA_Hover);
+#if QT_CONFIG(commandlinkbutton)
else if (qobject_cast<QCommandLinkButton*>(widget)) {
QFont buttonFont = widget->font();
buttonFont.setFamily(QLatin1String("Segoe UI"));
widget->setFont(buttonFont);
}
+#endif // QT_CONFIG(commandlinkbutton)
else if (widget->inherits("QTipLabel")){
//note that since tooltips are not reused
//we do not have to care about unpolishing
@@ -2392,12 +2396,15 @@ void QWindowsVistaStyle::unpolish(QWidget *widget)
#endif // QT_CONFIG(inputdialog)
else if (QTreeView *tree = qobject_cast<QTreeView *> (widget)) {
tree->viewport()->setAttribute(Qt::WA_Hover, false);
- } else if (qobject_cast<QCommandLinkButton*>(widget)) {
+ }
+#if QT_CONFIG(commandlinkbutton)
+ else if (qobject_cast<QCommandLinkButton*>(widget)) {
QFont font = QApplication::font("QCommandLinkButton");
QFont widgetFont = widget->font();
widgetFont.setFamily(font.family()); //Only family set by polish
widget->setFont(widgetFont);
}
+#endif // QT_CONFIG(commandlinkbutton)
}
diff --git a/src/plugins/styles/windowsvista/qwindowsvistastyle_p_p.h b/src/plugins/styles/windowsvista/qwindowsvistastyle_p_p.h
index 8fef9f9927..c1d764a60e 100644
--- a/src/plugins/styles/windowsvista/qwindowsvistastyle_p_p.h
+++ b/src/plugins/styles/windowsvista/qwindowsvistastyle_p_p.h
@@ -106,7 +106,9 @@
#include <qtableview.h>
#endif
#include <qdatetime.h>
+#if QT_CONFIG(commandlinkbutton)
#include <qcommandlinkbutton.h>
+#endif
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/styles/windowsvista/qwindowsxpstyle.cpp b/src/plugins/styles/windowsvista/qwindowsxpstyle.cpp
index bf80138b32..5d2e8efd68 100644
--- a/src/plugins/styles/windowsvista/qwindowsxpstyle.cpp
+++ b/src/plugins/styles/windowsvista/qwindowsxpstyle.cpp
@@ -3774,8 +3774,7 @@ int QWindowsXPStyle::styleHint(StyleHint hint, const QStyleOption *option, const
/*! \reimp */
QPalette QWindowsXPStyle::standardPalette() const
{
- return QWindowsXPStylePrivate::useXP() && QApplicationPrivate::sys_pal
- ? *QApplicationPrivate::sys_pal : QWindowsStyle::standardPalette();
+ return QWindowsXPStylePrivate::useXP() ? QPalette() : QWindowsStyle::standardPalette();
}
/*!
diff --git a/src/plugins/styles/windowsvista/windowsvista.pro b/src/plugins/styles/windowsvista/windowsvista.pro
index c08db7f533..483914c13d 100644
--- a/src/plugins/styles/windowsvista/windowsvista.pro
+++ b/src/plugins/styles/windowsvista/windowsvista.pro
@@ -11,9 +11,7 @@ HEADERS += qwindowsxpstyle_p.h qwindowsxpstyle_p_p.h
SOURCES += qwindowsxpstyle.cpp
QMAKE_USE_PRIVATE += user32 gdi32
-
-# DEFINES/LIBS needed for qwizard_win.cpp and the styles
-include(../../../widgets/kernel/win.pri)
+LIBS_PRIVATE *= -luxtheme
DISTFILES += windowsvistastyle.json