private void OnSurfaceMouseMove(object sender, MouseEventArgs e)
{
if (_lineGeometry != null)
{
_lineGeometry.EndPoint = e.GetPosition(_surface);
}
if (_dragStarted && SelectedItemHost != null)
{
var designerControl = SelectedItemHost as ActivityHost;
if (designerControl != null)
{
var newX = e.GetPosition(_surface).X - _clickPosition.X;
var newY = e.GetPosition(_surface).Y - _clickPosition.Y;
designerControl.PositionX = newX > 0 ? newX : 0;
designerControl.PositionY = newY > 0 ? newY : 0;
}
}
}