web_sys/features/
gen_EffectTiming.rs1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7 # [wasm_bindgen (extends = :: js_sys :: Object , js_name = EffectTiming)]
8 #[derive(Debug, Clone, PartialEq, Eq)]
9 #[doc = "The `EffectTiming` dictionary."]
10 #[doc = ""]
11 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
12 pub type EffectTiming;
13 #[doc = "Get the `delay` field of this object."]
14 #[doc = ""]
15 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
16 #[wasm_bindgen(method, getter = "delay")]
17 pub fn get_delay(this: &EffectTiming) -> Option<f64>;
18 #[doc = "Change the `delay` field of this object."]
19 #[doc = ""]
20 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
21 #[wasm_bindgen(method, setter = "delay")]
22 pub fn set_delay(this: &EffectTiming, val: f64);
23 #[cfg(feature = "PlaybackDirection")]
24 #[doc = "Get the `direction` field of this object."]
25 #[doc = ""]
26 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`, `PlaybackDirection`*"]
27 #[wasm_bindgen(method, getter = "direction")]
28 pub fn get_direction(this: &EffectTiming) -> Option<PlaybackDirection>;
29 #[cfg(feature = "PlaybackDirection")]
30 #[doc = "Change the `direction` field of this object."]
31 #[doc = ""]
32 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`, `PlaybackDirection`*"]
33 #[wasm_bindgen(method, setter = "direction")]
34 pub fn set_direction(this: &EffectTiming, val: PlaybackDirection);
35 #[doc = "Get the `duration` field of this object."]
36 #[doc = ""]
37 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
38 #[wasm_bindgen(method, getter = "duration")]
39 pub fn get_duration(this: &EffectTiming) -> ::wasm_bindgen::JsValue;
40 #[doc = "Change the `duration` field of this object."]
41 #[doc = ""]
42 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
43 #[wasm_bindgen(method, setter = "duration")]
44 pub fn set_duration(this: &EffectTiming, val: &::wasm_bindgen::JsValue);
45 #[doc = "Change the `duration` field of this object."]
46 #[doc = ""]
47 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
48 #[wasm_bindgen(method, setter = "duration")]
49 pub fn set_duration_f64(this: &EffectTiming, val: f64);
50 #[doc = "Change the `duration` field of this object."]
51 #[doc = ""]
52 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
53 #[wasm_bindgen(method, setter = "duration")]
54 pub fn set_duration_str(this: &EffectTiming, val: &str);
55 #[doc = "Get the `easing` field of this object."]
56 #[doc = ""]
57 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
58 #[wasm_bindgen(method, getter = "easing")]
59 pub fn get_easing(this: &EffectTiming) -> Option<::alloc::string::String>;
60 #[doc = "Change the `easing` field of this object."]
61 #[doc = ""]
62 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
63 #[wasm_bindgen(method, setter = "easing")]
64 pub fn set_easing(this: &EffectTiming, val: &str);
65 #[doc = "Get the `endDelay` field of this object."]
66 #[doc = ""]
67 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
68 #[wasm_bindgen(method, getter = "endDelay")]
69 pub fn get_end_delay(this: &EffectTiming) -> Option<f64>;
70 #[doc = "Change the `endDelay` field of this object."]
71 #[doc = ""]
72 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
73 #[wasm_bindgen(method, setter = "endDelay")]
74 pub fn set_end_delay(this: &EffectTiming, val: f64);
75 #[cfg(feature = "FillMode")]
76 #[doc = "Get the `fill` field of this object."]
77 #[doc = ""]
78 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`, `FillMode`*"]
79 #[wasm_bindgen(method, getter = "fill")]
80 pub fn get_fill(this: &EffectTiming) -> Option<FillMode>;
81 #[cfg(feature = "FillMode")]
82 #[doc = "Change the `fill` field of this object."]
83 #[doc = ""]
84 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`, `FillMode`*"]
85 #[wasm_bindgen(method, setter = "fill")]
86 pub fn set_fill(this: &EffectTiming, val: FillMode);
87 #[doc = "Get the `iterationStart` field of this object."]
88 #[doc = ""]
89 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
90 #[wasm_bindgen(method, getter = "iterationStart")]
91 pub fn get_iteration_start(this: &EffectTiming) -> Option<f64>;
92 #[doc = "Change the `iterationStart` field of this object."]
93 #[doc = ""]
94 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
95 #[wasm_bindgen(method, setter = "iterationStart")]
96 pub fn set_iteration_start(this: &EffectTiming, val: f64);
97 #[doc = "Get the `iterations` field of this object."]
98 #[doc = ""]
99 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
100 #[wasm_bindgen(method, getter = "iterations")]
101 pub fn get_iterations(this: &EffectTiming) -> Option<f64>;
102 #[doc = "Change the `iterations` field of this object."]
103 #[doc = ""]
104 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
105 #[wasm_bindgen(method, setter = "iterations")]
106 pub fn set_iterations(this: &EffectTiming, val: f64);
107}
108impl EffectTiming {
109 #[doc = "Construct a new `EffectTiming`."]
110 #[doc = ""]
111 #[doc = "*This API requires the following crate features to be activated: `EffectTiming`*"]
112 pub fn new() -> Self {
113 #[allow(unused_mut)]
114 let mut ret: Self = ::wasm_bindgen::JsCast::unchecked_into(::js_sys::Object::new());
115 ret
116 }
117 #[deprecated = "Use `set_delay()` instead."]
118 pub fn delay(&mut self, val: f64) -> &mut Self {
119 self.set_delay(val);
120 self
121 }
122 #[cfg(feature = "PlaybackDirection")]
123 #[deprecated = "Use `set_direction()` instead."]
124 pub fn direction(&mut self, val: PlaybackDirection) -> &mut Self {
125 self.set_direction(val);
126 self
127 }
128 #[deprecated = "Use `set_duration()` instead."]
129 pub fn duration(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
130 self.set_duration(val);
131 self
132 }
133 #[deprecated = "Use `set_easing()` instead."]
134 pub fn easing(&mut self, val: &str) -> &mut Self {
135 self.set_easing(val);
136 self
137 }
138 #[deprecated = "Use `set_end_delay()` instead."]
139 pub fn end_delay(&mut self, val: f64) -> &mut Self {
140 self.set_end_delay(val);
141 self
142 }
143 #[cfg(feature = "FillMode")]
144 #[deprecated = "Use `set_fill()` instead."]
145 pub fn fill(&mut self, val: FillMode) -> &mut Self {
146 self.set_fill(val);
147 self
148 }
149 #[deprecated = "Use `set_iteration_start()` instead."]
150 pub fn iteration_start(&mut self, val: f64) -> &mut Self {
151 self.set_iteration_start(val);
152 self
153 }
154 #[deprecated = "Use `set_iterations()` instead."]
155 pub fn iterations(&mut self, val: f64) -> &mut Self {
156 self.set_iterations(val);
157 self
158 }
159}
160impl Default for EffectTiming {
161 fn default() -> Self {
162 Self::new()
163 }
164}