Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic unable to remove node - Factory.CreateShapeNode (Read 1462 times)
meriturva
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 17
Joined: Feb 27th, 2007
unable to remove node - Factory.CreateShapeNode
Oct 14th, 2009 at 10:28am
Print Post  
Diagram Wpf version 2.2.1 (trial)
Behaviour : DrawControls

if i create a new node just dragging a rectangle on the diagram area, the node is created correctly and it is possible to remove it just selecting and pressing del key.

if i use the factory with the code:
Code
Select All
this.diagram.Factory.CreateShapeNode(diagramPoint.X - offsetPoint.X, diagramPoint.Y - offsetPoint.Y, 220, 220);
 



the node is selectable but it is not possible to delete it.
any ideas?
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: unable to remove node - Factory.CreateShapeNod
Reply #1 - Oct 14th, 2009 at 11:09am
Print Post  
I suppose the keyboard focus is not on the Diagram control. If it's inside a ScrollViewer, set <ScrollViewer Focusable="False" ... >, otherwise the ScrollViewer might steal the focus.
  
Back to top
 
IP Logged
 
meriturva
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 17
Joined: Feb 27th, 2007
Re: unable to remove node - Factory.CreateShapeNod
Reply #2 - Oct 14th, 2009 at 12:12pm
Print Post  
Perfect! The ScrollViewer was the problem!
Thanks.
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint