TouchDragDropTrigger StartDragPosition Property Delta Engine Documentation

Namespace: DeltaEngine.Input
Assembly: DeltaEngine.Input (in DeltaEngine.Input.dll) Version: 1.1.1.0 (1.1.1)
Syntax

public Vector2D StartDragPosition { get; set; }

Property Value

Type: Vector2D
Remarks

Tests: DeltaEngine.Input.Tests.TouchDragDropTriggerTests
Examples

2 unit tests call DeltaEngine.Input.TouchDragDropTrigger.StartDragPosition
[Test, CloseAfterFirstFrame]
public void Create()
{
    var trigger = new TouchDragDropTrigger(Rectangle.One);
    Assert.AreEqual(Rectangle.One, trigger.StartArea);
    Assert.AreEqual(Vector2D.Unused, trigger.StartDragPosition);
}
[Test, CloseAfterFirstFrame]
public void CreateFromAttributes()
{
    var trigger = new TouchDragDropTrigger(new Dictionary<string, string>
        {
            { "StartArea", new Rectangle(0.1f, 0.2f, 0.3f, 0.4f).ToString() }
        });
    Assert.AreEqual(new Rectangle(0.1f, 0.2f, 0.3f, 0.4f), trigger.StartArea);
    Assert.AreEqual(Vector2D.Unused, trigger.StartDragPosition);
}
See Also