mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-26 02:42:02 +01:00
exp/textinput: refactoring
This commit is contained in:
parent
0a20670f3f
commit
0fa39182cb
@ -59,10 +59,7 @@ var theTextInput textInput
|
|||||||
func (t *textInput) Start(x, y int) (chan State, func()) {
|
func (t *textInput) Start(x, y int) (chan State, func()) {
|
||||||
var session *session
|
var session *session
|
||||||
ui.Get().RunOnMainThread(func() {
|
ui.Get().RunOnMainThread(func() {
|
||||||
if t.session != nil {
|
t.end()
|
||||||
t.session.end()
|
|
||||||
t.session = nil
|
|
||||||
}
|
|
||||||
C.start(C.int(x), C.int(y))
|
C.start(C.int(x), C.int(y))
|
||||||
session = newSession()
|
session = newSession()
|
||||||
t.session = session
|
t.session = session
|
||||||
|
Loading…
Reference in New Issue
Block a user