语言

ViewExtensions.RotateToAsync 方法

定义

重载

名称 说明
RotateToAsync(VisualElement, Double, UInt32, Easing)

返回一个任务,该任务轮换VisualElement由 viewrotationlengtheasing参数和参数描述的指定任务。

RotateToAsync(VisualElement, Double, UInt32, Easing, CancellationToken)

返回一个任务,该任务轮换VisualElement由 viewrotationlengtheasing参数和参数描述的指定任务。

RotateToAsync(VisualElement, Double, UInt32, Easing)

Source:
ViewExtensions.cs
Source:
ViewExtensions.cs

返回一个任务,该任务轮换VisualElement由 viewrotationlengtheasing参数和参数描述的指定任务。

public static System.Threading.Tasks.Task<bool> RotateToAsync(this Microsoft.Maui.Controls.VisualElement view, double rotation, uint length = 250, Microsoft.Maui.Easing? easing = default);
static member RotateToAsync : Microsoft.Maui.Controls.VisualElement * double * uint32 * Microsoft.Maui.Easing -> System.Threading.Tasks.Task<bool>
<Extension()>
Public Function RotateToAsync (view As VisualElement, rotation As Double, Optional length As UInteger = 250, Optional easing As Easing = Nothing) As Task(Of Boolean)

参数

view
VisualElement

此方法操作的视图。

rotation
Double

最终旋转值。

length
UInt32

动画转换的时间(以毫秒为单位)。 默认值为 250。

easing
Easing

用于动画的缓动函数。

返回

一 Task 个包含一个 Boolean 值,该值指示动画是否已取消。 true 指示已取消动画。 false 指示动画已运行到完成。

例外

当 为 view时null引发。

适用于

RotateToAsync(VisualElement, Double, UInt32, Easing, CancellationToken)

Source:
ViewExtensions.cs

返回一个任务,该任务轮换VisualElement由 viewrotationlengtheasing参数和参数描述的指定任务。

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task<bool> ^ RotateToAsync(Microsoft::Maui::Controls::VisualElement ^ view, double rotation, System::UInt32 length, Microsoft::Maui::Easing ^ easing, System::Threading::CancellationToken cancellationToken);
public static System.Threading.Tasks.Task<bool> RotateToAsync(this Microsoft.Maui.Controls.VisualElement view, double rotation, uint length, Microsoft.Maui.Easing? easing, System.Threading.CancellationToken cancellationToken);
static member RotateToAsync : Microsoft.Maui.Controls.VisualElement * double * uint32 * Microsoft.Maui.Easing * System.Threading.CancellationToken -> System.Threading.Tasks.Task<bool>
<Extension()>
Public Function RotateToAsync (view As VisualElement, rotation As Double, length As UInteger, easing As Easing, cancellationToken As CancellationToken) As Task(Of Boolean)

参数

view
VisualElement

此方法操作的视图。

rotation
Double

最终旋转值。

length
UInt32

动画转换的时间(以毫秒为单位)。 默认值为 250。

easing
Easing

用于动画的缓动函数。

cancellationToken
CancellationToken

用于取消动画的 A CancellationToken 。

返回

一 Task 个包含一个 Boolean 值,该值指示动画是否已取消。 true 指示已取消动画。 false 指示动画已运行到完成。

例外

当 为 view时null引发。

适用于