Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Prioritizing nodes in diagram (Read 1490 times)
Vincent
Junior Member
**
Offline


I Love MindFusion!

Posts: 62
Joined: Oct 3rd, 2013
Prioritizing nodes in diagram
Dec 3rd, 2013 at 1:32pm
Print Post  
Hi,

We have a custom node which can contain another node of the same type (operator) in either a left or right slot. We notice that when nesting a few of those nodes, if we want to remove a child, most of the time we can't select a child node. The focus still goes to the root parent.

We want to solve this by arranging the ZIndex property ourselves when nesting nodes. So the root parent would have the lowest ZIndex and the lowest child would have the highest ZIndex.

With this in mind, we have a few questions:
1. Would you recommend we do this with the ZIndex property? If not, how can we achieve this otherwise?

2. Does modifying the ZIndex property influence other functionality? Like GetNearestNode() of diagram? This would help in cases where we want to add an operator node to another operator which already has a parent operator. (Nesting a 2nd time) At the moment, GetNearestNode() returns the root parent.

Thanks!

Vincent

  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Prioritizing nodes in diagram
Reply #1 - Dec 3rd, 2013 at 2:12pm
Print Post  
Hi,

Try overriding DiagramItem.ContainsPoint and returning false if the specified point is inside a slot. The control should not select parent nodes then even if they are higher in Z order, when you click inside a slot.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint