Struct prototty_wasm::InputBuffer
source · pub struct InputBuffer { /* private fields */ }
Implementations§
source§impl InputBuffer
impl InputBuffer
pub fn new() -> InputBuffer
pub fn clear(&mut self)
pub fn push_key_press(&mut self, key_code: u8, shift: bool)
pub fn push_mouse_scroll_up(&mut self, x: i32, y: i32)
pub fn push_mouse_scroll_down(&mut self, x: i32, y: i32)
pub fn push_mouse_scroll_left(&mut self, x: i32, y: i32)
pub fn push_mouse_scroll_right(&mut self, x: i32, y: i32)
pub fn push_mouse_move(&mut self, x: i32, y: i32)
pub fn push_mouse_press(&mut self, x: i32, y: i32)
pub fn push_mouse_release(&mut self, x: i32, y: i32)
Trait Implementations§
source§impl Default for InputBuffer
impl Default for InputBuffer
source§fn default() -> InputBuffer
fn default() -> InputBuffer
Returns the “default value” for a type. Read more
source§impl From<InputBuffer> for JsValue
impl From<InputBuffer> for JsValue
source§fn from(value: InputBuffer) -> JsValue
fn from(value: InputBuffer) -> JsValue
Converts to this type from the input type.
source§impl FromWasmAbi for InputBuffer
impl FromWasmAbi for InputBuffer
source§impl IntoWasmAbi for InputBuffer
impl IntoWasmAbi for InputBuffer
source§impl OptionFromWasmAbi for InputBuffer
impl OptionFromWasmAbi for InputBuffer
source§fn is_none(abi: &<InputBuffer as FromWasmAbi>::Abi) -> bool
fn is_none(abi: &<InputBuffer 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
. Read moresource§impl OptionIntoWasmAbi for InputBuffer
impl OptionIntoWasmAbi for InputBuffer
source§fn none() -> <InputBuffer as IntoWasmAbi>::Abi
fn none() -> <InputBuffer as IntoWasmAbi>::Abi
Returns an ABI instance indicating “none”, which JS will interpret as
the
None
branch of this option. Read moresource§impl RefFromWasmAbi for InputBuffer
impl RefFromWasmAbi for InputBuffer
§type Anchor = Ref<'static, InputBuffer>
type Anchor = Ref<'static, InputBuffer>
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. Read moresource§unsafe fn ref_from_abi(
js: <InputBuffer as RefFromWasmAbi>::Abi
) -> <InputBuffer as RefFromWasmAbi>::Anchor
unsafe fn ref_from_abi(
js: <InputBuffer as RefFromWasmAbi>::Abi
) -> <InputBuffer as RefFromWasmAbi>::Anchor
source§impl RefMutFromWasmAbi for InputBuffer
impl RefMutFromWasmAbi for InputBuffer
§type Anchor = RefMut<'static, InputBuffer>
type Anchor = RefMut<'static, InputBuffer>
Same as
RefFromWasmAbi::Anchor
source§unsafe fn ref_mut_from_abi(
js: <InputBuffer as RefMutFromWasmAbi>::Abi
) -> <InputBuffer as RefMutFromWasmAbi>::Anchor
unsafe fn ref_mut_from_abi(
js: <InputBuffer as RefMutFromWasmAbi>::Abi
) -> <InputBuffer as RefMutFromWasmAbi>::Anchor
Same as
RefFromWasmAbi::ref_from_abi
Auto Trait Implementations§
impl RefUnwindSafe for InputBuffer
impl Send for InputBuffer
impl Sync for InputBuffer
impl Unpin for InputBuffer
impl UnwindSafe for InputBuffer
Blanket Implementations§
source§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
Same as
IntoWasmAbi::Abi
source§fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
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
. Read more