maxcountryman_web_sys/features/
gen_WebGlContextEvent.rs1#![allow(unused_imports)]
2use super::*;
3use wasm_bindgen::prelude::*;
4#[wasm_bindgen]
5extern "C" {
6 # [wasm_bindgen (extends = Event , extends = :: js_sys :: Object , js_name = WebGLContextEvent , typescript_type = "WebGLContextEvent")]
7 #[derive(Debug, Clone, PartialEq, Eq)]
8 #[doc = "The `WebGlContextEvent` class."]
9 #[doc = ""]
10 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WebGLContextEvent)"]
11 #[doc = ""]
12 #[doc = "*This API requires the following crate features to be activated: `WebGlContextEvent`*"]
13 pub type WebGlContextEvent;
14 # [wasm_bindgen (structural , method , getter , js_class = "WebGLContextEvent" , js_name = statusMessage)]
15 #[doc = "Getter for the `statusMessage` field of this object."]
16 #[doc = ""]
17 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WebGLContextEvent/statusMessage)"]
18 #[doc = ""]
19 #[doc = "*This API requires the following crate features to be activated: `WebGlContextEvent`*"]
20 pub fn status_message(this: &WebGlContextEvent) -> String;
21 #[wasm_bindgen(catch, constructor, js_class = "WebGLContextEvent")]
22 #[doc = "The `new WebGlContextEvent(..)` constructor, creating a new instance of `WebGlContextEvent`."]
23 #[doc = ""]
24 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WebGLContextEvent/WebGLContextEvent)"]
25 #[doc = ""]
26 #[doc = "*This API requires the following crate features to be activated: `WebGlContextEvent`*"]
27 pub fn new(type_: &str) -> Result<WebGlContextEvent, JsValue>;
28 #[cfg(feature = "WebGlContextEventInit")]
29 #[wasm_bindgen(catch, constructor, js_class = "WebGLContextEvent")]
30 #[doc = "The `new WebGlContextEvent(..)` constructor, creating a new instance of `WebGlContextEvent`."]
31 #[doc = ""]
32 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/WebGLContextEvent/WebGLContextEvent)"]
33 #[doc = ""]
34 #[doc = "*This API requires the following crate features to be activated: `WebGlContextEvent`, `WebGlContextEventInit`*"]
35 pub fn new_with_event_init(
36 type_: &str,
37 event_init: &WebGlContextEventInit,
38 ) -> Result<WebGlContextEvent, JsValue>;
39}