diff options
| author | Jeff Carr <[email protected]> | 2019-06-01 01:20:20 -0700 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2019-06-01 01:20:20 -0700 |
| commit | bf9b5bd49d65dae7868d74d5f972510c2585ff7a (patch) | |
| tree | 6cbaf7e0b44a6054f91aa4307bb2ea41c75bdcb3 /area.go | |
| parent | 133ed30192bce5e2b10a993aaa17d26a11bed93f (diff) | |
more control panel code removal
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'area.go')
| -rw-r--r-- | area.go | 29 |
1 files changed, 27 insertions, 2 deletions
@@ -101,7 +101,32 @@ func (ah GuiArea) KeyEvent(a *ui.Area, ke *ui.AreaKeyEvent) (handled bool) { log.Println("GOT ENTER") } spew.Dump(ke) - // splashWin.Destroy() - // ui.Quit() return false } + +func ShowTextBox(gw *GuiWindow, newText *ui.AttributedString) *GuiBox { + log.Println("ShowTextBox() START") + if (gw == nil) { + log.Println("ShowTextBox() ERROR gw = nil") + return nil + } + log.Println("ShowTextBox() START gw =", gw) + + // create and setup a new GuiBox + var gb *GuiBox + gb = new(GuiBox) + + gb.EntryMap = make(map[string]*GuiEntry) + gb.EntryMap["test"] = nil + + newbox := ui.NewVerticalBox() + newbox.SetPadded(true) + gb.UiBox = newbox + gb.W = gw + gw.BoxMap["Splash"] = gb + + makeSplashArea(gb, newText) + newbox.Append(gb.Area.UiArea, true) + + return gb +} |
