summaryrefslogtreecommitdiffstats
path: root/src/widgets/styles
diff options
context:
space:
mode:
Diffstat (limited to 'src/widgets/styles')
-rw-r--r--src/widgets/styles/qstylesheetstyle.cpp18
-rw-r--r--src/widgets/styles/qstylesheetstyle_p.h8
2 files changed, 13 insertions, 13 deletions
diff --git a/src/widgets/styles/qstylesheetstyle.cpp b/src/widgets/styles/qstylesheetstyle.cpp
index b2b72fb6a8..2f38b72c21 100644
--- a/src/widgets/styles/qstylesheetstyle.cpp
+++ b/src/widgets/styles/qstylesheetstyle.cpp
@@ -2679,13 +2679,13 @@ void QStyleSheetStyle::setPalette(QWidget *w)
rule.configurePalette(&p, map[i].group, ew, ew != w);
}
- if (!useStyleSheetPropagationInWidgetStyles || p.resolve() != 0) {
+ if (!useStyleSheetPropagationInWidgetStyles || p.resolveMask() != 0) {
QPalette wp = w->palette();
- styleSheetCaches->customPaletteWidgets.insert(w, {wp, p.resolve()});
+ styleSheetCaches->customPaletteWidgets.insert(w, {wp, p.resolveMask()});
if (useStyleSheetPropagationInWidgetStyles) {
p = p.resolve(wp);
- p.resolve(p.resolve() | wp.resolve());
+ p.setResolveMask(p.resolveMask() | wp.resolveMask());
}
w->setPalette(p);
@@ -6109,18 +6109,18 @@ void QStyleSheetStyle::updateStyleSheetFont(QWidget* w) const
if (useStyleSheetPropagationInWidgetStyles) {
unsetStyleSheetFont(w);
- if (rule.font.resolve()) {
+ if (rule.font.resolveMask()) {
QFont wf = w->d_func()->localFont();
- styleSheetCaches->customFontWidgets.insert(w, {wf, rule.font.resolve()});
+ styleSheetCaches->customFontWidgets.insert(w, {wf, rule.font.resolveMask()});
QFont font = rule.font.resolve(wf);
- font.resolve(wf.resolve() | rule.font.resolve());
+ font.setResolveMask(wf.resolveMask() | rule.font.resolveMask());
w->setFont(font);
}
} else {
QFont wf = w->d_func()->localFont();
QFont font = rule.font.resolve(wf);
- font.resolve(wf.resolve() | rule.font.resolve());
+ font.setResolveMask(wf.resolveMask() | rule.font.resolveMask());
if ((!w->isWindow() || w->testAttribute(Qt::WA_WindowPropagation))
&& isNaturalChild(w) && qobject_cast<QWidget *>(w->parent())) {
@@ -6128,11 +6128,11 @@ void QStyleSheetStyle::updateStyleSheetFont(QWidget* w) const
font = font.resolve(static_cast<QWidget *>(w->parent())->font());
}
- if (wf.resolve() == font.resolve() && wf == font)
+ if (wf.resolveMask() == font.resolveMask() && wf == font)
return;
w->data->fnt = font;
- w->d_func()->directFontResolveMask = font.resolve();
+ w->d_func()->directFontResolveMask = font.resolveMask();
QEvent e(QEvent::FontChange);
QCoreApplication::sendEvent(w, &e);
diff --git a/src/widgets/styles/qstylesheetstyle_p.h b/src/widgets/styles/qstylesheetstyle_p.h
index 879ddec4d3..fa8a0955a7 100644
--- a/src/widgets/styles/qstylesheetstyle_p.h
+++ b/src/widgets/styles/qstylesheetstyle_p.h
@@ -194,7 +194,7 @@ public:
template <typename T>
struct Tampered {
T oldWidgetValue;
- decltype(std::declval<T>().resolve()) resolveMask;
+ decltype(std::declval<T>().resolveMask()) resolveMask;
// only call this function on an rvalue *this (it mangles oldWidgetValue)
T reverted(T current)
@@ -202,10 +202,10 @@ public:
&&
#endif
{
- oldWidgetValue.resolve(oldWidgetValue.resolve() & resolveMask);
- current.resolve(current.resolve() & ~resolveMask);
+ oldWidgetValue.setResolveMask(oldWidgetValue.resolveMask() & resolveMask);
+ current.setResolveMask(current.resolveMask() & ~resolveMask);
current.resolve(oldWidgetValue);
- current.resolve(current.resolve() | oldWidgetValue.resolve());
+ current.setResolveMask(current.resolveMask() | oldWidgetValue.resolveMask());
return current;
}
};