web_sys/features/
gen_Touch.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 = Touch , typescript_type = "Touch")]
8 #[derive(Debug, Clone, PartialEq, Eq)]
9 #[doc = "The `Touch` class."]
10 #[doc = ""]
11 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch)"]
12 #[doc = ""]
13 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
14 pub type Touch;
15 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = identifier)]
16 #[doc = "Getter for the `identifier` field of this object."]
17 #[doc = ""]
18 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/identifier)"]
19 #[doc = ""]
20 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
21 pub fn identifier(this: &Touch) -> i32;
22 #[cfg(feature = "EventTarget")]
23 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = target)]
24 #[doc = "Getter for the `target` field of this object."]
25 #[doc = ""]
26 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/target)"]
27 #[doc = ""]
28 #[doc = "*This API requires the following crate features to be activated: `EventTarget`, `Touch`*"]
29 pub fn target(this: &Touch) -> Option<EventTarget>;
30 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = screenX)]
31 #[doc = "Getter for the `screenX` field of this object."]
32 #[doc = ""]
33 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/screenX)"]
34 #[doc = ""]
35 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
36 pub fn screen_x(this: &Touch) -> i32;
37 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = screenY)]
38 #[doc = "Getter for the `screenY` field of this object."]
39 #[doc = ""]
40 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/screenY)"]
41 #[doc = ""]
42 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
43 pub fn screen_y(this: &Touch) -> i32;
44 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = clientX)]
45 #[doc = "Getter for the `clientX` field of this object."]
46 #[doc = ""]
47 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/clientX)"]
48 #[doc = ""]
49 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
50 pub fn client_x(this: &Touch) -> i32;
51 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = clientY)]
52 #[doc = "Getter for the `clientY` field of this object."]
53 #[doc = ""]
54 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/clientY)"]
55 #[doc = ""]
56 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
57 pub fn client_y(this: &Touch) -> i32;
58 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = pageX)]
59 #[doc = "Getter for the `pageX` field of this object."]
60 #[doc = ""]
61 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/pageX)"]
62 #[doc = ""]
63 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
64 pub fn page_x(this: &Touch) -> i32;
65 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = pageY)]
66 #[doc = "Getter for the `pageY` field of this object."]
67 #[doc = ""]
68 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/pageY)"]
69 #[doc = ""]
70 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
71 pub fn page_y(this: &Touch) -> i32;
72 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = radiusX)]
73 #[doc = "Getter for the `radiusX` field of this object."]
74 #[doc = ""]
75 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/radiusX)"]
76 #[doc = ""]
77 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
78 pub fn radius_x(this: &Touch) -> i32;
79 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = radiusY)]
80 #[doc = "Getter for the `radiusY` field of this object."]
81 #[doc = ""]
82 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/radiusY)"]
83 #[doc = ""]
84 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
85 pub fn radius_y(this: &Touch) -> i32;
86 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = rotationAngle)]
87 #[doc = "Getter for the `rotationAngle` field of this object."]
88 #[doc = ""]
89 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/rotationAngle)"]
90 #[doc = ""]
91 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
92 pub fn rotation_angle(this: &Touch) -> f32;
93 # [wasm_bindgen (structural , method , getter , js_class = "Touch" , js_name = force)]
94 #[doc = "Getter for the `force` field of this object."]
95 #[doc = ""]
96 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/force)"]
97 #[doc = ""]
98 #[doc = "*This API requires the following crate features to be activated: `Touch`*"]
99 pub fn force(this: &Touch) -> f32;
100 #[cfg(feature = "TouchInit")]
101 #[wasm_bindgen(catch, constructor, js_class = "Touch")]
102 #[doc = "The `new Touch(..)` constructor, creating a new instance of `Touch`."]
103 #[doc = ""]
104 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/Touch/Touch)"]
105 #[doc = ""]
106 #[doc = "*This API requires the following crate features to be activated: `Touch`, `TouchInit`*"]
107 pub fn new(touch_init_dict: &TouchInit) -> Result<Touch, JsValue>;
108}