diff options
| author | Jeff Carr <[email protected]> | 2024-01-07 05:46:59 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-01-07 05:46:59 -0600 |
| commit | 930bdc941b1181460f4c38dc708dc53d583ab5d3 (patch) | |
| tree | 725fc54433bcc5a5947922bae0fee2a6b830b346 /errorBox.go | |
| parent | 82b5717f48f258f6ea792cd4e895c0ba99cf1e11 (diff) | |
remove debugging options
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'errorBox.go')
| -rw-r--r-- | errorBox.go | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/errorBox.go b/errorBox.go new file mode 100644 index 0000000..ea31f6a --- /dev/null +++ b/errorBox.go @@ -0,0 +1,47 @@ +/* + Show a box for a configuration error +*/ + +package main + +import ( + "go.wit.com/log" + "go.wit.com/gui/gui" + "go.wit.com/gui/gadgets" +) + +type errorBox struct { + name string // the problem name + + parent *gui.Node + group *gui.Node + grid *gui.Node + + l *gui.Node + b *gui.Node + + something *gadgets.OneLiner +} + +func NewErrorBox(p *gui.Node, name string) *errorBox { + var eb *errorBox + eb = new(errorBox) + eb.parent = p + // eb.group = p.NewGroup("eg") + // eb.grid = eb.group.NewGrid("labels", 2, 1) + + eb.l = p.NewLabel("click to fix") + eb.b = p.NewButton("fix", func() { + log.Log(WARN, "should try to fix here") + }) + eb.something = gadgets.NewOneLiner(eb.grid, "something") + + return eb +} + +func (eb *errorBox) update() bool { + return false +} + +func (eb *errorBox) toggle() { +} |
