зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1396474: When aSetTransform is false, do not rely on the current DT transform when returning the output transform. r=mattwoodrow
MozReview-Commit-ID: 8DbS6dzFVtp
This commit is contained in:
Родитель
0cbd965dd6
Коммит
41a643c958
|
@ -302,18 +302,16 @@ RotatedContentBuffer::BorrowDrawTargetForQuadrantUpdate(const IntRect& aBounds,
|
|||
IntRect quadrantRect = GetQuadrantRectangle(sideX, sideY);
|
||||
NS_ASSERTION(quadrantRect.Contains(bounds), "Messed up quadrants");
|
||||
|
||||
mLoanedTransform = mLoanedDrawTarget->GetTransform();
|
||||
|
||||
Matrix transform = Matrix(mLoanedTransform)
|
||||
.PreTranslate(-quadrantRect.x,
|
||||
-quadrantRect.y);
|
||||
|
||||
if (aSetTransform) {
|
||||
mLoanedTransform = mLoanedDrawTarget->GetTransform();
|
||||
Matrix transform = Matrix(mLoanedTransform)
|
||||
.PreTranslate(-quadrantRect.x,
|
||||
-quadrantRect.y);
|
||||
mLoanedDrawTarget->SetTransform(transform);
|
||||
mSetTransform = true;
|
||||
} else {
|
||||
MOZ_ASSERT(aOutMatrix);
|
||||
*aOutMatrix = transform;
|
||||
*aOutMatrix = Matrix::Translation(-quadrantRect.x, -quadrantRect.y);
|
||||
mSetTransform = false;
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче