summaryrefslogtreecommitdiffstats
path: root/layout/style/nsStyleStruct.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'layout/style/nsStyleStruct.cpp')
-rw-r--r--layout/style/nsStyleStruct.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/layout/style/nsStyleStruct.cpp b/layout/style/nsStyleStruct.cpp
index d2d89a57d..acf287ea8 100644
--- a/layout/style/nsStyleStruct.cpp
+++ b/layout/style/nsStyleStruct.cpp
@@ -4024,6 +4024,7 @@ nsStyleUserInterface::nsStyleUserInterface(StyleStructContext aContext)
, mPointerEvents(NS_STYLE_POINTER_EVENTS_AUTO)
, mCursor(NS_STYLE_CURSOR_AUTO)
, mCaretColor(StyleComplexColor::Auto())
+ , mScrollbarWidth(StyleScrollbarWidth::Auto)
{
MOZ_COUNT_CTOR(nsStyleUserInterface);
}
@@ -4036,6 +4037,7 @@ nsStyleUserInterface::nsStyleUserInterface(const nsStyleUserInterface& aSource)
, mCursor(aSource.mCursor)
, mCursorImages(aSource.mCursorImages)
, mCaretColor(aSource.mCaretColor)
+ , mScrollbarWidth(aSource.mScrollbarWidth)
{
MOZ_COUNT_CTOR(nsStyleUserInterface);
}
@@ -4087,6 +4089,13 @@ nsStyleUserInterface::CalcDifference(const nsStyleUserInterface& aNewData) const
if (mCaretColor != aNewData.mCaretColor) {
hint |= nsChangeHint_RepaintFrame;
}
+
+ if (mScrollbarWidth != aNewData.mScrollbarWidth) {
+ // For scrollbar-width change, we need some special handling similar
+ // to overflow properties. Specifically, we may need to reconstruct
+ // the scrollbar or force reflow of the viewport scrollbar.
+ hint |= nsChangeHint_ScrollbarChange;
+ }
return hint;
}