2022-10-16 08:07:13 -05:00
|
|
|
package gui
|
|
|
|
|
2023-03-01 11:35:36 -06:00
|
|
|
import (
|
2024-01-01 15:43:50 -06:00
|
|
|
"go.wit.com/gui/gui/toolkit"
|
2023-03-01 11:35:36 -06:00
|
|
|
)
|
2022-10-16 08:07:13 -05:00
|
|
|
|
2023-05-09 08:38:33 -05:00
|
|
|
func (parent *Node) NewSlider(name string, x int, y int) *Node {
|
2023-05-09 20:25:37 -05:00
|
|
|
newNode := parent.newNode(name, toolkit.Slider)
|
|
|
|
|
|
|
|
newNode.Custom = func() {
|
2023-03-01 11:35:36 -06:00
|
|
|
log(debugGui, "even newer clicker() name in NewSlider name =", name)
|
2023-05-09 20:25:37 -05:00
|
|
|
}
|
2022-10-19 13:23:22 -05:00
|
|
|
|
2023-05-09 08:38:33 -05:00
|
|
|
newNode.X = x
|
|
|
|
newNode.Y = y
|
|
|
|
a := newAction(newNode, toolkit.Add)
|
2023-03-23 12:35:12 -05:00
|
|
|
a.X = x
|
|
|
|
a.Y = y
|
2023-05-09 18:53:31 -05:00
|
|
|
sendAction(a)
|
2023-03-23 12:35:12 -05:00
|
|
|
|
2022-11-13 08:53:03 -06:00
|
|
|
return newNode
|
2022-10-16 08:07:13 -05:00
|
|
|
}
|