~eliasnaur/gio-example

ref: 1ad8d13d0f99c508d3a2528dfe349f3313acc7c5 gio-example/gio-extras/haptic/example_android.go -rw-r--r-- 400 bytes
1ad8d13dChris Waldon windows,multiwindow: rename package for clarity 2 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
package main

import (
	"gioui.org/app"
	"gioui.org/io/event"
)

// ProcessPlatformEvent handles platform-specific event processing. If it
// consumed the provided event, it returns true. In this case, no further
// event processing should occur.
func ProcessPlatformEvent(event event.Event) bool {
	if ve, ok := event.(app.ViewEvent); ok {
		buzzer.SetView(ve.View)
		return true
	}
	return false
}