Closed Bug 1799564 Opened 2 years ago Closed 2 years ago

[wpt-sync] Sync PR 36860 - DOMMatrix.inverse() should not generate invalid 2D matrix

Categories

(Core :: DOM: CSS Object Model, task, P4)

task

Tracking

()

RESOLVED FIXED
108 Branch
Tracking Status
firefox108 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 36860 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/36860
Details from upstream follow.

Xianzhu Wang <wangxianzhu@chromium.org> wrote:

DOMMatrix.inverse() should not generate invalid 2D matrix

The bug was introduced in crrev.com/c/1045489 in which we removed the
if (is_2d_) block from DOMMatrix::invertSelf().
TransformationMatrix::GetInverse() may change a 2D matrix into non-2D
due to floating point errors, while DOMMtraix.is2D is still true.

We should let gfx::Transform::GetInverse() preserve 2D status to fix
the root cause, but this CL just revert DOMMatrix::invertSelf()
because we need to merge this fix into M108.

Bug: 1379529
Change-Id: If3e280e34d1a66d2dd1b7f08bed3e6ef9b044d2a
Reviewed-on: https://chromium-review.googlesource.com/4010919
WPT-Export-Revision: 168f1a7a779b1486e79294427e37009bc72662ab

Component: web-platform-tests → DOM: CSS Object Model
Product: Testing → Core

CI Results

Ran 0 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 1 tests and 2 subtests

Status Summary

Firefox

OK : 1
PASS: 2

Chrome

OK : 1
FAIL: 2

Safari

OK : 1
PASS: 2

Links

GitHub PR Head
GitHub PR Base

Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/68cd11f58d02 [wpt PR 36860] - DOMMatrix.inverse() should not generate invalid 2D matrix, a=testonly
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 108 Branch
You need to log in before you can comment on or make changes to this bug.