GoXam for WPF v3
ComputeMove Method
Northwoods.GoXam.Tool Namespace > DraggingTool Class : ComputeMove Method
the Northwoods.GoXam.Node being moved
the proposed new Northwoods.GoXam.Node.Location for the node n, in model coordinates
a Dictionary of Northwoods.GoXam.Parts being dragged
This method computes the new location for a node, given a new desired location and a dictionary of dragged parts.
Syntax

Parameters

n
the Northwoods.GoXam.Node being moved
newloc
the proposed new Northwoods.GoXam.Node.Location for the node n, in model coordinates
draggedparts
a Dictionary of Northwoods.GoXam.Parts being dragged

Return Value

a new location for the node, in model coordinates
Remarks

If DragOverSnapArea includes nodes, this finds a Northwoods.GoXam.Node that acts as a drag-snapping controller, typically a grid-like node, at the newloc point, using ConsiderSnapTo as the predicate to find a qualified drag-snapping node. If it finds such a drag-snapper node, it calls SnapTo to get the adjusted new location.

If DragOverSnapArea includes the diagram, and if the diagram's Northwoods.GoXam.Diagram.GridSnapEnabled property is true, this calls SnapTo with a null value for the moving node, allowing that method to consider the "GridSnap..." properties of the Northwoods.GoXam.Diagram in computing the new location for the node n.

It then limits the new location using the Northwoods.GoXam.Node.MinLocation and Northwoods.GoXam.Node.MaxLocation properties.

See Also

Reference

DraggingTool Class
DraggingTool Members