summaryrefslogtreecommitdiff
path: root/toolkit/nocui/structs.go
diff options
context:
space:
mode:
Diffstat (limited to 'toolkit/nocui/structs.go')
-rw-r--r--toolkit/nocui/structs.go46
1 files changed, 9 insertions, 37 deletions
diff --git a/toolkit/nocui/structs.go b/toolkit/nocui/structs.go
index c3ece3b..90c2c1e 100644
--- a/toolkit/nocui/structs.go
+++ b/toolkit/nocui/structs.go
@@ -1,47 +1,19 @@
package main
-import "git.wit.org/wit/gui/toolkit"
-
-var callback chan toolkit.Action
-
-type node struct {
- parent *node
- children []*node
-
- WidgetId int // widget ID
- WidgetType toolkit.WidgetType
- ParentId int // parent ID
-
- Name string
- Text string
-
- // This is how the values are passed back and forth
- // values from things like checkboxes & dropdown's
- B bool
- I int
- S string
-
- A any // switch to this or deprecate this? pros/cons?
-
- // This is used for things like a slider(0,100)
- X int
- Y int
-
- // This is for the grid size & widget position
- W int
- H int
- AtW int
- AtH int
-
- // the internal plugin toolkit structure
- tk *nocuiT
-}
+// import "git.wit.org/wit/gui/toolkit"
// stores the raw toolkit internals
-type nocuiT struct {
+type guiWidget struct {
Width int
Height int
c int
val map[int]string
}
+
+// It's probably a terrible idea to call this 'me'
+var me config
+
+type config struct {
+ rootNode *node // the base of the binary tree. it should have id == 0
+}