Responder

Base class of Window and View for event processing.

Modulerequire("yue.gui")
TypeClass

Methods

setcapture()

Set mouse capture to the responder.

releasecapture()

Release mouse capture if the responder has mouse capture.

hascapture()

Return whether the responder has mouse capture.

Return

boolean

Events

onmousedown(self, event)

Emitted when pressing mouse buttons.

Parameters

Preventable

Yes.

onmouseup(self, event)

Emitted when releasing mouse buttons.

Parameters

Preventable

Yes.

onmousemove(self, event)

Emitted when user moves mouse in the responder.

Parameters

Preventable

No.

onmouseenter(self, event)

Emitted when mouse enters the responder.

Parameters

Preventable

No.

onmouseleave(self, event)

Emitted when mouse leaves the responder.

Parameters

Preventable

No.

onkeydown(self, event)

Emitted when pressing keyboard.

Parameters

Preventable

Yes.

onkeyup(self, event)

Emitted when releasing keyboard.

Parameters

Preventable

Yes.

oncapturelost(self)

Emitted when the mouse capture on responder has been released.

Parameters

Preventable

No.