Jaa


InteractionTrackerInertiaStateEnteredArgs Class

Definition

Arguments for the IInteractionTrackerOwner.InertiaStateEntered callback.

The InteractionTrackerOwner.InertiaStateEntered class defines the accessible and up-to-date property values when InteractionTracker enters the inertia state. If registered for the InertiaStateEntered event, values of this object's properties represent the results calculated by the system at the beginning of the inertia state. Using the modified and natural resting positions helps enables scenarios such as scrolling virtualization.

public ref class InteractionTrackerInertiaStateEnteredArgs sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 196608)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class InteractionTrackerInertiaStateEnteredArgs final
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 196608)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class InteractionTrackerInertiaStateEnteredArgs final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 196608)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class InteractionTrackerInertiaStateEnteredArgs
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 196608)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class InteractionTrackerInertiaStateEnteredArgs
Public NotInheritable Class InteractionTrackerInertiaStateEnteredArgs
Inheritance
Object Platform::Object IInspectable InteractionTrackerInertiaStateEnteredArgs
Attributes

Windows requirements

Device family
Windows 10 Anniversary Edition (introduced in 10.0.14393.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v3.0)

Examples

public void InertiaStateEntered(InteractionTracker sender, 	InteractionTrackerInertiaStateEnteredArgs args)
{
  // Natural and Modified Resting Positions and Scale
  Vector3 naturalRestPos = args.NaturalRestingPosition;
  Vector3 modifiedRestPos = (Vector3)args.ModifiedRestingPosition;
  float naturalRestScale = args.NaturalRestingScale;
  float modifiedRestScale = (float) args.ModifiedRestingScale;

  // Position and Scale velocity of InteractionTracker when entering Inertia
  Vector3 posVelocity = args.PositionVelocityInPixelsPerSecond;
  float scaleVelocity = args.ScaleVelocityInPercentPerSecond;

  // The ID for the request that triggered the callback
  int id = args.RequestId;
}

Remarks

Version history

Windows version SDK version Value added
1809 17763 IsInertiaFromImpulse
1903 18362 IsFromBinding

Properties

IsFromBinding

Gets a value that indicates whether this state was entered through interaction with a tracker that this one is bound to.

IsInertiaFromImpulse

Gets a value that indicates whether the inertia is the result of an impulse.

ModifiedRestingPosition

The InteractionTracker's resting position when inertia completes after InteractionTrackerInertiaModifiers and boundaries have been applied.

The ModifiedRestingPosition property represents the systems calculation of where the final resting position of InteractionTracker will be based on an interaction. Unlike the NaturalRestingPosition, ModifiedRestingPosition will be calculated based on other factors that affect the motion of InteractionTracker such as InertiaModifiers and Min/Max boundaries.

ModifiedRestingScale

The InteractionTracker's resting scale when inertia completes, after InteractionTrackerInertiaModifiers and boundaries have been applied.

The ModifiedRestingScale property represents the systems calculation of where the final resting scale position of InteractionTracker will be based on an interaction. Unlike the NaturalRestingScale, ModifiedRestingScale will be calculated based on other factors that affect the motion of InteractionTracker such as InertiaModifiers and Min/Max boundaries.

NaturalRestingPosition

The InteractionTracker's resting position when inertia completes, without any modifiers or boundaries applied.

The NaturalRestingPosition property represents the system’s calculation of InteractionTracker ’s final natural resting position based on an interaction. Unlike the ModifiedRestingPosition, NaturalRestingPosition will be calculated without any other factors that impact InteractionTracker ’s motion such as InertiaModifiers and Min/Max boundaries.

NaturalRestingScale

The InteractionTracker's resting scale when inertia completes, without accounting for InteractionTrackerInertiaModifiers or boundaries.

The NaturalRestingScale property represents the system’s calculation of InteractionTracker ’s final natural resting scale position based on an interaction. Unlike the ModifiedRestingScale, NaturalRestingScale will be calculated without any other factors that impact InteractionTracker ’s motion such as InteractionTrackerInertiaModifiers and Min/Max boundaries.

PositionVelocityInPixelsPerSecond

The velocity of InteractionTracker's position.

The PositionVelocityInPixelsPerSecond property represents the position velocity of InteractionTracker when it has entered the Inertia state.

RequestId

The ID of the request that triggered the callback. Represents the ID of the request that caused InteractionTracker to enter the Inertia State (the InertiaStateEntered callback was triggered). Note that the RequestID property will be incremented each time a request tries to change the state of InteractionTracker.

ScaleVelocityInPercentPerSecond

The velocity of InteractionTracker's scale.

The ScaleVelocityInPercentPerSecond property represents the scale velocity of InteractionTracker when it has entered the Inertia state.

Applies to