当前位置: 首页>>代码示例>>C#>>正文


C# Gesture.GetInstanceID方法代码示例

本文整理汇总了C#中TouchScript.Gestures.Gesture.GetInstanceID方法的典型用法代码示例。如果您正苦于以下问题:C# Gesture.GetInstanceID方法的具体用法?C# Gesture.GetInstanceID怎么用?C# Gesture.GetInstanceID使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在TouchScript.Gestures.Gesture的用法示例。


在下文中一共展示了Gesture.GetInstanceID方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: removeFriendlyGestureId

 // Gets also called by the custom inspector.
 private void removeFriendlyGestureId(Gesture gesture)
 {
     friendlyGestureIds.Remove(gesture.GetInstanceID());
 }
开发者ID:sloopidoopi,项目名称:TouchScript,代码行数:5,代码来源:Gesture.cs

示例2: CanPreventGesture

 /// <summary>
 /// Determines whether this instance can prevent the specified gesture.
 /// </summary>
 /// <param name="gesture">The gesture.</param>
 /// <returns>
 ///   <c>true</c> if this instance can prevent the specified gesture; otherwise, <c>false</c>.
 /// </returns>
 public virtual bool CanPreventGesture(Gesture gesture)
 {
     if (Delegate == null)
     {
         if (gesture.CanBePreventedByGesture(this))
         {
             if (shouldRecognizeWith.Contains(gesture.GetInstanceID()))
             {
                 return false;
             } else
             {
                 return true;
             }
         } else
         {
             return false;
         }
     } else
     {
         return !Delegate.ShouldRecognizeSimultaneously(this, gesture);
     }
 }
开发者ID:NormLi,项目名称:TouchScript,代码行数:29,代码来源:Gesture.cs

示例3: addFriendlyGestureId

 // Gets also called by the custom inspector.
 private void addFriendlyGestureId(Gesture gesture)
 {
     var id = gesture.GetInstanceID();
     if (!friendlyGestureIds.Contains(id)) friendlyGestureIds.Add(id);
 }
开发者ID:sloopidoopi,项目名称:TouchScript,代码行数:6,代码来源:Gesture.cs

示例4: IsFriendly

 /// <summary>
 /// Checks if a gesture is friendly with this gesture.
 /// </summary>
 /// <param name="gesture">A gesture to check.</param>
 /// <returns>True if gestures are friendly; false otherwise.</returns>
 public bool IsFriendly(Gesture gesture)
 {
     return friendlyGestureIds.Contains(gesture.GetInstanceID());
 }
开发者ID:sloopidoopi,项目名称:TouchScript,代码行数:9,代码来源:Gesture.cs

示例5: UnregisterFriendlyGesture

 internal void UnregisterFriendlyGesture(Gesture gesture)
 {
     friendlyGestureIds.Remove(gesture.GetInstanceID());
 }
开发者ID:keangame,项目名称:TouchScript,代码行数:4,代码来源:Gesture.cs

示例6: RegisterFriendlyGesture

        internal void RegisterFriendlyGesture(Gesture gesture)
        {
            if (gesture == this || friendlyGestureIds.Contains(gesture.GetInstanceID())) return;

            friendlyGestureIds.Add(gesture.GetInstanceID());
        }
开发者ID:keangame,项目名称:TouchScript,代码行数:6,代码来源:Gesture.cs

示例7: unregisterFriendlyGesture

        private void unregisterFriendlyGesture(Gesture gesture)
        {
            if (gesture == null || gesture == this || friendlyGestureIds.Contains(gesture.GetInstanceID())) return;

            friendlyGestureIds.Remove(gesture.GetInstanceID());
        }
开发者ID:ksmylz,项目名称:TouchScript,代码行数:6,代码来源:Gesture.cs

示例8:

        {
            get; private set;
        }

        #endregion Properties

        #region Methods

        /// <summary>
        /// Determines whether this instance can prevent the specified gesture.
        /// </summary>
        /// <param name="gesture">The gesture.</param>
        /// <returns>
开发者ID:gijs,项目名称:TouchScript,代码行数:13,代码来源:Gesture.cs

示例9: ShouldReceiveTouch

        /// <param name="touch">The touch.</param>
        /// <returns><c>true</c> if this touch should be received by the gesture; otherwise, <c>false</c>.</returns>
        public virtual bool ShouldReceiveTouch(TouchPoint touch)
        {
            if (Delegate == null) return true;
            return Delegate.ShouldReceiveTouch(this, touch);
        }

        /// <summary>
        /// Tells that the gesture should (or shouldn't) work simultaneously with this gesture.
        /// </summary>
        /// <param name="gesture">The gesture.</param>
        /// <param name="value">if set to <c>true</c> allows simultaneous recognition.</param>
        public void ShouldRecognizeSimultaneouslyWith(Gesture gesture, bool value = true)
        {
            if (gesture == this) return;
开发者ID:gijs,项目名称:TouchScript,代码行数:16,代码来源:Gesture.cs


注:本文中的TouchScript.Gestures.Gesture.GetInstanceID方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。