From b88cca4b0d5f8948e682d6c70752c23ec7808d53 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Thu, 25 Jan 2024 18:16:51 -0600 Subject: checkbox state works Signed-off-by: Jeff Carr --- action.go | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'action.go') diff --git a/action.go b/action.go index cc5a975..0eecda1 100644 --- a/action.go +++ b/action.go @@ -60,6 +60,13 @@ func sendAction(n *Node, atype widget.ActionType) { defer n.mu.Unlock() // log.Log(PLUG, "SENDING ACTION STRINGS n.Strings", n.strings, n.id, n.WidgetType, n.GetProgName()) + if n.changed { + n.changed = false + } else { + // probably shouldn't even send this to the toolkits + // TODO: can't implement this yet + } + // this checks to see if the window is show in the toolkit. If it is not, // then don't send any events. Unless it is a window widget, then send events if n.WidgetType != widget.Window { @@ -103,6 +110,8 @@ func sendAction(n *Node, atype widget.ActionType) { a.State.Checked = n.checked a.State.Visable = n.visable + // TODO: if visable == false here, return + a.State.Hidden = n.hidden a.State.Pad = n.pad a.State.Expand = n.expand a.State.Borderless = n.borderless -- cgit v1.2.3