Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Disable Selecting of Nodes/Links (Read 1562 times)
Nedor
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 16
Joined: Aug 6th, 2010
Disable Selecting of Nodes/Links
Sep 15th, 2010 at 9:06am
Print Post  
Is there any way to disable the selection of nodes/link and disable the edit funktion during the Behavior.DrawXXX (XXX=ShapeNodes,Links ... ) functions?
I want only Draw (and Add) new Nodes/Links to the diagram.
I change the Behavior to Behavior.Modify if i want to select (and modify) the nodes.
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Disable Selecting of Nodes/Links
Reply #1 - Sep 15th, 2010 at 10:04am
Print Post  
Handle the NodeSelecting and LinkSelecting validation events, and set e.Cancel = true.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Nedor
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 16
Joined: Aug 6th, 2010
Re: Disable Selecting of Nodes/Links
Reply #2 - Sep 15th, 2010 at 11:41am
Print Post  
Thanks, this works well, now i have another question:

If I change the behavior, all selected Items are deselected. But I want to "take" this selection in the new Behavior. Do I have to store the current selection, change the behavior and reset the selection? Or are there some other functions which are allowing to change the behavior without deselecting all Items?
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Disable Selecting of Nodes/Links
Reply #3 - Sep 15th, 2010 at 6:19pm
Print Post  
Clearing the selection from the Behavior setter doesn't seem to make much sense, perhaps it's some remnant from our ActiveX control where it was necessary for some reason. Now this build won't clear it anymore:
https://mindfusion.eu/_beta/fcnet541.zip

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