Closed
Bug 1135764
Opened 10 years ago
Closed 10 years ago
CSS transitions not working Firefox for XML document transformed to HTML with XSLT
Categories
(Core :: CSS Parsing and Computation, defect)
Tracking
()
RESOLVED
FIXED
mozilla39
People
(Reporter: kim.betti, Assigned: bzbarsky)
References
Details
(Keywords: regression)
Attachments
(5 files)
1.29 KB,
application/zip
|
Details | |
399 bytes,
text/html
|
Details | |
677 bytes,
application/xml
|
Details | |
116 bytes,
application/xml
|
Details | |
4.19 KB,
patch
|
smaug
:
review+
lmandel
:
approval-mozilla-aurora+
lmandel
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
User Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2125.111 Safari/537.36
Steps to reproduce:
Tried to use css transitions in a html document transformed from xml using xslt.
1. Open the attached 'data.xml' and hover the box with your mouse
2. Notice that the box rotates without any animation being applied
3. Open 'data.html' (html document copied from the transformed xml document)
4. Hover the box and notice that the box rotates evenly as expected.
http://stackoverflow.com/questions/28676926/css-transitions-not-working-firefox-for-xml-document-transformed-to-html-with-xs
Actual results:
It did not work, but copying out the generated html from Firefox developer tools and pasting it into a plain .html document did.
Expected results:
I expected css transitions to work in html transformed from xml.
Comment 1•10 years ago
|
||
Comment 2•10 years ago
|
||
Comment 3•10 years ago
|
||
Updated•10 years ago
|
Attachment #8568458 -
Attachment mime type: text/plain → application/xml
Comment 4•10 years ago
|
||
I can confirm the problem with Firefox 35 on Windows 8.1
Status: UNCONFIRMED → NEW
Component: Untriaged → CSS Parsing and Computation
Ever confirmed: true
OS: Linux → All
Product: Firefox → Core
Comment 5•10 years ago
|
||
I have now tried to reproduce the problem with a nightly 39.0a1, there it is even worse, the div is not rotated at all when I hover over the red div block in the document generated by XSLT (test case https://bug1135764.bugzilla.mozilla.org/attachment.cgi?id=8568458). The static HTML test case continues to work fine.
![]() |
Assignee | |
Comment 6•10 years ago
|
||
It's worth figuring out the regression range for when the :hover style stopped applying. Chances are, it's the same issue..
Keywords: regressionwindow-wanted
![]() |
||
Comment 7•10 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=7877a00d7025&tochange=95267af607c3
Regressed by: Bug 1112480
Blocks: 1112480
Flags: needinfo?(bbirtles)
![]() |
||
Updated•10 years ago
|
status-firefox36:
--- → unaffected
status-firefox37:
--- → affected
status-firefox38:
--- → affected
status-firefox39:
--- → affected
tracking-firefox37:
--- → ?
tracking-firefox38:
--- → ?
tracking-firefox39:
--- → ?
Comment 8•10 years ago
|
||
I'm afraid I'm on PTO then travelling so I might not be able to look into this for another two weeks.
![]() |
||
Comment 9•10 years ago
|
||
via local build
Last good: 003c367a510f
First bad: d99b6fd9ca56
triggered by:
d99b6fd9ca56 Brian Birtles — Bug 1112480 part 6 - Make PendingPlayerTracker call StartOnNextTick; r=jwatt
Comment 10•10 years ago
|
||
jwatt, is there someone else who can work on this while Brian is out of town?
And, should we (or can we) back this out for 37 while trying to fix it for 38 and 39?
Flags: needinfo?(jwatt)
Keywords: regression
Comment 11•10 years ago
|
||
Martin, if you tested this in Firefox 35, and it was broken there, I wonder if it's also broken in 36. Would you mind trying that out? Or, did you really mean to say it's broken in 35? Thanks for the help and the test cases!
Flags: needinfo?(martin.honnen)
Comment 12•10 years ago
|
||
I'll try to have a look sometime next week. jwatt, I can see we're successfully creating the AnimationPlayer but it remains pending. So perhaps we're registering the pending animation against the wrong document, or perhaps nsTransitionManager is not registered against the refresh driver for the right document--in any case, we're not getting to the point where we kick start the animation.
Comment 13•10 years ago
|
||
(In reply to Liz Henry :lizzard from comment #11)
> Martin, if you tested this in Firefox 35, and it was broken there, I wonder
> if it's also broken in 36. Would you mind trying that out? Or, did you
> really mean to say it's broken in 35? Thanks for the help and the test
> cases!
I have now upgraded to Firefox 36 and see the same problem with the test case https://bug1135764.bugzilla.mozilla.org/attachment.cgi?id=8568458 as in Firefox 35, when I hover over the red box it is rotated, but the rotation is not animated, there is no transition happening.
Flags: needinfo?(martin.honnen)
![]() |
||
Comment 14•10 years ago
|
||
(In reply to Martin Honnen from comment #13)
> (In reply to Liz Henry :lizzard from comment #11)
> > Martin, if you tested this in Firefox 35, and it was broken there, I wonder
> > if it's also broken in 36. Would you mind trying that out? Or, did you
> > really mean to say it's broken in 35? Thanks for the help and the test
> > cases!
>
> I have now upgraded to Firefox 36 and see the same problem with the test
> case https://bug1135764.bugzilla.mozilla.org/attachment.cgi?id=8568458 as in
> Firefox 35, when I hover over the red box it is rotated, but the rotation is
> not animated, there is no transition happening.
Regression window about the animation
https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=810b3536cb50&tochange=0f4b90123dba
Regressed by: Bug 1002332
Blocks: 1002332
![]() |
||
Updated•10 years ago
|
Comment 15•10 years ago
|
||
After reading the comments above properly, I think the issue is basically that in this case we're applying the styles to a resource document. I suspect resource documents probably won't have a navigationStart time hence document.timeline.currentTime will always return 0 (as of bug 1002332). As a result there will be no animation.
I'm not sure exactly why we would complete the transition before bug 1112480 landed, but in any case, if we fix the lack of animation, that should be enough.
I don't think we need to back anything out here since this bug has been around for a long time and no-one has noticed until now (and we'd have to back out a *lot*).
Ideally we need to get the timeline from the presentation document and use its timeline in this case. We already have AnimationPlayer::GetRenderedDocument but I've yet to check if that's the correct document for this.
We should also write a test for this to ensure browsers behave consistently here.
![]() |
Assignee | |
Comment 16•10 years ago
|
||
> I think the issue is basically that in this case we're applying the styles to a resource
> document
No, the styles apply to the post-transform document, which is not a resource document.
> I suspect resource documents probably won't have a navigationStart time
This document has a navigationStart time. You can see it by just loading it and doing performance.timing.navigationStart in the console.
> hence document.timeline.currentTime will always return 0
Ah, here we go. So the _window_ has the right performance.timing. But calling mDocument->GetNavigationTiming() in AnimationTimeline::ToTimelineTime returns null.
This we do have. document.timeline.currenTime is returning null for me in a slightly-old nightly.
![]() |
Assignee | |
Comment 17•10 years ago
|
||
This makes the transition happen for me. The test tests document.timeline, but if someone wants to add a test for transition stuff directly, so much the better.
Attachment #8571355 -
Flags: review?(bugs)
![]() |
Assignee | |
Updated•10 years ago
|
Assignee: nobody → bzbarsky
Status: NEW → ASSIGNED
Updated•10 years ago
|
Attachment #8571355 -
Flags: review?(bugs) → review+
![]() |
Assignee | |
Updated•10 years ago
|
![]() |
Assignee | |
Comment 18•10 years ago
|
||
![]() |
Assignee | |
Comment 19•10 years ago
|
||
Comment on attachment 8571355 [details] [diff] [review]
Make sure XSLT transform results have a document timeline so things like transitions will work
Approval Request Comment
[Feature/regressing bug #]: Bug 1112480
[User impact if declined]: Transitions on web pages produced via XSLT
transformations are broken.
[Describe test coverage new/current, TreeHerder]: Test coverage is a bit spotty,
though this patch adds some tests.
[Risks and why]: I think this is very low risk.
[String/UUID change made/needed]: None.
Attachment #8571355 -
Flags: approval-mozilla-beta?
Attachment #8571355 -
Flags: approval-mozilla-aurora?
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
Comment 21•10 years ago
|
||
(In reply to Not doing reviews right now from comment #19)
> [Feature/regressing bug #]: Bug 1112480
Bug 1112480 landed in 37. 36 is marked as affected. Is that correct?
Flags: needinfo?(bzbarsky)
Comment 22•10 years ago
|
||
Comment on attachment 8571355 [details] [diff] [review]
Make sure XSLT transform results have a document timeline so things like transitions will work
Given that bz thinks this is very low risk and this has already landed on m-c, let's get this fix into Beta 3. Beta+ Aurora+
Attachment #8571355 -
Flags: approval-mozilla-beta?
Attachment #8571355 -
Flags: approval-mozilla-beta+
Attachment #8571355 -
Flags: approval-mozilla-aurora?
Attachment #8571355 -
Flags: approval-mozilla-aurora+
![]() |
Assignee | |
Comment 23•10 years ago
|
||
> Is that correct?
Yes. In 36, the new transform does take effect, but there is no transition. That's what this bug report was about originally.
In 37, the new transform doesn't take effect at all. That was caused by bug 1112480.
The patch fixes both problems, as it happens, but for approval purposes for beta the relevant thing is the regression from bug 1112480, imo.
Flags: needinfo?(bzbarsky)
Comment 24•10 years ago
|
||
Flags: in-testsuite+
Comment 25•10 years ago
|
||
You need to log in
before you can comment on or make changes to this bug.
Description
•