button to set basic entry
Signed-off-by: Jeff Carr <jcarr@wit.com>
This commit is contained in:
parent
1a0de8d839
commit
3f3e8e1b2e
|
@ -62,7 +62,7 @@ func newChoices(parent *gui.Node) *choices {
|
|||
c.animal.AddText("honey badger")
|
||||
c.animal.AddText("polar bear")
|
||||
|
||||
c.place = gadgets.NewBasicEntry(c.grid, "common favorite place")
|
||||
c.place = gadgets.NewBasicEntry(c.grid, "favorite place")
|
||||
c.place.Custom = func() {
|
||||
log.Info("now set to:", c.place.String())
|
||||
if c.place == section1.place {
|
||||
|
@ -80,6 +80,9 @@ func newChoices(parent *gui.Node) *choices {
|
|||
c.grid.NewButton("disable animals", func() {
|
||||
c.animal.Disable()
|
||||
})
|
||||
c.grid.NewButton("set trust", func() {
|
||||
c.place.SetText("trust")
|
||||
})
|
||||
|
||||
return c
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue