From 64d3e26fb0ab5d2426bf1cdc2191c734ae9c9b00 Mon Sep 17 00:00:00 2001 From: Hajime Hoshi Date: Sun, 31 Mar 2019 16:28:50 +0900 Subject: [PATCH] input: Rename UpdateTouches -> SetTouches --- internal/input/input_mobile.go | 2 +- internal/ui/ui_mobile.go | 2 +- mobile/touches_mobile.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/internal/input/input_mobile.go b/internal/input/input_mobile.go index 43f68167f..515c8b2a6 100644 --- a/internal/input/input_mobile.go +++ b/internal/input/input_mobile.go @@ -46,7 +46,7 @@ func (i *Input) IsMouseButtonPressed(key driver.MouseButton) bool { return false } -func (i *Input) UpdateTouches(touches []*Touch) { +func (i *Input) SetTouches(touches []*Touch) { i.m.Lock() i.touches = touches // TODO: Need copy? i.m.Unlock() diff --git a/internal/ui/ui_mobile.go b/internal/ui/ui_mobile.go index 7107b181e..ddf8e1f4d 100644 --- a/internal/ui/ui_mobile.go +++ b/internal/ui/ui_mobile.go @@ -140,7 +140,7 @@ func appMain(a app.App) { for _, t := range touches { ts = append(ts, t) } - input.Get().UpdateTouches(ts) + input.Get().SetTouches(ts) } } } diff --git a/mobile/touches_mobile.go b/mobile/touches_mobile.go index c6bc29901..fba31d0c2 100644 --- a/mobile/touches_mobile.go +++ b/mobile/touches_mobile.go @@ -38,5 +38,5 @@ func updateTouches() { Y: position.y, }) } - input.Get().UpdateTouches(ts) + input.Get().SetTouches(ts) }