Documentation
¶
Overview ¶
Package touch defines an event for touch input, for the GoGi GUI system.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var KiT_Actions = kit.Enums.AddEnum(ActionsN, kit.NotBitFlag, nil)
Functions ¶
This section is empty.
Types ¶
type Actions ¶
type Actions int32
Actions describes the action taken for a touch event.
const ( // Begin is a user first touching the device. // // On Android, this is a AMOTION_EVENT_ACTION_DOWN. // On iOS, this is a call to touchesBegan. Begin Actions = iota // Move is a user dragging across the device. // // A TypeMove is delivered between a TypeBegin and TypeEnd. // // On Android, this is a AMOTION_EVENT_ACTION_MOVE. // On iOS, this is a call to touchesMoved. Move // End is a user no longer touching the device. // // On Android, this is a AMOTION_EVENT_ACTION_UP. // On iOS, this is a call to touchesEnded. End ActionsN )
func (*Actions) FromString ¶
type Event ¶
type Event struct {
oswin.EventBase
// Where is the touch location, in raw display dots (raw, actual pixels)
Where image.Point
// Sequence is the sequence number. The same number is shared by all events
// in a sequence. A sequence begins with a single Begin, is followed by
// zero or more Moves, and ends with a single End. A Sequence
// distinguishes concurrent sequences but its value is subsequently reused.
Sequence Sequence
// Action is the touch action
Action Actions
}
touch.Event is a touch event.
Click to show internal directories.
Click to hide internal directories.