Share via


UIView.ExclusiveTouch 屬性

定義

限制事件傳遞至此檢視。

[ObjCRuntime.Unavailable(ObjCRuntime.PlatformName.TvOS, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual bool ExclusiveTouch { [Foundation.Export("isExclusiveTouch")] [ObjCRuntime.Unavailable(ObjCRuntime.PlatformName.TvOS, ObjCRuntime.PlatformArchitecture.All, null)] get; [Foundation.Export("setExclusiveTouch:")] [ObjCRuntime.Unavailable(ObjCRuntime.PlatformName.TvOS, ObjCRuntime.PlatformArchitecture.All, null)] set; }
member this.ExclusiveTouch : bool with get, set

屬性值

預設值為 false。

屬性

備註

設定此屬性時,如果此檢視開始追蹤觸控,則視窗中沒有其他檢視會收到這些事件。 此外,將此屬性設定為 true 的檢視將不會接收與視窗中其他檢視相關聯的任何事件。

如果手指觸碰到已設定此屬性的檢視,則只有在視窗中沒有其他檢視追蹤手指時,才會傳遞事件。 如果手指觸碰非獨佔視窗,則只有在沒有追蹤手指的獨佔檢視時,才會傳遞事件。

適用於