quiet output related to expected init() conditions
This commit is contained in:
parent
bdb93a7b57
commit
cb3047ab09
10
add.go
10
add.go
|
@ -60,9 +60,13 @@ func newAdd(n *tree.Node) {
|
|||
}
|
||||
add(n)
|
||||
if n.TK == nil {
|
||||
log.Log(WARN, "newAdd() Tree sent an action on a widget we didn't seem to have.", n.WidgetId)
|
||||
// do this init here again? Probably something
|
||||
// went wrong and we should reset the our while gocui.View tree
|
||||
if n.WidgetId == 1 || n.WidgetId == 2 {
|
||||
// this is normal at plugin init() time
|
||||
} else {
|
||||
// this probably shouldn't be happening
|
||||
log.Log(WARN, "newAdd() Tree sent an action on a widget we didn't seem to have.", n.WidgetId, n.WidgetType, n.ProgName())
|
||||
}
|
||||
// Probably something went wrong and we should reset / redraw everything?
|
||||
n.TK = initWidget(n)
|
||||
}
|
||||
// show(n, !a.State.Hidden)
|
||||
|
|
|
@ -26,7 +26,7 @@ func newWindow(p, n *tree.Node) {
|
|||
win.SetBorderless(n.State.Borderless)
|
||||
win.SetMargined(n.State.Pad)
|
||||
win.OnClosing(func(*ui.Window) bool {
|
||||
// show(n, false)
|
||||
newt.uiWindow = nil // delete the local reference to the window
|
||||
me.myTree.SendWindowCloseEvent(n)
|
||||
// n.DeleteNode()
|
||||
return true
|
||||
|
|
Loading…
Reference in New Issue