Current picking algo in Z-Ascending order worked only by chance, as it picked up any bottom node. Proper algo is in Z-Descending order to block occluded (child) nodes: for-all s : shapes p1 = testPicking(s) if ( s is Container ) { p2 = testPicking(s.childs) if( null != p2 ) { p1 = p2; // override w/ child prio } } return p1 } Further, testPicking(shape) shall only return a positive shape, if the event dispatching check (mouse-over, click, ..) signals end-of-traversal - as originally intended. Overall philosophy is to pick the 'deepest' child of a group if responding, otherwise the next higher interactive group.
Commit 43a7899fedf2a570d20b03848bf15710f30b7f26 Bug 1498: Change Top-Level Widget Mode: Register a top-level Group in Scene, where its zOffset gets adjusted when activated.. .. instead of having a non-working complicated callback orgy setup. This also takes away the getAdjustedZ() overloading burden (or better uglyness) etc. Hence Group's setWidgetMode(boolean) became: - enableTopLevelWidget(Scene) - disableTopLevelWidget() The forwardActivation listener is still applied to all children as well as isActive() is also still overloaded for same required behavior. However, none of the children is set in 'widget mode' as well as the Group is simply added to (or removed from) the Scene's top-level Group list - the holder. Scene's setActiveShape(Shape) and releaseActiveShape() handle the top-level Group if affected, i.e. adding or zero'ing its ZOffset.
commit ec5d278a51eaaf4062010df41cf23f884e4b715b GraphUI Cleanup: Use TreeTool directly (Reduce virtl-funcs); Fix typos; Use PointerListener for onClicked(), add onHover(); Subsequent commits will fix complete cleanup where code was changed mostly regarding other issues. +++ commit 8df74578481431768b3c26294c6bd64ed7030ae5 Bug 1498: GraphUI: Adopt RangedSlider to new picking (coming up), simplifies code. +++
commit 4b5de7337d2b335d512a0ff969222f038b734b8b (HEAD -> master) Bug 1498: GraphUI: Fix Picking Traversal throughout Groups in Z-Descending Order, testing Children and fallback to Group if positive .. fixed as described
(In reply to Sven Gothel from comment #1) commit 0ac7b2e59d5b41302f8e0ec7596d8f44447cf0a1 Bug 1498: Refine Top-Level Widget Mode: Handle active-state by Scene, simplify and reduce runtime costs Refines commit 43a7899fedf2a570d20b03848bf15710f30b7f26 Scene handles top-level active state via releaseActiveShape() and setActive(), now calling into setActiveTopLevel() -> dispatchActivationEvent(). Drop child's addActivationListener(forwardActivation) and isActive() override.