summaryrefslogtreecommitdiff
path: root/click.go
diff options
context:
space:
mode:
Diffstat (limited to 'click.go')
-rw-r--r--click.go33
1 files changed, 21 insertions, 12 deletions
diff --git a/click.go b/click.go
index f815aa6..1f3f144 100644
--- a/click.go
+++ b/click.go
@@ -100,6 +100,7 @@ func (w *guiWidget) doWidgetClick() {
log.Log(NOW, "doWidgetClick() FLAG widget name =", w.String())
log.Log(NOW, "doWidgetClick() if this is the dropdown menu, handle it here?")
case widget.Window:
+ log.Log(NOW, "doWidgetClick() START on window", w.String())
if me.currentWindow == w.node {
return
}
@@ -112,8 +113,12 @@ func (w *guiWidget) doWidgetClick() {
}
me.currentWindow = w.node
+ log.Log(NOW, "doWidgetClick() set currentWindow to", w.String())
w.setColor(&colorActiveW)
w.hideWidgets()
+ w.placeWidgets(me.RawW, me.RawH)
+ w.showWidgets()
+ /*
w.redoTabs(me.TabW, me.TabH)
for _, child := range w.children {
if child.currentTab == true {
@@ -124,6 +129,7 @@ func (w *guiWidget) doWidgetClick() {
return
}
}
+ */
/* FIXME: redo this
if ! n.hasTabs {
}
@@ -310,18 +316,20 @@ func findUnderMouse() *tree.Node {
found = n
}
}
- if n == me.ddview {
- tk := me.ddview.TK.(*guiWidget)
- log.Log(NOW, "findUnderMouse() found ddview")
- if tk.Visible() {
- log.Log(NOW, "findUnderMouse() and ddview is visable. hide it here. TODO: find highlighted row")
- found = n
- // find the actual value here and set the dropdown widget
- me.baseGui.DeleteView("ddview")
- } else {
- log.Log(NOW, "findUnderMouse() I was lying, actually it's not found")
+ /*
+ if n == me.ddview {
+ tk := me.ddview.TK.(*guiWidget)
+ log.Log(NOW, "findUnderMouse() found ddview")
+ if tk.Visible() {
+ log.Log(NOW, "findUnderMouse() and ddview is visable. hide it here. TODO: find highlighted row")
+ found = n
+ // find the actual value here and set the dropdown widget
+ me.baseGui.DeleteView("ddview")
+ } else {
+ log.Log(NOW, "findUnderMouse() I was lying, actually it's not found")
+ }
}
- }
+ */
for _, child := range widget.children {
f(child.node)
@@ -332,7 +340,8 @@ func findUnderMouse() *tree.Node {
// TODO: pop up menu with a list of them
for _, n := range widgets {
//log(logNow, "ctrlDown() FOUND widget", widget.id, widget.name)
- showWidgetPlacement(n, true, "findUnderMouse() FOUND")
+ widget := n.TK.(*guiWidget)
+ widget.showWidgetPlacement(true, "findUnderMouse() FOUND")
}
return found
}