ClickGestureRecognizer 类

定义

注意

The ClickGestureRecognizer is deprecated; please use TapGestureRecognizer or PointerGestureRecognizer instead.

单击手势的识别器。

public ref class ClickGestureRecognizer sealed : Microsoft::Maui::Controls::GestureRecognizer
[System.Obsolete("The ClickGestureRecognizer is deprecated; please use TapGestureRecognizer or PointerGestureRecognizer instead.")]
public sealed class ClickGestureRecognizer : Microsoft.Maui.Controls.GestureRecognizer
[<System.Obsolete("The ClickGestureRecognizer is deprecated; please use TapGestureRecognizer or PointerGestureRecognizer instead.")>]
type ClickGestureRecognizer = class
    inherit GestureRecognizer
Public NotInheritable Class ClickGestureRecognizer
Inherits GestureRecognizer
继承
属性

构造函数

ClickGestureRecognizer()
已过时.

使用默认值创建新 ClickGestureRecognizer

字段

ButtonsProperty
已过时.

Buttons可绑定属性。

CommandParameterProperty
已过时.

CommandParameter可绑定属性。

CommandProperty
已过时.

Command可绑定属性。

NumberOfClicksRequiredProperty
已过时.

NumberOfClicksRequired可绑定属性。

属性

AutomationId
已过时.

获取或设置允许自动化框架查找此元素并与其交互的值。

(继承自 Element)
BindingContext
已过时.

获取或设置一个 对象,该对象包含将由属于此 BindableObject的绑定属性所面向的属性。 这是一种可绑定属性。

(继承自 BindableObject)
Buttons
已过时.

获取或设置标志值,该值指示单击了哪个或哪些按钮。

ClassId
已过时.

获取或设置用于标识语义相似元素集合的值。

(继承自 Element)
Command
已过时.

获取或设置要执行的命令。

CommandParameter
已过时.

获取或设置命令参数。

Dispatcher
已过时.

获取创建此可绑定对象时可用的调度程序,否则会尝试查找最接近的可用调度程序 (可能是窗口/应用的) 。

(继承自 BindableObject)
EffectControlProvider
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
Effects
已过时.

获取或设置将在运行时应用于 元素的样式和属性。

(继承自 Element)
Handler
已过时.

获取或设置此元素的关联处理程序。

(继承自 Element)
Id
已过时.

获取一个值,该值可用于在应用程序的整个运行过程中唯一标识元素。

(继承自 Element)
LogicalChildren
已过时.

供 Microsoft.Maui.Controls 平台内部使用。

(继承自 Element)
NumberOfClicksRequired
已过时.

激活识别器所需的单击次数。

Parent
已过时.

获取或设置此元素的父 Element 元素。

(继承自 Element)
RealParent
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
StyleId
已过时.

获取或设置用于唯一地标识元素的用户定义的值。

(继承自 Element)

方法

AddLogicalChild(Element)
已过时.

将 添加到 Element 逻辑子级。

(继承自 Element)
ApplyBindings()
已过时.

将所有当前绑定应用于 BindingContext

(继承自 BindableObject)
ClearLogicalChildren()
已过时.

删除所有子 Element项。

(继承自 Element)
ClearValue(BindableProperty)
已过时.

清除以前为可绑定属性设置的任何值。

(继承自 BindableObject)
ClearValue(BindablePropertyKey)
已过时.

清除以前为其键标识的可绑定属性设置的任何值。

(继承自 BindableObject)
CoerceValue(BindableProperty)
已过时.

强制指定可绑定属性的值。 这是通过调用 BindableProperty.CoerceValueDelegate 指定的可绑定属性来完成的。

(继承自 BindableObject)
CoerceValue(BindablePropertyKey)
已过时.

强制指定可绑定属性的值。 这是通过调用 BindableProperty.CoerceValueDelegate 指定的可绑定属性来完成的。

(继承自 BindableObject)
EffectIsAttached(String)
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
FindByName(String)
已过时.

返回具有指定名称的元素。

(继承自 Element)
GetValue(BindableProperty)
已过时.

返回给定的可绑定属性中包含的值。

(继承自 BindableObject)
InsertLogicalChild(Int32, Element)
已过时.

将 插入 Element 到指定索引处的逻辑子级。

(继承自 Element)
IsSet(BindableProperty)
已过时.

确定是否存在可绑定属性以及是否设置了值。

(继承自 BindableObject)
OnBindingContextChanged()
已过时.

每当元素的绑定上下文发生更改时就会调用。 实现此方法可为此事件添加类处理。

(继承自 Element)
OnChildAdded(Element)
已过时.

引发 ChildAdded 事件。 实现此方法可为此事件添加类处理。

(继承自 Element)
OnChildRemoved(Element, Int32)
已过时.

引发 ChildRemoved 事件。 实现此方法以为此事件添加类处理

(继承自 Element)
OnHandlerChanged()
已过时.

在派生类中重写时,应引发 HandlerChanged 事件。

(继承自 Element)
OnHandlerChanging(HandlerChangingEventArgs)
已过时.

在派生类中重写时,应引发 HandlerChanging 事件。

(继承自 Element)
OnParentChanged()
已过时.

在派生类中重写时,应引发 ParentChanged 事件。

(继承自 Element)
OnParentChanging(ParentChangingEventArgs)
已过时.

在派生类中重写时,应引发 ParentChanging 事件。

(继承自 Element)
OnParentSet()
已过时.

引发 (内部) ParentSet 事件。 实现此方法以便在将元素添加到父元素时添加行为。

(继承自 Element)
OnPropertyChanged(String)
已过时.

