We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

LinkTool gets activated when poking on the link port, Why?

Hello, The link tool gets activated when I click on a links port object. This gives the effect that the linktool is considered active in the IMouseEventReceiver.MouseUp event handler. What''s the reason behind activating the tool in this case and where is it activated? I have preventing edit/resizing of the link by setting these properties: link.EditStyle.AllowResize = false; link.EditStyle.AllowVertexEdit = false; link.EditStyle.AllowRotate = false; link.EditStyle.DefaultHandleEditMode = HandleEditMode.None; The reason why I''m asking this is that I didn''t expect the link tool to be activated unless the user clicks the link tool button. I have done some custom implementation in the IMouseEventReceiver.MouseUp method which gets effected when the tool gets activated outside of my control. Best regards Tommy Norman

1 Reply

AD Administrator Syncfusion Team April 6, 2005 08:11 PM UTC

Hi Tommy, This is an interesting issue that you have raised. I have logged this as a feature request, and we will try to provide an option on the LinkTool that disables auto activation from the MouseDown event. For the time being, you can workaround the condition by using a custom LinkTool in place of the default tool. The LinkTool gets activated from it''s IMouseEventReceiver.MouseDown(...) method, when the call to the LinkTool.HitTestLinkPorts(...) method returns a valid Port allowing the subsequent call to Controller.ActivateTool(...). Enclosing this part of the ''If'' block in your custom LinkTool.IMouseEventReceiver.MouseDown(...) method within an enable/disable flag will let you rewire the activation behavior so that only an explicit invocation of the Controller.ActivateTool(...) method from your application will activate the tool. Regards, Prakash Surendra Syncfusion Inc.,

Loader.
Up arrow icon