Repository navigation
LoAF initial spec - #122
Conversation
This includes part of the long animation frame spec: - Intro - Security & privacy - Some of the attributes It doesn't include yet: - Scripts - desiredRenderStart - firstUIEventTimestamp Note also that it exports a few algorithms to be called from the HTML spec.
yoavweiss
left a comment
There was a problem hiding this comment.
Thanks! A pile of nits :)
| readonly attribute DOMString name; | ||
| readonly attribute DOMString entryType; | ||
| readonly attribute DOMHighResTimeStamp startTime; | ||
| readonly attribute DOMHighResTimeStamp duration; |
There was a problem hiding this comment.
You don't need to redefine the attributes that are in PerformanceEntry
|
|
||
| The {{PerformanceLongAnimationFrameTiming/blockingDuration}} attribute's getter steps are: | ||
|
|
||
| 1. Let |workDuration| be [=this=]'s [=this=]'s [=PerformanceLongAnimationFrameTiming/timing info=]'s [=frame timing info/longest task duration=]. |
|
|
||
| 1. Let |workDuration| be [=this=]'s [=this=]'s [=PerformanceLongAnimationFrameTiming/timing info=]'s [=frame timing info/longest task duration=]. | ||
| 1. Let |renderDuration| be the 0. | ||
| 1. If [=this=]'s [=PerformanceLongAnimationFrameTiming/timing info=]'s [=frame timing info=/update the rendering start time=] is not zero, then: |
| :: A {{DOMHighResTimeStamp}}, initially 0. | ||
| </dl> | ||
|
|
||
| A {{Document}} has a null-or-[=frame timing info=] <dfn>current frame timing info</dfn>, initially null. |
There was a problem hiding this comment.
Can we just append a "null-or-" to random structs without defining the whole thing?
There was a problem hiding this comment.
It seems like your defining a new type named "null-or-frame timing info". But I see a similar pattern in Fetch, only without the "-". Maybe drop them?
| </div> | ||
|
|
||
| <div algorithm="Report task start time"> | ||
| To <dfn export>report task start time</dfn> given an {{DOMHighResTimeStamp}} |taskStartTime|, and a {{Document}} |document|: |
| 1. If |root|'s [=current frame timing info=] is null, | ||
| then set |root|'s [=current frame timing info=] to a new [=frame timing info=] whose [=frame timing info/start time=] is |taskStartTime|. | ||
|
|
||
| 1. Set |timingInfo|'s [=current frame timing info=]'s [=frame timing info/current task start time=] to |taskStartTime|. |
There was a problem hiding this comment.
What's |timingInfo| here?
| </div> | ||
|
|
||
| <div algorithm="Queue frame timing"> | ||
| To <dfn export>flush frame timing</dfn> given a {{Document}} |document| and a {{DOMHighResTimeStamp}} |endTime|: |
There was a problem hiding this comment.
Generally, it might be better to prefix all the unsafe timestamps with "unsafe" (or something similar), rather than prefixing the safe ones.
| :: A {{DOMHighResTimeStamp}}, initially 0. | ||
| </dl> | ||
|
|
||
| A {{Document}} has a null-or-[=frame timing info=] <dfn>current frame timing info</dfn>, initially null. |
There was a problem hiding this comment.
It seems like your defining a new type named "null-or-frame timing info". But I see a similar pattern in Fetch, only without the "-". Maybe drop them?
This includes part of the long animation frame spec:
It doesn't include yet:
Note also that it exports a few algorithms to be called from the HTML spec.
Preview | Diff