[][src]Struct qt_3d_input::QMouseEvent

#[repr(C)]pub struct QMouseEvent { /* fields omitted */ }

The Qt3DCore::QMouseEvent contains parameters that describe a mouse event.

C++ class: Qt3DInput::QMouseEvent.

C++ documentation:

The Qt3DCore::QMouseEvent contains parameters that describe a mouse event.

Mouse events occur when a mouse button is pressed and the ray traversing the view, originating from the mouse position intersects with one or more elements of the scene.

Methods

impl QMouseEvent[src]

pub unsafe fn button(&self) -> Buttons[src]

Specifies the button triggering the mouse event

Calls C++ function: Qt3DInput::QMouseEvent::Buttons Qt3DInput::QMouseEvent::button() const.

C++ documentation:

Specifies the button triggering the mouse event

Access functions:

Buttons button() const

pub unsafe fn buttons(&self) -> c_int[src]

Specifies the button triggering the mouse event

Calls C++ function: int Qt3DInput::QMouseEvent::buttons() const.

C++ documentation:

Specifies the button triggering the mouse event

Access functions:

int buttons() const

pub unsafe fn is_accepted(&self) -> bool[src]

Returns whether the event was accepted.

Calls C++ function: bool Qt3DInput::QMouseEvent::isAccepted() const.

C++ documentation:

Returns whether the event was accepted.

Note: Getter function for property accepted.

pub unsafe fn meta_object(&self) -> Ptr<QMetaObject>[src]

Calls C++ function: virtual const QMetaObject* Qt3DInput::QMouseEvent::metaObject() const.

pub unsafe fn modifiers(&self) -> Modifiers[src]

Specifies if any modifiers were applied to the mouse event

Calls C++ function: Qt3DInput::QMouseEvent::Modifiers Qt3DInput::QMouseEvent::modifiers() const.

C++ documentation:

Specifies if any modifiers were applied to the mouse event

Access functions:

Modifiers modifiers() const

pub unsafe fn new(e: impl CastInto<Ref<QMouseEvent>>) -> QBox<QMouseEvent>[src]

Constructs a new QMouseEvent instance for the QMouseEvent e.

Calls C++ function: [constructor] void Qt3DInput::QMouseEvent::QMouseEvent(const QMouseEvent& e).

C++ documentation:

Constructs a new QMouseEvent instance for the QMouseEvent e.

pub unsafe fn qt_metacall(
    &self,
    arg1: Call,
    arg2: c_int,
    arg3: *mut *mut c_void
) -> c_int
[src]

Calls C++ function: virtual int Qt3DInput::QMouseEvent::qt_metacall(QMetaObject::Call arg1, int arg2, void** arg3).

pub unsafe fn qt_metacast(&self, arg1: *const c_char) -> *mut c_void[src]

Calls C++ function: virtual void* Qt3DInput::QMouseEvent::qt_metacast(const char* arg1).

pub unsafe fn set_accepted(&self, accepted: bool)[src]

Sets the event as accepted if accepted is true.

Calls C++ function: void Qt3DInput::QMouseEvent::setAccepted(bool accepted).

C++ documentation:

Sets the event as accepted if accepted is true.

Note: When an event is accepted, it will prevent further propagation to other listeners.

Note: Setter function for property accepted.

See also isAccepted().

pub unsafe fn static_meta_object() -> Ref<QMetaObject>[src]

Returns a reference to the staticMetaObject field.

pub unsafe fn tr(
    s: *const c_char,
    c: *const c_char,
    n: c_int
) -> CppBox<QString>
[src]

Calls C++ function: static QString Qt3DInput::QMouseEvent::tr(const char* s, const char* c, int n).

pub unsafe fn tr_utf8(
    s: *const c_char,
    c: *const c_char,
    n: c_int
) -> CppBox<QString>
[src]

Calls C++ function: static QString Qt3DInput::QMouseEvent::trUtf8(const char* s, const char* c, int n).

pub unsafe fn type_(&self) -> Type[src]

Returns the QEvent::Type of the event.

Calls C++ function: QEvent::Type Qt3DInput::QMouseEvent::type() const.

C++ documentation:

Returns the QEvent::Type of the event.

pub unsafe fn was_held(&self) -> bool[src]

Specifies if a mouse button was held down during the mouse event

Calls C++ function: bool Qt3DInput::QMouseEvent::wasHeld() const.

C++ documentation:

Specifies if a mouse button was held down during the mouse event

Access functions:

bool wasHeld() const

pub unsafe fn x(&self) -> c_int[src]

Specifies The X coordinate of the mouse event

Calls C++ function: int Qt3DInput::QMouseEvent::x() const.

C++ documentation:

Specifies The X coordinate of the mouse event

Access functions:

int x() const

pub unsafe fn y(&self) -> c_int[src]

Specifies The y coordinate of the mouse event

Calls C++ function: int Qt3DInput::QMouseEvent::y() const.

C++ documentation:

Specifies The y coordinate of the mouse event

Access functions:

int y() const

Trait Implementations

impl CppDeletable for QMouseEvent[src]

unsafe fn delete(&self)[src]

Destroys the instance of QMouseEvent.

Calls C++ function: virtual [destructor] void Qt3DInput::QMouseEvent::~QMouseEvent().

C++ documentation:

Destroys the instance of QMouseEvent.

impl Deref for QMouseEvent[src]

type Target = QObject

The resulting type after dereferencing.

fn deref(&self) -> &QObject[src]

Calls C++ function: QObject* static_cast<QObject*>(Qt3DInput::QMouseEvent* ptr).

impl DynamicCast<QMouseEvent> for QObject[src]

unsafe fn dynamic_cast(ptr: Ptr<QObject>) -> Ptr<QMouseEvent>[src]

Calls C++ function: Qt3DInput::QMouseEvent* dynamic_cast<Qt3DInput::QMouseEvent*>(QObject* ptr).

impl StaticDowncast<QMouseEvent> for QObject[src]

unsafe fn static_downcast(ptr: Ptr<QObject>) -> Ptr<QMouseEvent>[src]

Calls C++ function: Qt3DInput::QMouseEvent* static_cast<Qt3DInput::QMouseEvent*>(QObject* ptr).

impl StaticUpcast<QObject> for QMouseEvent[src]

unsafe fn static_upcast(ptr: Ptr<QMouseEvent>) -> Ptr<QObject>[src]

Calls C++ function: QObject* static_cast<QObject*>(Qt3DInput::QMouseEvent* ptr).

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T, U> CastInto<U> for T where
    U: CastFrom<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> StaticUpcast<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.