func (c *Console) Respond(ui *gui.Gui, group gui.EventGroup) bool { if found, event := group.FindEvent(GetDefaultKeyMap()["console"].Id()); found && event.Type == gin.Press { if group.Focus { ui.DropFocus() } else { ui.TakeFocus(c) } return true } if group.Focus { // if found, event := group.FindEvent(gin.Left); found && event.Type == gin.Press { // c.xscroll += 250 // } // if found, event := group.FindEvent(gin.Right); found && event.Type == gin.Press { // c.xscroll -= 250 // } } if c.xscroll > 0 { c.xscroll = 0 } if found, event := group.FindEvent(gin.AnySpace); found && event.Type == gin.Press { c.xscroll = 0 } return group.Focus }