mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-12 20:18:59 +01:00
mobile: Move Render to a global func
This commit is contained in:
parent
f41455c2cf
commit
59a21620dc
@ -20,8 +20,6 @@ import (
|
||||
)
|
||||
|
||||
type EventDispatcher interface {
|
||||
Render() error
|
||||
|
||||
// UpdateTouchesOnAndroid updates the touch state on Android.
|
||||
//
|
||||
// This should be called with onTouchEvent of GLSurfaceView like this:
|
||||
@ -47,6 +45,10 @@ func Start(f func(*ebiten.Image) error, width, height int, scale float64, title
|
||||
return start(f, width, height, scale, title)
|
||||
}
|
||||
|
||||
func Render() error {
|
||||
return render()
|
||||
}
|
||||
|
||||
type position struct {
|
||||
x int
|
||||
y int
|
||||
@ -56,10 +58,6 @@ type eventDispatcher struct {
|
||||
touches map[int]position
|
||||
}
|
||||
|
||||
func (e *eventDispatcher) Render() error {
|
||||
return render()
|
||||
}
|
||||
|
||||
// touch implements ui.Touch.
|
||||
type touch struct {
|
||||
id int
|
||||
|
Loading…
Reference in New Issue
Block a user