mirror of
https://github.com/servo/servo.git
synced 2025-07-22 14:53:49 +01:00
style: Add a new Timer structure to the shared style context, and basic infrastructure for controlling animations.
This commit is contained in:
parent
2e68821014
commit
0b67b218d0
20 changed files with 178 additions and 26 deletions
|
@ -1030,6 +1030,12 @@ impl Window {
|
|||
recv.recv().unwrap_or((Size2D::zero(), Point2D::zero()))
|
||||
}
|
||||
|
||||
/// Advances the layout animation clock by `delta` milliseconds, and then
|
||||
/// forces a reflow.
|
||||
pub fn advance_animation_clock(&self, delta: i32) {
|
||||
self.layout_chan.send(Msg::AdvanceClockMs(delta)).unwrap();
|
||||
}
|
||||
|
||||
/// Reflows the page unconditionally if possible and not suppressed. This
|
||||
/// method will wait for the layout thread to complete (but see the `TODO`
|
||||
/// below). If there is no window size yet, the page is presumed invisible
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue