Trait script::dom::bindings::codegen::Bindings::MouseEventBinding::MouseEvent_Binding::MouseEventMethods
source · pub trait MouseEventMethods {
Show 21 methods
// Required methods
fn ScreenX(&self) -> i32;
fn ScreenY(&self) -> i32;
fn ClientX(&self) -> i32;
fn ClientY(&self) -> i32;
fn PageX(&self) -> i32;
fn PageY(&self) -> i32;
fn X(&self) -> i32;
fn Y(&self) -> i32;
fn OffsetX(&self, _can_gc: CanGc) -> i32;
fn OffsetY(&self, _can_gc: CanGc) -> i32;
fn CtrlKey(&self) -> bool;
fn ShiftKey(&self) -> bool;
fn AltKey(&self) -> bool;
fn MetaKey(&self) -> bool;
fn Button(&self) -> i16;
fn GetRelatedTarget(&self) -> Option<Root<Dom<EventTarget>>>;
fn Buttons(&self) -> u16;
fn Which(&self) -> i32;
fn InitMouseEvent(
&self,
typeArg: DOMString,
bubblesArg: bool,
cancelableArg: bool,
viewArg: Option<&Window>,
detailArg: i32,
screenXArg: i32,
screenYArg: i32,
clientXArg: i32,
clientYArg: i32,
ctrlKeyArg: bool,
altKeyArg: bool,
shiftKeyArg: bool,
metaKeyArg: bool,
buttonArg: i16,
relatedTargetArg: Option<&EventTarget>,
);
fn IsTrusted(&self) -> bool;
fn Constructor(
global: &Window,
proto: Option<HandleObject<'_>>,
can_gc: CanGc,
typeArg: DOMString,
mouseEventInitDict: &MouseEventInit,
) -> Result<Root<Dom<MouseEvent>>, Error>;
}
Required Methods§
fn ScreenX(&self) -> i32
fn ScreenY(&self) -> i32
fn ClientX(&self) -> i32
fn ClientY(&self) -> i32
fn PageX(&self) -> i32
fn PageY(&self) -> i32
fn X(&self) -> i32
fn Y(&self) -> i32
fn OffsetX(&self, _can_gc: CanGc) -> i32
fn OffsetY(&self, _can_gc: CanGc) -> i32
fn CtrlKey(&self) -> bool
fn ShiftKey(&self) -> bool
fn AltKey(&self) -> bool
fn MetaKey(&self) -> bool
fn Button(&self) -> i16
fn GetRelatedTarget(&self) -> Option<Root<Dom<EventTarget>>>
fn Buttons(&self) -> u16
fn Which(&self) -> i32
fn InitMouseEvent( &self, typeArg: DOMString, bubblesArg: bool, cancelableArg: bool, viewArg: Option<&Window>, detailArg: i32, screenXArg: i32, screenYArg: i32, clientXArg: i32, clientYArg: i32, ctrlKeyArg: bool, altKeyArg: bool, shiftKeyArg: bool, metaKeyArg: bool, buttonArg: i16, relatedTargetArg: Option<&EventTarget>, )
fn IsTrusted(&self) -> bool
fn Constructor( global: &Window, proto: Option<HandleObject<'_>>, can_gc: CanGc, typeArg: DOMString, mouseEventInitDict: &MouseEventInit, ) -> Result<Root<Dom<MouseEvent>>, Error>
Object Safety§
This trait is not object safe.