Struct workflow_nw::ipc::imports::Window

source ·
pub struct Window { /* private fields */ }
Expand description

Interface for managing application windows. For usage example please refer to nw_sys::window

Implementations§

source§

impl Window

source

pub fn window(&self) -> Window

Get the corresponding DOM window object of the native window.

NWJS Documentation

source§

impl Window

source

pub fn x(&self) -> i32

Get left offset from window frame to screen.

NWJS Documentation

source§

impl Window

source

pub fn set_x(&self, x: i32)

Set left offset from window frame to screen.

NWJS Documentation

source§

impl Window

source

pub fn y(&self) -> i32

Get top offset from window frame to screen.

NWJS Documentation

source§

impl Window

source

pub fn set_y(&self, y: i32)

Set top offset from window frame to screen.

NWJS Documentation

source§

impl Window

source

pub fn width(&self) -> u32

Get window’s size, including the window’s frame.

NWJS Documentation

source§

impl Window

source

pub fn set_width(&self, width: u32)

Set window’s size, including the window’s frame.

NWJS Documentation

source§

impl Window

source

pub fn height(&self) -> u32

Get window’s size, including the window’s frame.

NWJS Documentation

source§

impl Window

source

pub fn set_height(&self, height: u32)

Set window’s size, including the window’s frame.

NWJS Documentation

source§

impl Window

source

pub fn title(&self) -> String

Get window’s title.

NWJS Documentation

source§

impl Window

source

pub fn set_title(&self, title: &str)

Set window’s title.

NWJS Documentation

source§

impl Window

source

pub fn menu(&self) -> Menu

Get window’s menubar.

NWJS Documentation

source§

impl Window

source

pub fn set_menu(&self, menu: &Menu)

Set window’s menubar.

NWJS Documentation

source§

impl Window

source

pub fn remove_menu_impl(&self, menu: JsValue)

Set window’s menubar = null.

NWJS Documentation

source§

impl Window

source

pub fn is_always_on_top(&self) -> bool

Get whether the window is always on top of other windows.

NWJS Documentation

source§

impl Window

source

pub fn is_fullscreen(&self) -> bool

Get whether we’re in fullscreen mode.

NWJS Documentation

source§

impl Window

source

pub fn is_transparent(&self) -> bool

Get whether transparency is turned on

NWJS Documentation

source§

impl Window

source

pub fn is_kiosk_mode(&self) -> bool

Get whether we’re in kiosk mode.

NWJS Documentation

source§

impl Window

source

pub fn zoom_level(&self) -> i16

Get the page zoom. 0 for normal size; positive value for zooming in; negative value for zooming out.

NWJS Documentation

source§

impl Window

source

pub fn set_zoom_level(&self, zoom: i16)

Set the page zoom. 0 for normal size; positive value for zooming in; negative value for zooming out.

NWJS Documentation

source§

impl Window

source

pub fn move_to(&self, x: u32, y: u32)

Moves a window’s left and top edge to the specified coordinates.

NWJS Documentation

source§

impl Window

source

pub fn move_by(&self, x: u32, y: u32)

Moves a window a specified number of pixels relative to its current coordinates.

NWJS Documentation

source§

impl Window

source

pub fn resize_to(&self, width: u32, height: u32)

Resizes a window to the specified width and height.

NWJS Documentation

source§

impl Window

source

pub fn set_inner_width(&self, width: u32)

Set the inner width of the window

NWJS Documentation

source§

impl Window

source

pub fn set_inner_height(&self, height: u32)

Set the inner height of the window

NWJS Documentation

source§

impl Window

source

pub fn resize_by(&self, width: u32, height: u32)

Resizes a window by the specified amount.

NWJS Documentation

source§

impl Window

source

pub fn focus(&self)

Focus on the window.

NWJS Documentation

source§

impl Window

source

pub fn blur(&self)

Move focus away. Usually it will move focus to other windows of your app, since on some platforms there is no concept of blur.

NWJS Documentation

source§

impl Window

source

pub fn show(&self)

Show the window if it’s not shown.

NWJS Documentation

source§

impl Window

source

pub fn set_show(&self, is_show: bool)

Show/Hide the window

NWJS Documentation

source§

impl Window

source

pub fn hide(&self)

Hide the window. User will not be able to find the window once it’s hidden.

NWJS Documentation

source§

impl Window

source

pub fn close(&self)

Closes the current window. You can prevent the closing by listening to the close event.

NWJS Documentation

source§

impl Window

source

pub fn close_impl(&self, force: bool)

Closes the current window. You can prevent the closing by listening to the close event. if force is equals true, then the close event will be ignored.

NWJS Documentation

source§

impl Window

source

pub fn reload(&self)

Reloads the current window.

NWJS Documentation

source§

impl Window

source

pub fn reload_dev(&self)

Reloads the current page by starting a new renderer process from scratch.

NWJS Documentation

source§

impl Window

source

pub fn reload_ignoring_cache(&self)

Like reload(), but don’t use caches (aka “shift-reload”).

NWJS Documentation

source§

impl Window

source

pub fn maximize(&self)

Maximize the window on GTK and Windows, and zoom the window on Mac OS X.

NWJS Documentation

source§

impl Window

source

pub fn unmaximize(&self)

Unmaximize the window, i.e. the reverse of maximize().

NWJS Documentation

source§

impl Window

source

pub fn minimize(&self)

Minimize the window to task bar on Windows, iconify the window on GTK, and miniaturize the window on Mac OS X.

NWJS Documentation

source§

impl Window

source

pub fn restore(&self)

Restore window to previous state after the window is minimized, i.e. the reverse of minimize(). It’s not named unminimize since restore is used commonly.

NWJS Documentation

source§

impl Window

source

pub fn enter_fullscreen(&self)

Make the window fullscreen.

NWJS Documentation

source§

impl Window

source

pub fn leave_fullscreen(&self)

Leave the fullscreen mode.

NWJS Documentation

source§

impl Window

source

pub fn toggle_fullscreen(&self)

Toggle the fullscreen mode.

NWJS Documentation

source§

impl Window

source

pub fn enter_kiosk_mode(&self)

Enter the Kiosk mode. In Kiosk mode, the app will be fullscreen and try to prevent users from leaving the app, so you should remember to provide a way in app to leave Kiosk mode. This mode is mainly used for presentation on public displays.

NWJS Documentation

source§

impl Window

source

pub fn leave_kiosk_mode(&self)

Leave the Kiosk mode.

NWJS Documentation

source§

impl Window

source

pub fn toggle_kiosk_mode(&self)

Toggle the kiosk mode.

NWJS Documentation

source§

impl Window

source

pub fn set_transparent(&self, transparent: bool)

Turn on/off the transparency support.

See more info on Transparent Window.

NWJS Documentation

source§

impl Window

source

pub fn set_shadow(&self, shadow: bool)

(Mac) Turn the window’s native shadow on/off. Useful for frameless, transparent windows.

NWJS Documentation

source§

impl Window

source

pub fn show_dev_tools(&self)

Open the devtools to inspect the window.

NWJS Documentation

source§

impl Window

source

pub fn show_dev_tools_with_id(&self, iframe_id: &str)

Open the devtools to inspect the window.

NWJS Documentation

source§

impl Window

source

pub fn show_dev_tools_with_id_and_callback( &self, iframe_id: &str, callback: &Function, )

Open the devtools to inspect the window.

NWJS Documentation

source§

impl Window

source

pub fn show_dev_tools_with_iframe(&self, iframe_element: &HtmlIFrameElement)

Open the devtools to inspect the window.

NWJS Documentation

source§

impl Window

source

pub fn show_dev_tools_with_iframe_and_callback( &self, iframe_element: &HtmlIFrameElement, callback: &Function, )

Open the devtools to inspect the window.

NWJS Documentation

source§

impl Window

source

pub fn close_dev_tools(&self)

Close the devtools window.

NWJS Documentation

source§

impl Window

source

pub fn get_printers(&self, callback: &Function)

Enumerate the printers in the system. The callback function will receive an array of JSON objects for the printer information. The device name of the JSON object can be used as parameter in win.print()

NWJS Documentation

source§

impl Window

source

pub fn is_dev_tools_open(&self) -> bool

Query the status of devtools window.

NWJS Documentation

source§

impl Window

source

pub fn print(&self, options: &PrintOptions)

Print the web contents in the window with or without the need for user’s interaction.

NWJS Documentation

source§

impl Window

source

pub fn set_maximum_size(&self, width: u32, height: u32)

Set window’s maximum size.

NWJS Documentation

source§

impl Window

source

pub fn set_minimum_size(&self, width: u32, height: u32)

Set window’s minimum size.

NWJS Documentation

source§

impl Window

source

pub fn set_resizable(&self, resizable: bool)

Set whether window is resizable.

NWJS Documentation

source§

impl Window

source

pub fn set_always_on_top(&self, top: bool)

Sets the widget to be on top of all other windows in the window system.

NWJS Documentation

source§

impl Window

source

pub fn set_visible_on_all_workspaces(&self, top: bool)

(Mac and Linux) Sets the widget to be on top of all other windows in the window system.

NWJS Documentation

source§

impl Window

source

pub fn can_set_visible_on_all_workspaces(&self) -> bool

(Mac and Linux) Returns a boolean indicating if the platform (currently Mac OS X and Linux) support Window API method win.set_visible_on_all_workspaces(true/false).

NWJS Documentation

source§

impl Window

source

pub fn set_position_impl(&self, position: JsValue)

Move window to specified position. Currently only center is supported on all platforms, which will put window in the middle of the screen.

There are three valid positions: null or center or mouse

NWJS Documentation

source§

impl Window

source

pub fn set_show_in_taskbar(&self, show: bool)

Control whether to show window in taskbar or dock.

See also show_in_taskbar in Manifest-format.

NWJS Documentation

source§

impl Window

source

pub fn request_attention(&self, attension: bool)

Request the user’s attension by making the window flashes in the task bar.

NWJS Documentation

source§

impl Window

source

pub fn request_attention_with_number(&self, attension: i16)

Request the user’s attension by making the window flashes in the task bar.

On Mac, value < 0 will trigger NSInformationalRequest, while value > 0 will trigger NSCriticalRequest.

NWJS Documentation

source§

impl Window

source

pub fn capture_page(&self, callback: &Function)

Captures the visible area of the window.

To capture the full page, see win.captureScreenshot.

NWJS Documentation

source§

impl Window

source

pub fn capture_page_with_config( &self, callback: &Function, config: &CaptureConfig, )

Captures the visible area of the window.

To capture the full page, see win.captureScreenshot.

NWJS Documentation

source§

impl Window

source

pub fn capture_screenshot(&self, config: &ScreenshotConfig) -> Promise

Captures the the window. It can be used to capture the full page beyond the visible area.

Note: This API is experimental and subject to change in the future.

NWJS Documentation

source§

impl Window

source

pub fn capture_screenshot_with_callback( &self, config: &ScreenshotConfig, callback: &Function, )

Captures the the window. It can be used to capture the full page beyond the visible area.

Note: This API is experimental and subject to change in the future.

NWJS Documentation

source§

impl Window

source

pub fn set_progress_bar(&self, progress: f32)

Set progress bar

Note: Only Ubuntu is supported, and you’ll need to specify the application .desktop file through NW_DESKTOP env.

If NW_DESKTOP env variable is not found, it uses nw.desktop by default.

NWJS Documentation

source§

impl Window

source

pub fn set_badge_label(&self, label: &str)

Set the badge label on the window icon in taskbar or dock.

Note: This API is only supported on Ubuntu and the label is restricted to a string number only. You’ll also need to specify the .desktop file for your application (see the note on set_progress_bar)

NWJS Documentation

source§

impl Window

source

pub fn eval_impl(&self, iframe: JsValue, script: &str)

Execute a piece of JavaScript in the frame.

NWJS Documentation

source§

impl Window

source

pub fn eval_with_iframe(&self, iframe: &HtmlIFrameElement, script: &str)

Execute a piece of JavaScript in the frame.

NWJS Documentation

source§

impl Window

source

pub fn eval_nw_bin_impl(&self, iframe: JsValue, script: JsValue)

Load and execute the compiled binary in the frame.

See Protect JavaScript Source Code.

NWJS Documentation

source§

impl Window

source

pub fn eval_nw_bin_with_iframe_impl( &self, iframe: &HtmlIFrameElement, script: JsValue, )

Load and execute the compiled binary in the frame.

See Protect JavaScript Source Code.

NWJS Documentation

source§

impl Window

source

pub fn eval_nw_bin_module_impl( &self, iframe: JsValue, script: JsValue, module_path: &str, )

Load and execute the compiled binary for Modules in the frame.

The binary should be compiled with nwjc –nw-module. The following code will load lib.bin as module and other modules can refer to it with something like import * from "./lib.js"

NWJS Documentation

source§

impl Window

source

pub fn eval_nw_bin_module_with_iframe( &self, iframe: &HtmlIFrameElement, script: JsValue, module_path: &str, )

Load and execute the compiled binary for Modules in the frame.

The binary should be compiled with nwjc –nw-module. The following code will load lib.bin as module and other modules can refer to it with something like import * from "./lib.js"

NWJS Documentation

source§

impl Window

source

pub fn remove_all_listeners(&self)

Removes all listeners

NWJS Documentation

source§

impl Window

source

pub fn remove_all_listeners_with_name(&self, event_name: &str)

Removes all listeners of the specified event_name

NWJS Documentation

source§

impl Window

source

pub fn on(&self, event_name: &str, callback: &Function)

Add event listener to the specified event_name

NWJS Documentation

source§

impl Window

source

pub fn remove_menu(&self)

Set window’s menubar = null.

NWJS Documentation

source

pub fn close_with_force(&self)

Closes the current window without triggering close event.

NWJS Documentation

source

pub fn set_position(&self, position: WindowPosition)

Move window to specified position. Currently only center is supported on all platforms, which will put window in the middle of the screen.

There are three valid positions: null or center or mouse

NWJS Documentation

source

pub fn eval(&self, iframe: Option<HtmlIFrameElement>, script: &str)

Execute a piece of JavaScript in the frame.

NWJS Documentation

source

pub fn eval_nw_bin(&self, iframe: Option<HtmlIFrameElement>, script: NWBinary)

Load and execute the compiled binary in the frame.

See Protect JavaScript Source Code.

NWJS Documentation

source

pub fn eval_nw_bin_module( &self, iframe: Option<HtmlIFrameElement>, script: NWBinary, module_path: &str, )

Load and execute the compiled binary for Modules in the frame.

The binary should be compiled with nwjc –nw-module. The following code will load lib.bin as module and other modules can refer to it with something like import * from "./lib.js"

NWJS Documentation

Methods from Deref<Target = JsValue>§

source

pub const NULL: JsValue = _

source

pub const UNDEFINED: JsValue = _

source

pub const TRUE: JsValue = _

source

pub const FALSE: JsValue = _

source

pub fn as_f64(&self) -> Option<f64>

Returns the f64 value of this JS value if it’s an instance of a number.

If this JS value is not an instance of a number then this returns None.

source

pub fn is_string(&self) -> bool

Tests whether this JS value is a JS string.

source

pub fn as_string(&self) -> Option<String>

If this JS value is a string value, this function copies the JS string value into wasm linear memory, encoded as UTF-8, and returns it as a Rust String.

To avoid the copying and re-encoding, consider the JsString::try_from() function from js-sys instead.

If this JS value is not an instance of a string or if it’s not valid utf-8 then this returns None.

§UTF-16 vs UTF-8

JavaScript strings in general are encoded as UTF-16, but Rust strings are encoded as UTF-8. This can cause the Rust string to look a bit different than the JS string sometimes. For more details see the documentation about the str type which contains a few caveats about the encodings.

source

pub fn as_bool(&self) -> Option<bool>

Returns the bool value of this JS value if it’s an instance of a boolean.

If this JS value is not an instance of a boolean then this returns None.

source

pub fn is_null(&self) -> bool

Tests whether this JS value is null

source

pub fn is_undefined(&self) -> bool

Tests whether this JS value is undefined

source

pub fn is_symbol(&self) -> bool

Tests whether the type of this JS value is symbol

source

pub fn is_object(&self) -> bool

Tests whether typeof self == "object" && self !== null.

source

pub fn is_array(&self) -> bool

Tests whether this JS value is an instance of Array.

source

pub fn is_function(&self) -> bool

Tests whether the type of this JS value is function.

source

pub fn is_bigint(&self) -> bool

Tests whether the type of this JS value is bigint.

source

pub fn js_typeof(&self) -> JsValue

Applies the unary typeof JS operator on a JsValue.

MDN documentation

source

pub fn js_in(&self, obj: &JsValue) -> bool

Applies the binary in JS operator on the two JsValues.

MDN documentation

source

pub fn is_truthy(&self) -> bool

Tests whether the value is “truthy”.

source

pub fn is_falsy(&self) -> bool

Tests whether the value is “falsy”.

source

