Applied formatting & added GetWait().
- GetWait waits for an event in a blocking way.
This commit is contained in:
parent
4d98c63391
commit
ab5572018d
@ -135,6 +135,12 @@ func (eq *EventQueue) Get() Event {
|
|||||||
return eq.mapEvent(&event)
|
return eq.mapEvent(&event)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (eq *EventQueue) GetWait() Event {
|
||||||
|
var event C.ALLEGRO_EVENT
|
||||||
|
C.al_wait_for_event(eq.queue, &event)
|
||||||
|
return eq.mapEvent(&event)
|
||||||
|
}
|
||||||
|
|
||||||
func (eq *EventQueue) Destroy() {
|
func (eq *EventQueue) Destroy() {
|
||||||
C.al_destroy_event_queue(eq.queue)
|
C.al_destroy_event_queue(eq.queue)
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user