Closed Bug 1231243 Opened 9 years ago Closed 9 years ago

CSS transform on element scaled larger than the viewport does not repaint when the transform is animated and the element is scaled down

Categories

(Core :: Layout, defect)

45 Branch
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla46
Tracking Status
firefox43 --- unaffected
firefox44 --- unaffected
firefox45 --- unaffected
firefox46 + fixed

People

(Reporter: metaeaux, Assigned: botond)

References

Details

Attachments

(2 files)

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:45.0) Gecko/20100101 Firefox/45.0 Build ID: 20151208030212 Steps to reproduce: Scale an element larger than the viewport down to fit within the viewport. Here's a video of the problem: https://vid.me/mAiha And a codepen: http://codepen.io/metaeaux/pen/vLEMBa The problem occurs when layers.offmainthreadcomposition.async-animations set to true. Some other notes: - Moving the mouse seems to trigger a paint of the element and the white borders disappear (as seen in the video) - When the viewport is around 1920px wide (or larger) the problem doesn't seem to occur Actual results: The edges that exceeded the viewport size are painted white rather than painted with the content of the element Expected results: The content of the element should be painted.
OS: Unspecified → Mac OS X
Hardware: Unspecified → x86_64
Summary: Element scaled larger than viewport is not are scaled down → CSS transform on element scaled larger than the viewport does not repaint when the transform is animated and the element is scaled down
It seems to be related to this issue: https://bugzilla.mozilla.org/show_bug.cgi?id=929362 It seems like a regression since the issue status is fixed.
Confirmed this behaviour in the latest nightly build
Status: UNCONFIRMED → NEW
Component: Untriaged → Layout
Ever confirmed: true
OS: Mac OS X → All
Product: Firefox → Core
Hardware: x86_64 → All
Interestingly, I see this on Linux but don't see this on Windows.
This is a regression from the nsDisplayBackgroundImage::GetBoundsInternal changes from bug 1166301.
Blocks: 1166301
I will investigate.
Assignee: nobody → botond
(In reply to Markus Stange [:mstange] from comment #4) > This is a regression from the nsDisplayBackgroundImage::GetBoundsInternal > changes from bug 1166301. Confirmed, backing out the change to nsDisplayBackgroundImage::GetBoundsInternal() fixes the problem. Nice call!
Note that, while this is a regression from bug 1166301, the issue only occurs with e10s and APZ enabled, so Firefox 45 and below are unaffected.
The problem here is that bug 1166301 changed nsDisplayBackgroundImage::GetBoundsInternal() to return the bounds of the viewport rather than the bounds of the image if APZ is enabled. The intention was to return a size *no smaller* than the viewport size; we also want to return a size no smaller than the bounds of the image, so to handle cases like this where the image is larger than the viewport, we should be taking the union.
Comment on attachment 8703832 [details] MozReview Request: Bug 1231243 - In nsDisplayBackgroundImage::GetBoundsInternal(), take the union of the image bounds and the viewport bounds if APZ is enabled. r=mstange https://reviewboard.mozilla.org/r/29481/#review26673
Attachment #8703832 - Flags: review?(mstange) → review+
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla46
Tracking for 46 since this is a regression - so if it reopens we'll notice it.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: