mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
f81615613a
Earlier in this patch series we added AnimationPlayer::StartOnNextTick which takes a ready time parameter expressed in timeline time. In order to call this method when painting finishes we need to convert the TimeStamp recorded when painting finished to a timeline time. However, when the timeline is driven by a refresh driver under test control we can no longer meaningfully do this conversion since there is no correspondence between the notion of time used to record the time when painting finished (wallclock time) and the notion of time used by the timeline (which has been arbitrarily adjusted by test code). We need a way to detect this situation so that we know not to call ToTimelineTime in that case. Alternatively, we could make ToTimelineTime automatically return a null value when its refresh driver is under test control. However, in this situation ToTimelineTime can still actually be used to convert a TimeStamp to a timeline time as long as the TimeStamp is from the same refresh driver. Indeed, GetCurrentTime does exactly that. So if we were to go down that route we would have to provide a way for GetCurrentTime to work around that restriction. For now, this patch puts the onus on the caller of ToTimelineTime to check if the timeline is under test control first (unless they are passing a TimeStamp from the same refresh driver, in which case there is no need to check). |
||
---|---|---|
.. | ||
test | ||
Animation.cpp | ||
Animation.h | ||
AnimationEffect.cpp | ||
AnimationEffect.h | ||
AnimationPlayer.cpp | ||
AnimationPlayer.h | ||
AnimationTimeline.cpp | ||
AnimationTimeline.h | ||
AnimationUtils.h | ||
moz.build | ||
PendingPlayerTracker.cpp | ||
PendingPlayerTracker.h |