animation: Accept ms as u32

Less boilerplate elsewhere.
This commit is contained in:
Ivan Molodetskikh
2024-02-07 16:32:38 +04:00
parent f9085db564
commit 753a90430a
6 changed files with 11 additions and 10 deletions
+1 -2
View File
@@ -114,8 +114,7 @@ impl<W: LayoutElement> Tile<W> {
}
pub fn start_open_animation(&mut self) {
self.open_animation =
Some(Animation::new(0., 1., Duration::from_millis(150)).with_curve(Curve::EaseOutExpo));
self.open_animation = Some(Animation::new(0., 1., 150).with_curve(Curve::EaseOutExpo));
}
pub fn window(&self) -> &W {