diff options
| author | Jeff Carr <[email protected]> | 2023-03-24 20:14:18 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2023-03-24 20:14:18 -0500 |
| commit | 6f91f5e080e06cdc0f34b13d23e5fd16ea37259a (patch) | |
| tree | 7037a36829c644dccc7cb78ee6f87f87f88aed21 /toolkit/andlabs/combobox.go | |
| parent | d4787a1ebdd08359746516dbb72f1feaf95be5b6 (diff) | |
starting to try safe chan and goroutines
fix tab title's
right before attempting to add chan goroutines
removed "where" widget pointer
box added to tab
experiement with log as it's own repo
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'toolkit/andlabs/combobox.go')
| -rw-r--r-- | toolkit/andlabs/combobox.go | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/toolkit/andlabs/combobox.go b/toolkit/andlabs/combobox.go index e200b3b..59d312d 100644 --- a/toolkit/andlabs/combobox.go +++ b/toolkit/andlabs/combobox.go @@ -6,11 +6,14 @@ import ( "git.wit.org/wit/gui/toolkit" ) -func (t *andlabsT) newCombobox(w *toolkit.Widget) *andlabsT { +func (t *andlabsT) newCombobox(a *toolkit.Action) *andlabsT { var newt andlabsT + w := a.Widget log(debugToolkit, "newCombobox() START", w.Name) newt.tw = w + newt.wId = a.WidgetId + newt.Type = w.Type s := ui.NewEditableCombobox() newt.uiEditableCombobox = s newt.uiControl = s @@ -21,7 +24,7 @@ func (t *andlabsT) newCombobox(w *toolkit.Widget) *andlabsT { s.OnChanged(func(spin *ui.EditableCombobox) { newt.tw.S = spin.Text() - newt.commonChange(newt.tw) + newt.commonChange(newt.tw, a.WidgetId) }) return &newt @@ -42,17 +45,14 @@ func (t *andlabsT) AddComboboxName(title string) { } func newCombobox(a *toolkit.Action) { - w := a.Widget - parentW := a.Where - log(debugToolkit, "newCombobox()", w.Name) + log(debugToolkit, "newCombobox()", a.Title) - t := mapToolkits[parentW] + t := andlabs[a.WhereId] if (t == nil) { - log(debugToolkit, "newCombobox() toolkit struct == nil. name=", parentW.Name, w.Name) + log(debugToolkit, "newCombobox() toolkit struct == nil. name=", a.Title) listMap(debugToolkit) return } - newt := t.newCombobox(w) + newt := t.newCombobox(a) place(a, t, newt) - mapWidgetsToolkits(a, newt) } |