pub fn loose_eq(&self, other: &JsValue) -> bool

Compare two JsValues for equality, using the == operator in JS.

MDN documentation

source

pub fn bit_not(&self) -> JsValue

Applies the unary ~ JS operator on a JsValue.

MDN documentation

source

pub fn unsigned_shr(&self, rhs: &JsValue) -> u32

Applies the binary >>> JS operator on the two JsValues.

MDN documentation

source

pub fn checked_div(&self, rhs: &JsValue) -> JsValue

Applies the binary / JS operator on two JsValues, catching and returning any RangeError thrown.

MDN documentation

source

pub fn pow(&self, rhs: &JsValue) -> JsValue

Applies the binary ** JS operator on the two JsValues.

MDN documentation

source

pub fn lt(&self, other: &JsValue) -> bool

Applies the binary < JS operator on the two JsValues.

MDN documentation

source

pub fn le(&self, other: &JsValue) -> bool

Applies the binary <= JS operator on the two JsValues.

MDN documentation

source

pub fn ge(&self, other: &JsValue) -> bool

Applies the binary >= JS operator on the two JsValues.

MDN documentation

source

pub fn gt(&self, other: &JsValue) -> bool

Applies the binary > JS operator on the two JsValues.

MDN documentation

source

pub fn unchecked_into_f64(&self) -> f64

Applies the unary + JS operator on a JsValue. Can throw.

MDN documentation

Trait Implementations§

source§

impl AsRef<JsValue> for Window

source§

fn as_ref(&self) -> &JsValue

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl AsRef<Window> for Window

source§

fn as_ref(&self) -> &Window

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl Clone for Window

source§

fn clone(&self) -> Window

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Window

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl Deref for Window

§

type Target = JsValue

The resulting type after dereferencing.
source§

fn deref(&self) -> &JsValue

Dereferences the value.
source§

impl From<JsValue> for Window

source§

fn from(obj: JsValue) -> Window

Converts to this type from the input type.
source§

impl From<Window> for IpcTarget

source§

fn from(window: Window) -> IpcTarget

Converts to this type from the input type.
source§

impl From<Window> for JsValue

source§

fn from(obj: Window) -> JsValue

Converts to this type from the input type.
source§

impl FromWasmAbi for Window

§

type Abi = <JsValue as FromWasmAbi>::Abi

The wasm ABI type that this converts from when coming back out from the ABI boundary.
source§

unsafe fn from_abi(js: <Window as FromWasmAbi>::Abi) -> Window

Recover a Self from Self::Abi. Read more
source§

impl<'a> IntoWasmAbi for &'a Window

§

type Abi = <&'a JsValue as IntoWasmAbi>::Abi

The wasm ABI type that this converts into when crossing the ABI boundary.
source§

fn into_abi(self) -> <&'a Window as IntoWasmAbi>::Abi

Convert self into Self::Abi so that it can be sent across the wasm ABI boundary.
source§

impl IntoWasmAbi for Window

§

type Abi = <JsValue as IntoWasmAbi>::Abi

The wasm ABI type that this converts into when crossing the ABI boundary.
source§

fn into_abi(self) -> <Window as IntoWasmAbi>::Abi

Convert self into Self::Abi so that it can be sent across the wasm ABI boundary.
source§

impl IpcDispatch for Window

source§

fn as_target(&self) -> IpcTarget

source§

fn notify<'life0, 'async_trait, Ops, Msg>( &'life0 self, op: Ops, payload: Msg, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Ops: OpsT + 'async_trait, Msg: BorshSerialize + Send + Sync + 'static + 'async_trait, Self: Sync + 'async_trait, 'life0: 'async_trait,

source§

fn call<'life0, 'async_trait, Ops, Req, Resp>( &'life0 self, op: Ops, req: Req, ) -> Pin<Box<dyn Future<Output = Result<Resp>> + Send + 'async_trait>>
where Ops: OpsT + 'async_trait, Req: MsgT + 'async_trait, Resp: MsgT + 'async_trait, Self: Sync + 'async_trait, 'life0: 'async_trait,

source§

fn call_with_source<'life0, 'life1, 'async_trait, Ops, Req, Resp>( &'life0 self, op: Ops, req: Req, source: &'life1 IpcTarget, ) -> Pin<Box<dyn Future<Output = Result<Resp>> + Send + 'async_trait>>
where Ops: OpsT + 'async_trait, Req: MsgT + 'async_trait, Resp: MsgT + 'async_trait, Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source§

impl JsCast for Window

source§

fn instanceof(val: &JsValue) -> bool

Performs a dynamic instanceof check to see whether the JsValue provided is an instance of this type. Read more
source§

fn unchecked_from_js(val: JsValue) -> Window

Performs a zero-cost unchecked conversion from a JsValue into an instance of Self Read more
source§

fn unchecked_from_js_ref(val: &JsValue) -> &Window

Performs a zero-cost unchecked conversion from a &JsValue into an instance of &Self. Read more
source§

fn has_type<T>(&self) -> bool
where T: JsCast,

Test whether this JS value has a type T. Read more
source§

fn dyn_into<T>(self) -> Result<T, Self>
where T: JsCast,

Performs a dynamic cast (checked at runtime) of this value into the target type T. Read more
source§

fn dyn_ref<T>(&self) -> Option<&T>
where T: JsCast,

Performs a dynamic cast (checked at runtime) of this value into the target type T. Read more
source§

fn unchecked_into<T>(self) -> T
where T: JsCast,

Performs a zero-cost unchecked cast into the specified type. Read more
source§

fn unchecked_ref<T>(&self) -> &T
where T: JsCast,

Performs a zero-cost unchecked cast into a reference to the specified type. Read more
source§

fn is_instance_of<T>(&self) -> bool
where T: JsCast,

Test whether this JS value is an instance of the type T. Read more
source§

fn is_type_of(val: &JsValue) -> bool

Performs a dynamic check to see whether the JsValue provided is a value of this type. Read more
source§

impl LongRefFromWasmAbi for Window

§

type Abi = <JsValue as LongRefFromWasmAbi>::Abi

Same as RefFromWasmAbi::Abi
§

type Anchor = Window

Same as RefFromWasmAbi::Anchor
source§

unsafe fn long_ref_from_abi( js: <Window as LongRefFromWasmAbi>::Abi, ) -> <Window as LongRefFromWasmAbi>::Anchor

Same as RefFromWasmAbi::ref_from_abi
source§

impl OptionFromWasmAbi for Window

source§

fn is_none(abi: &<Window as FromWasmAbi>::Abi) -> bool

Tests whether the argument is a “none” instance. If so it will be deserialized as None, and otherwise it will be passed to FromWasmAbi.
source§

impl<'a> OptionIntoWasmAbi for &'a Window

source§

fn none() -> <&'a Window as IntoWasmAbi>::Abi

Returns an ABI instance indicating “none”, which JS will interpret as the None branch of this option. Read more
source§

impl OptionIntoWasmAbi for Window

source§

fn none() -> <Window as IntoWasmAbi>::Abi

Returns an ABI instance indicating “none”, which JS will interpret as the None branch of this option. Read more
source§

impl RefFromWasmAbi for Window

§

type Abi = <JsValue as RefFromWasmAbi>::Abi

The wasm ABI type references to Self are recovered from.
§

type Anchor = ManuallyDrop<Window>

The type that holds the reference to Self for the duration of the invocation of the function that has an &Self parameter. This is required to ensure that the lifetimes don’t persist beyond one function call, and so that they remain anonymous.
source§

unsafe fn ref_from_abi( js: <Window as RefFromWasmAbi>::Abi, ) -> <Window as RefFromWasmAbi>::Anchor

Recover a Self::Anchor from Self::Abi. Read more
source§

impl Send for Window

source§

impl Sync for Window

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Any for T
where T: Any,

source§

fn into_any(self: Box<T>) -> Box<dyn Any>

source§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

source§

fn type_name(&self) -> &'static str

source§

impl<T> AnySync for T
where T: Any + Send + Sync,

source§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Sync + Send>

source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where T: Clone,

source§

default unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ReturnWasmAbi for T
where T: IntoWasmAbi,

§

type Abi = <T as IntoWasmAbi>::Abi

Same as IntoWasmAbi::Abi
source§

fn return_abi(self) -> <T as ReturnWasmAbi>::Abi

Same as IntoWasmAbi::into_abi, except that it may throw and never return in the case of Err.
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

source§

fn vzip(self) -> V

source§

impl<T> VectorFromWasmAbi for T
where T: JsObject,

source§

impl<T> VectorIntoWasmAbi for T
where T: JsObject,

source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more