更改绑定属性时调用的方法。

(继承自 Element)
OnPropertyChanging(String)
已过时.

引发 PropertyChanging 事件。

(继承自 BindableObject)
RemoveBinding(BindableProperty)
已过时.

从可绑定属性中删除以前设置的绑定。

(继承自 BindableObject)
RemoveDynamicResource(BindableProperty)
已过时.

删除以前设置的动态资源。

(继承自 Element)
RemoveLogicalChild(Element)
已过时.

从逻辑子级中删除特定 Element 项的第一个匹配项。

(继承自 Element)
SendClicked(View, ButtonsMask)
已过时.

运行单击命令(如存在),并在适当时调用单击事件处理程序。

SetBinding(BindableProperty, BindingBase)
已过时.

将绑定分配给可绑定属性。

(继承自 BindableObject)
SetDynamicResource(BindableProperty, String)
已过时.

BindableProperty使用提供的键设置要通过 DynamicResource 更新此元素的 属性。

(继承自 Element)
SetValue(BindableProperty, Object)
已过时.

设置指定的可绑定属性的值。

(继承自 BindableObject)
SetValue(BindablePropertyKey, Object)
已过时.

设置指定的可绑定属性的值。

(继承自 BindableObject)
SetValueFromRenderer(BindableProperty, Object)
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
SetValueFromRenderer(BindablePropertyKey, Object)
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
UnapplyBindings()
已过时.

从当前上下文中删除所有当前绑定。

(继承自 BindableObject)

事件

BindingContextChanged
已过时.

BindingContext 属性的值更改时发生。

(继承自 BindableObject)
ChildAdded
已过时.

每当将子元素添加到 元素时引发。

(继承自 Element)
ChildRemoved
已过时.

每当从元素中删除子元素时引发。

(继承自 Element)
Clicked
已过时.

单击手势的识别器。

DescendantAdded
已过时.

每当将子元素添加到元素的子树时引发。

(继承自 Element)
DescendantRemoved
已过时.

每当从元素子树中删除子元素时引发。

(继承自 Element)
HandlerChanged
已过时.

每当元素的处理程序发生更改时引发。

(继承自 Element)
HandlerChanging
已过时.

每当元素的处理程序开始更改时引发。

(继承自 Element)
ParentChanged
已过时.

每当元素的父级发生更改时引发。

(继承自 Element)
ParentChanging
已过时.

每当元素的 开始更改时引发。

(继承自 Element)
PropertyChanged
已过时.

在属性值更改时发生。

(继承自 BindableObject)
PropertyChanging
已过时.

在属性值更改时发生。

(继承自 BindableObject)

显式接口实现

IContextFlyoutElement.ContextFlyout
已过时.

ContextFlyout获取视图的 。 菜单浮出控件、菜单浮出控件子项和菜单浮出控件分隔符可以添加到上下文浮出控件。

(继承自 Element)
IDynamicResourceHandler.SetDynamicResource(BindableProperty, String)
已过时.

单击手势的识别器。

(继承自 BindableObject)
IEffectControlProvider.RegisterEffect(Effect)
已过时.

单击手势的识别器。

(继承自 Element)
IElement.Parent
已过时.

获取 元素的父级。

(继承自 Element)
IElementController.Descendants()
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
IElementController.LogicalChildren
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
IElementController.SetValueFromRenderer(BindableProperty, Object)
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
INameScope.RegisterName(String, Object)
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
INameScope.UnregisterName(String)
已过时.

供 .NET MAUI 内部使用。

(继承自 Element)
IToolTipElement.ToolTip
已过时.

表示一个小矩形弹出窗口,当用户将指针放在视图上时,该窗口显示视图用途的简短说明。

(继承自 Element)
IVisualTreeElement.GetVisualChildren()
已过时.

获取元素的可视子级的只读列表。

(继承自 Element)
IVisualTreeElement.GetVisualParent()
已过时.

获取元素的视觉对象父级。

(继承自 Element)

扩展方法

GetPropertyIfSet<T>(BindableObject, BindableProperty, T)
已过时.

单击手势的识别器。

SetAppTheme<T>(BindableObject, BindableProperty, T, T)
已过时.

单击手势的识别器。

SetAppThemeColor(BindableObject, BindableProperty, Color, Color)
已过时.

单击手势的识别器。

SetBinding(BindableObject, BindableProperty, String, BindingMode, IValueConverter, String)
已过时.

创建绑定并将其应用到属性。

FindByName<T>(Element, String)
已过时.

单击手势的识别器。

ToHandler(IElement, IMauiContext)
已过时.

单击手势的识别器。

ToPlatform(IElement, IMauiContext)
已过时.

单击手势的识别器。

GetVisualElementWindow(IVisualTreeElement)
已过时.

如果元素包含在一个元素中,则获取包含可视化树元素的窗口。

GetVisualTreeDescendants(IVisualTreeElement)
已过时.

获取子代的整个层次结构,作为给定可视树元素的子级列表。

GetVisualTreeElements(IVisualTreeElement, Point)
已过时.

获取基于给定点的可视化树元素的子元素的列表。

GetVisualTreeElements(IVisualTreeElement, Rect)
已过时.

获取基于矩形的可视化树元素子项的列表。

GetVisualTreeElements(IVisualTreeElement, Double, Double)
已过时.

获取基于给定 x、y 点的可视化树元素子级的列表。

GetVisualTreeElements(IVisualTreeElement, Double, Double, Double, Double)
已过时.

获取基于由坐标定义的矩形(以平台单位而不是像素指定的)的可视树元素子级的列表。

适用于