// Update implements gruid.Model.Update for TextInput. It considers mouse
// message coordinates to be absolute in its grid.
Update implements gruid.Model.Update for TextInput. It considers mouse
message coordinates to be absolute in its grid.
// Update implements gruid . Model . Update for TextInput . It considers mouse // message coordinates to be absolute in its grid .
func (ti *TextInput) Update(msg gruid.Msg) gruid.Effect {
	ti.action = TextInputPass
	switch msg := msg.(type) {
	case gruid.MsgKeyDown:
		ti.updateMsgKeyDown(msg)
	case gruid.MsgMouse:
		ti.updateMsgMouse(msg)
	}
	if ti.action != TextInputPass {
		ti.dirty = true
	}
	return nil
}
func ( ti * TextInput ) Update ( msg gruid . Msg ) gruid . Effect { ti . action = TextInputPass switch msg := msg . ( type ) { case gruid . MsgKeyDown : ti . updateMsgKeyDown ( msg ) case gruid . MsgMouse : ti . updateMsgMouse ( msg ) } if ti . action != TextInputPass { ti . dirty = true } return nil }
Update implements gruid.Model.Update for TextInput.
Update implements gruid . Model . Update for TextInput .