I made a pretty nice NodeGraph in WPF based on Canvas and am at the point where I'm adding nifty features through right-click menus.
These menus are context sensitive. Meaning a right-click on the background of the graph will display the graphs ContextMenu, whereas right-clicking a Node in the graph will display the nodes ContextMenu, or if the node has any child-controls with menus, those.
I have been postponing this particular issue for a while now but can no longer ignore it. As stated in the title: When I right-click a node, the context-menu of the graph will show. If I disable the context-menu of the graph, the nodes one shows up just fine.
This makes me believe this is an issue of the parent control taking precedence in opening a context menu. I have already tried overriding mouse events in both the parent and child controls and setting them to handled, but I just can't figure it out!
Could anyone assist me in getting rid of this very annoying issue?