diff options
Diffstat (limited to 'toolkit/andlabs')
| -rw-r--r-- | toolkit/andlabs/add.go | 5 | ||||
| -rw-r--r-- | toolkit/andlabs/main.go | 11 | ||||
| -rw-r--r-- | toolkit/andlabs/plugin.go | 38 | ||||
| -rw-r--r-- | toolkit/andlabs/tab.go | 4 | ||||
| -rw-r--r-- | toolkit/andlabs/window.go | 2 |
5 files changed, 30 insertions, 30 deletions
diff --git a/toolkit/andlabs/add.go b/toolkit/andlabs/add.go index 2a1b677..e6f3305 100644 --- a/toolkit/andlabs/add.go +++ b/toolkit/andlabs/add.go @@ -47,7 +47,10 @@ func add(a *toolkit.Action) { doWindow(a) return case toolkit.Tab: - newTab(a) + log(debugError, "add() CAME AT THIS FROM add() =", a.Name) + log(debugError, "add() CAME AT THIS FROM add() =", a.Name) + log(debugError, "add() CAME AT THIS FROM add() =", a.Name) + newTab(*a) return case toolkit.Label: newLabel(a) diff --git a/toolkit/andlabs/main.go b/toolkit/andlabs/main.go index a8c8b39..c107038 100644 --- a/toolkit/andlabs/main.go +++ b/toolkit/andlabs/main.go @@ -26,20 +26,15 @@ func catchActionChannel() { if (a.WidgetType == toolkit.Window) { log(logNow, "makeCallback() WINDOW START") go ui.Main( func() { - log(logNow, "ui.Main() WINDOW START") - rawAction(&a) + log(logNow, "ui.Main() WINDOW START DOING NOTHING") + newWindow(&a) log(logNow, "ui.Main() WINDOW END") }) sleep(.5) log(logNow, "makeCallback() WINDOW END") } else { log(logNow, "makeCallback() STUFF") - rawAction(&a) - /* - Queue( func() { - rawAction(&a) - }) - */ + rawAction(a) log(logNow, "makeCallback() STUFF END") } // sleep(.1) diff --git a/toolkit/andlabs/plugin.go b/toolkit/andlabs/plugin.go index f7577d1..f319add 100644 --- a/toolkit/andlabs/plugin.go +++ b/toolkit/andlabs/plugin.go @@ -22,7 +22,8 @@ func Send(p *toolkit.Widget, c *toolkit.Widget) { log(debugPlugin, "Send() goodbye. not used anymore") } -func Action(a *toolkit.Action) { + +func oldAction(a *toolkit.Action) { log(logNow, "Action() START") if (a == nil) { log(debugPlugin, "Action = nil") @@ -40,34 +41,35 @@ func Action(a *toolkit.Action) { log(logNow, "Action() END") } -func rawAction(a *toolkit.Action) { + +func rawAction(a toolkit.Action) { log(debugAction, "rawAction() START a.ActionType =", a.ActionType) log(debugAction, "rawAction() START a.S =", a.S) log(logNow, "rawAction() START a.WidgetId =", a.WidgetId, "a.ParentId =", a.ParentId) switch a.WidgetType { case toolkit.Flag: - flag(a) + flag(&a) return } switch a.ActionType { case toolkit.Add: - add(a) + add(&a) case toolkit.Show: a.B = true - show(a) + show(&a) case toolkit.Hide: a.B = false - show(a) + show(&a) case toolkit.Enable: a.B = true - enable(a) + enable(&a) case toolkit.Disable: a.B = false - enable(a) + enable(&a) case toolkit.Get: - setText(a) + setText(&a) case toolkit.GetText: switch a.WidgetType { case toolkit.Textbox: @@ -75,24 +77,24 @@ func rawAction(a *toolkit.Action) { a.S = t.s } case toolkit.Set: - setText(a) + setText(&a) case toolkit.SetText: - setText(a) + setText(&a) case toolkit.AddText: - setText(a) + setText(&a) case toolkit.Margin: - pad(a) + pad(&a) case toolkit.Unmargin: - pad(a) + pad(&a) case toolkit.Pad: - pad(a) + pad(&a) case toolkit.Unpad: - pad(a) + pad(&a) case toolkit.Delete: - uiDelete(a) + uiDelete(&a) case toolkit.Move: log(debugNow, "rawAction() attempt to move() =", a.ActionType, a.WidgetType) - move(a) + move(&a) default: log(debugError, "rawAction() Unknown =", a.ActionType, a.WidgetType) } diff --git a/toolkit/andlabs/tab.go b/toolkit/andlabs/tab.go index a9a3e38..6936df6 100644 --- a/toolkit/andlabs/tab.go +++ b/toolkit/andlabs/tab.go @@ -19,7 +19,7 @@ import ( once there is one. If you send a Window here, it will replace any existing tabs rather than adding a new one */ -func (t *andlabsT) newTab(a *toolkit.Action) { +func (t *andlabsT) newTab(a toolkit.Action) { // var w *ui.Window var newt *andlabsT @@ -118,7 +118,7 @@ func (t *andlabsT) appendTab(name string) *andlabsT { return &newT } -func newTab(a *toolkit.Action) { +func newTab(a toolkit.Action) { // w := a.Widget log(debugToolkit, "newTab()", a.ParentId) diff --git a/toolkit/andlabs/window.go b/toolkit/andlabs/window.go index cfa419f..9e2e950 100644 --- a/toolkit/andlabs/window.go +++ b/toolkit/andlabs/window.go @@ -30,12 +30,12 @@ func newWindow(a *toolkit.Action) { newt.doUserEvent() return true }) - win.Show() newt.uiWindow = win newt.uiControl = win newt.Name = a.Name andlabs[a.WidgetId] = newt + win.Show() return } |
