Bug 1539366 - Use a temporary object to compute the mPIStartBorderData coords so that we don't clobber the regular state. r=mats

Differential Revision: https://phabricator.services.mozilla.com/D26649

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Matt Woodrow 2019-05-27 20:38:26 +00:00
parent 6be2cd58d3
commit 65c3bca864

View File

@ -188,12 +188,15 @@ struct InlineBackgroundData {
mPIStartBorderData.SetCoord(joinedBorderArea.x);
}
} else if (mPIStartBorderData.mFrame) {
// Copy data to a temporary object so that computing the
// continous rect here doesn't clobber our normal state.
InlineBackgroundData temp = *this;
if (mVertical) {
mPIStartBorderData.SetCoord(
GetContinuousRect(mPIStartBorderData.mFrame).y);
temp.GetContinuousRect(mPIStartBorderData.mFrame).y);
} else {
mPIStartBorderData.SetCoord(
GetContinuousRect(mPIStartBorderData.mFrame).x);
temp.GetContinuousRect(mPIStartBorderData.mFrame).x);
}
}
} else {