mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-10-24 16:17:29 +09:00
No issue - Refactor nsStyleUIReset::CalcDifference to accumulate change hints
This was patched in m-c via an unrelated bug (bug 1370034). Noted by dbaron in this comment: https://bugzilla.mozilla.org/show_bug.cgi?id=1370034#c69
This commit is contained in:
parent
3ba0b10bb4
commit
2c704d1b8e
1 changed files with 10 additions and 6 deletions
|
|
@ -4025,32 +4025,36 @@ nsStyleUIReset::~nsStyleUIReset()
|
||||||
nsChangeHint
|
nsChangeHint
|
||||||
nsStyleUIReset::CalcDifference(const nsStyleUIReset& aNewData) const
|
nsStyleUIReset::CalcDifference(const nsStyleUIReset& aNewData) const
|
||||||
{
|
{
|
||||||
|
nsChangeHint hint = nsChangeHint(0);
|
||||||
|
|
||||||
// ignore mIMEMode
|
// ignore mIMEMode
|
||||||
if (mForceBrokenImageIcon != aNewData.mForceBrokenImageIcon) {
|
if (mForceBrokenImageIcon != aNewData.mForceBrokenImageIcon) {
|
||||||
return nsChangeHint_ReconstructFrame;
|
hint |= nsChangeHint_ReconstructFrame;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mWindowShadow != aNewData.mWindowShadow) {
|
if (mWindowShadow != aNewData.mWindowShadow) {
|
||||||
// We really need just an nsChangeHint_SyncFrameView, except
|
// We really need just an nsChangeHint_SyncFrameView, except
|
||||||
// on an ancestor of the frame, so we get that by doing a
|
// on an ancestor of the frame, so we get that by doing a
|
||||||
// reflow.
|
// reflow.
|
||||||
return NS_STYLE_HINT_REFLOW;
|
hint |= NS_STYLE_HINT_REFLOW;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mUserSelect != aNewData.mUserSelect) {
|
if (mUserSelect != aNewData.mUserSelect) {
|
||||||
return NS_STYLE_HINT_VISUAL;
|
hint |= NS_STYLE_HINT_VISUAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mWindowDragging != aNewData.mWindowDragging) {
|
if (mWindowDragging != aNewData.mWindowDragging) {
|
||||||
return nsChangeHint_SchedulePaint;
|
hint |= nsChangeHint_SchedulePaint;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mScrollbarWidth != aNewData.mScrollbarWidth) {
|
if (mScrollbarWidth != aNewData.mScrollbarWidth) {
|
||||||
// For scrollbar-width change, we need some special handling similar
|
// For scrollbar-width change, we need some special handling similar
|
||||||
// to overflow properties. Specifically, we may need to reconstruct
|
// to overflow properties. Specifically, we may need to reconstruct
|
||||||
// the scrollbar or force reflow of the viewport scrollbar.
|
// the scrollbar or force reflow of the viewport scrollbar.
|
||||||
return nsChangeHint_ScrollbarChange;
|
hint |= nsChangeHint_ScrollbarChange;
|
||||||
}
|
}
|
||||||
|
|
||||||
return nsChangeHint(0);
|
return hint;
|
||||||
}
|
}
|
||||||
|
|
||||||
//-----------------------
|
//-----------------------
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue