diff options
Diffstat (limited to 'src/animation/mod.rs')
| -rw-r--r-- | src/animation/mod.rs | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/animation/mod.rs b/src/animation/mod.rs index b6d6b552..b2f26b32 100644 --- a/src/animation/mod.rs +++ b/src/animation/mod.rs @@ -295,11 +295,22 @@ impl Animation { self.to } - #[cfg(test)] pub fn from(&self) -> f64 { self.from } + pub fn start_time(&self) -> Duration { + self.start_time + } + + pub fn end_time(&self) -> Duration { + self.start_time + self.duration + } + + pub fn duration(&self) -> Duration { + self.duration + } + pub fn offset(&mut self, offset: f64) { self.from += offset; self.to += offset; |
