1 #![allow(unused_imports)]
2 use super::*;
3 use wasm_bindgen::prelude::*;
4 #[cfg(web_sys_unstable_apis)]
5 #[wasm_bindgen]
6 extern "C" {
7     # [wasm_bindgen (extends = :: js_sys :: Object , js_name = GPUExtent3DDict)]
8     #[derive(Debug, Clone, PartialEq, Eq)]
9     #[doc = "The `GpuExtent3dDict` dictionary."]
10     #[doc = ""]
11     #[doc = "*This API requires the following crate features to be activated: `GpuExtent3dDict`*"]
12     #[doc = ""]
13     #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
14     #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
15     pub type GpuExtent3dDict;
16 }
17 #[cfg(web_sys_unstable_apis)]
18 impl GpuExtent3dDict {
19     #[doc = "Construct a new `GpuExtent3dDict`."]
20     #[doc = ""]
21     #[doc = "*This API requires the following crate features to be activated: `GpuExtent3dDict`*"]
22     #[doc = ""]
23     #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
24     #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
new(width: u32) -> Self25     pub fn new(width: u32) -> Self {
26         #[allow(unused_mut)]
27         let mut ret: Self = ::wasm_bindgen::JsCast::unchecked_into(::js_sys::Object::new());
28         ret.width(width);
29         ret
30     }
31     #[cfg(web_sys_unstable_apis)]
32     #[doc = "Change the `depthOrArrayLayers` field of this object."]
33     #[doc = ""]
34     #[doc = "*This API requires the following crate features to be activated: `GpuExtent3dDict`*"]
35     #[doc = ""]
36     #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
37     #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
depth_or_array_layers(&mut self, val: u32) -> &mut Self38     pub fn depth_or_array_layers(&mut self, val: u32) -> &mut Self {
39         use wasm_bindgen::JsValue;
40         let r = ::js_sys::Reflect::set(
41             self.as_ref(),
42             &JsValue::from("depthOrArrayLayers"),
43             &JsValue::from(val),
44         );
45         debug_assert!(
46             r.is_ok(),
47             "setting properties should never fail on our dictionary objects"
48         );
49         let _ = r;
50         self
51     }
52     #[cfg(web_sys_unstable_apis)]
53     #[doc = "Change the `height` field of this object."]
54     #[doc = ""]
55     #[doc = "*This API requires the following crate features to be activated: `GpuExtent3dDict`*"]
56     #[doc = ""]
57     #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
58     #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
height(&mut self, val: u32) -> &mut Self59     pub fn height(&mut self, val: u32) -> &mut Self {
60         use wasm_bindgen::JsValue;
61         let r =
62             ::js_sys::Reflect::set(self.as_ref(), &JsValue::from("height"), &JsValue::from(val));
63         debug_assert!(
64             r.is_ok(),
65             "setting properties should never fail on our dictionary objects"
66         );
67         let _ = r;
68         self
69     }
70     #[cfg(web_sys_unstable_apis)]
71     #[doc = "Change the `width` field of this object."]
72     #[doc = ""]
73     #[doc = "*This API requires the following crate features to be activated: `GpuExtent3dDict`*"]
74     #[doc = ""]
75     #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
76     #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
width(&mut self, val: u32) -> &mut Self77     pub fn width(&mut self, val: u32) -> &mut Self {
78         use wasm_bindgen::JsValue;
79         let r = ::js_sys::Reflect::set(self.as_ref(), &JsValue::from("width"), &JsValue::from(val));
80         debug_assert!(
81             r.is_ok(),
82             "setting properties should never fail on our dictionary objects"
83         );
84         let _ = r;
85         self
86     }
87 }
88