web_sys/features/
gen_HtmlTrackElement.rs1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7 # [wasm_bindgen (extends = HtmlElement , extends = Element , extends = Node , extends = EventTarget , extends = :: js_sys :: Object , js_name = HTMLTrackElement , typescript_type = "HTMLTrackElement")]
8 #[derive(Debug, Clone, PartialEq, Eq)]
9 #[doc = "The `HtmlTrackElement` class."]
10 #[doc = ""]
11 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement)"]
12 #[doc = ""]
13 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
14 pub type HtmlTrackElement;
15 # [wasm_bindgen (structural , method , getter , js_class = "HTMLTrackElement" , js_name = kind)]
16 #[doc = "Getter for the `kind` field of this object."]
17 #[doc = ""]
18 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/kind)"]
19 #[doc = ""]
20 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
21 pub fn kind(this: &HtmlTrackElement) -> ::alloc::string::String;
22 # [wasm_bindgen (structural , method , setter , js_class = "HTMLTrackElement" , js_name = kind)]
23 #[doc = "Setter for the `kind` field of this object."]
24 #[doc = ""]
25 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/kind)"]
26 #[doc = ""]
27 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
28 pub fn set_kind(this: &HtmlTrackElement, value: &str);
29 # [wasm_bindgen (structural , method , getter , js_class = "HTMLTrackElement" , js_name = src)]
30 #[doc = "Getter for the `src` field of this object."]
31 #[doc = ""]
32 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/src)"]
33 #[doc = ""]
34 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
35 pub fn src(this: &HtmlTrackElement) -> ::alloc::string::String;
36 # [wasm_bindgen (structural , method , setter , js_class = "HTMLTrackElement" , js_name = src)]
37 #[doc = "Setter for the `src` field of this object."]
38 #[doc = ""]
39 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/src)"]
40 #[doc = ""]
41 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
42 pub fn set_src(this: &HtmlTrackElement, value: &str);
43 # [wasm_bindgen (structural , method , getter , js_class = "HTMLTrackElement" , js_name = srclang)]
44 #[doc = "Getter for the `srclang` field of this object."]
45 #[doc = ""]
46 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/srclang)"]
47 #[doc = ""]
48 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
49 pub fn srclang(this: &HtmlTrackElement) -> ::alloc::string::String;
50 # [wasm_bindgen (structural , method , setter , js_class = "HTMLTrackElement" , js_name = srclang)]
51 #[doc = "Setter for the `srclang` field of this object."]
52 #[doc = ""]
53 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/srclang)"]
54 #[doc = ""]
55 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
56 pub fn set_srclang(this: &HtmlTrackElement, value: &str);
57 # [wasm_bindgen (structural , method , getter , js_class = "HTMLTrackElement" , js_name = label)]
58 #[doc = "Getter for the `label` field of this object."]
59 #[doc = ""]
60 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/label)"]
61 #[doc = ""]
62 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
63 pub fn label(this: &HtmlTrackElement) -> ::alloc::string::String;
64 # [wasm_bindgen (structural , method , setter , js_class = "HTMLTrackElement" , js_name = label)]
65 #[doc = "Setter for the `label` field of this object."]
66 #[doc = ""]
67 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/label)"]
68 #[doc = ""]
69 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
70 pub fn set_label(this: &HtmlTrackElement, value: &str);
71 # [wasm_bindgen (structural , method , getter , js_class = "HTMLTrackElement" , js_name = default)]
72 #[doc = "Getter for the `default` field of this object."]
73 #[doc = ""]
74 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/default)"]
75 #[doc = ""]
76 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
77 pub fn default(this: &HtmlTrackElement) -> bool;
78 # [wasm_bindgen (structural , method , setter , js_class = "HTMLTrackElement" , js_name = default)]
79 #[doc = "Setter for the `default` field of this object."]
80 #[doc = ""]
81 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/default)"]
82 #[doc = ""]
83 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
84 pub fn set_default(this: &HtmlTrackElement, value: bool);
85 # [wasm_bindgen (structural , method , getter , js_class = "HTMLTrackElement" , js_name = readyState)]
86 #[doc = "Getter for the `readyState` field of this object."]
87 #[doc = ""]
88 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/readyState)"]
89 #[doc = ""]
90 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
91 pub fn ready_state(this: &HtmlTrackElement) -> u16;
92 #[cfg(feature = "TextTrack")]
93 # [wasm_bindgen (structural , method , getter , js_class = "HTMLTrackElement" , js_name = track)]
94 #[doc = "Getter for the `track` field of this object."]
95 #[doc = ""]
96 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement/track)"]
97 #[doc = ""]
98 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`, `TextTrack`*"]
99 pub fn track(this: &HtmlTrackElement) -> Option<TextTrack>;
100}
101impl HtmlTrackElement {
102 #[doc = "The `HTMLTrackElement.NONE` const."]
103 #[doc = ""]
104 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
105 pub const NONE: u16 = 0i64 as u16;
106 #[doc = "The `HTMLTrackElement.LOADING` const."]
107 #[doc = ""]
108 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
109 pub const LOADING: u16 = 1u64 as u16;
110 #[doc = "The `HTMLTrackElement.LOADED` const."]
111 #[doc = ""]
112 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
113 pub const LOADED: u16 = 2u64 as u16;
114 #[doc = "The `HTMLTrackElement.ERROR` const."]
115 #[doc = ""]
116 #[doc = "*This API requires the following crate features to be activated: `HtmlTrackElement`*"]
117 pub const ERROR: u16 = 3u64 as u16;
118}