diff options
| author | Jeff Carr <[email protected]> | 2023-04-03 10:26:47 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2023-04-03 10:26:47 -0500 |
| commit | 4b6207743b90968d6b822032a4355e43b6ce6da9 (patch) | |
| tree | 2cb9f13d5e95f14e165f8e41e8484320b7454177 /toolkit/andlabs/window.go | |
| parent | 0320ebe4bb49ea80761d77af80fa208157ffdb89 (diff) | |
gocui: working towards correct layout
make a gocui widget binary tree
more debugging cleanups
sample button app displays in gocui
geometry logic closer to correct
improvements in gocui layout
continued attempts to clean up tabs
dump binary tree
moving towards proper chan callback()
deprecate Widget.Name
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'toolkit/andlabs/window.go')
| -rw-r--r-- | toolkit/andlabs/window.go | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/toolkit/andlabs/window.go b/toolkit/andlabs/window.go index 2fee729..f00e1ee 100644 --- a/toolkit/andlabs/window.go +++ b/toolkit/andlabs/window.go @@ -16,22 +16,14 @@ func (t *andlabsT) ErrorWindow(msg1 string, msg2 string) { } func newWindow(a *toolkit.Action) { - w := a.Widget var newt *andlabsT - // log(debugToolkit, "toolkit NewWindow", w.Name, w.Width, w.Height) - - if (w == nil) { - log(debugToolkit, "wit/gui plugin error. widget == nil") - return - } newt = new(andlabsT) - newt.tw = w - newt.Type = toolkit.Window + newt.WidgetType = toolkit.Window newt.wId = a.WidgetId // menubar bool is if the OS defined border on the window should be used - win := ui.NewWindow(w.Name, a.Width, a.Height, menubar) + win := ui.NewWindow(a.Name, a.Width, a.Height, menubar) win.SetBorderless(canvas) win.SetMargined(margin) win.OnClosing(func(*ui.Window) bool { @@ -41,8 +33,7 @@ func newWindow(a *toolkit.Action) { win.Show() newt.uiWindow = win newt.uiControl = win - // newt.UiWindowBad = win // deprecate this as soon as possible - newt.Name = w.Name + newt.Name = a.Name andlabs[a.WidgetId] = newt return |
