Visual Basic (Declaration) | |
---|---|
Public Overrides Sub DoActivate() |
C# | |
---|---|
public override void DoActivate() |
If StartPort is already set, it uses that element as the starting port. If it is not set, this calls FindLinkablePort and remembers the port as StartPort.
It then starts a model edit and changes the cursor. Next it initializes and adds the TemporaryFromNode, TemporaryToNode, and TemporaryLink to the diagram's Northwoods.GoXam.Diagram.PartsModel. The temporary nodes that are positioned and sized to be like the real (LinkingBaseTool.OriginalFromPort and LinkingBaseTool.OriginalToPort) ports by calling CopyPortProperties. The temporary link connects the two temporary nodes, of course.
The base LinkingBaseTool.DoStart method starts mouse capture.