InertiaRotationBehavior 클래스

정의

활동이 없는 동안 회전 조작의 감속을 제어합니다.

public ref class InertiaRotationBehavior
public class InertiaRotationBehavior
type InertiaRotationBehavior = class
Public Class InertiaRotationBehavior
상속
InertiaRotationBehavior

예제

다음 예제와 ManipulationInertiaStarting 이벤트 처리기에 대해 변환, 확장 등 회전 관성 도중 사용 되는 감속을 가져오거나 설정 합니다. 이 예제는에서 더 큰 예제의 일부 연습: 만드는 첫 번째 터치 애플리케이션합니다.

void Window_InertiaStarting(object sender, ManipulationInertiaStartingEventArgs e)
{

    // Decrease the velocity of the Rectangle's movement by 
    // 10 inches per second every second.
    // (10 inches * 96 pixels per inch / 1000ms^2)
    e.TranslationBehavior.DesiredDeceleration = 10.0 * 96.0 / (1000.0 * 1000.0);

    // Decrease the velocity of the Rectangle's resizing by 
    // 0.1 inches per second every second.
    // (0.1 inches * 96 pixels per inch / (1000ms^2)
    e.ExpansionBehavior.DesiredDeceleration = 0.1 * 96 / (1000.0 * 1000.0);

    // Decrease the velocity of the Rectangle's rotation rate by 
    // 2 rotations per second every second.
    // (2 * 360 degrees / (1000ms^2)
    e.RotationBehavior.DesiredDeceleration = 720 / (1000.0 * 1000.0);

    e.Handled = true;
}
Private Sub Window_InertiaStarting(ByVal sender As Object,
                                   ByVal e As ManipulationInertiaStartingEventArgs)

    ' Decrease the velocity of the Rectangle's movement by 
    ' 10 inches per second every second.
    ' (10 inches * 96 pixels per inch / 1000ms^2)
    e.TranslationBehavior.DesiredDeceleration = 10.0 * 96.0 / (1000.0 * 1000.0)

    ' Decrease the velocity of the Rectangle's resizing by 
    ' 0.1 inches per second every second.
    ' (0.1 inches * 96 pixels per inch / (1000ms^2)
    e.ExpansionBehavior.DesiredDeceleration = 0.1 * 96 / (1000.0 * 1000.0)

    ' Decrease the velocity of the Rectangle's rotation rate by 
    ' 2 rotations per second every second.
    ' (2 * 360 degrees / (1000ms^2)
    e.RotationBehavior.DesiredDeceleration = 720 / (1000.0 * 1000.0)

    e.Handled = True
End Sub

설명

InertiaRotationBehavior 클래스 관성 경우 회전 조작의 동작 방식을 지정 합니다. 사용 된 RotationBehavior 속성에는 ManipulationInertiaStarting 다음을 수행 하는 이벤트:

  • 관성의 초기 속도 설정 하 여이 시작 될 때 지정 된 InitialVelocity 속성입니다.

  • 설정 하 여 관성이 끝날 때 원하는 회전 조작의 지정 된 DesiredRotation 속성입니다.

  • 관성의 감속을 설정 하 여 지정 된 DesiredDeceleration 속성입니다.

설정 된 DesiredRotation 또는 DesiredDeceleration, 하지만 둘 다. 이러한 속성 중 하나를 설정 하면 다른 속성으로 변경 됩니다 Double.NaN 값이 있는 경우.

조작에 대 한 자세한 내용은 참조는 입력 개요합니다. 조작에 응답 하는 애플리케이션 예제를 보려면 연습: 만드는 첫 번째 터치 애플리케이션합니다.

생성자

InertiaRotationBehavior()

InertiaRotationBehavior 클래스의 새 인스턴스를 초기화합니다.

속성

DesiredDeceleration

회전이 느려지는 속도(제곱 밀리초당 도 단위)를 가져오거나 설정합니다.

DesiredRotation

관성 이동 끝에서의 회전(도 단위)을 가져오거나 설정합니다.

InitialVelocity

관성 단계 시작에서의 회전의 초기 속도를 가져오거나 설정합니다.

메서드

Equals(Object)

지정된 개체가 현재 개체와 같은지 확인합니다.

(다음에서 상속됨 Object)
GetHashCode()

기본 해시 함수로 작동합니다.

(다음에서 상속됨 Object)
GetType()

현재 인스턴스의 Type을 가져옵니다.

(다음에서 상속됨 Object)
MemberwiseClone()

현재 Object의 단순 복사본을 만듭니다.

(다음에서 상속됨 Object)
ToString()

현재 개체를 나타내는 문자열을 반환합니다.

(다음에서 상속됨 Object)

적용 대상