Assets/Watson/Scripts/Utilities/TouchEventManager.cs
/// <summary>
/// To check equality of the same Touch Event Data
/// </summary>
/// <param name="obj">Object to check equality</param>
/// <returns>True if objects are equal</returns>
To check equality of the same Touch Event Data
To check equality of the same Touch Event Data
public override bool Equals(object obj)
            {
                bool isEqual = false;
                TouchEventData touchEventData = obj as TouchEventData;
                if (touchEventData != null)
                {
                    isEqual =
                        (touchEventData.Collider == this.Collider &&
                            touchEventData.Collider2D == this.Collider2D &&
                            touchEventData.RectTransform == this.RectTransform &&
                            touchEventData.GameObjectAttached == this.GameObjectAttached &&
                            touchEventData.IsInside == this.IsInside &&
                            touchEventData.SortingLayer == this.SortingLayer &&
                            touchEventData.DragCallback == this.DragCallback &&
                            touchEventData.TapCallback == this.TapCallback);
                }
                else
                {
                    isEqual = base.Equals(obj);
                }
                return isEqual;
            }
public override bool Equals ( object obj ) { bool isEqual = false ; TouchEventData touchEventData = obj as TouchEventData ; if ( touchEventData != null ) { isEqual = ( touchEventData . Collider == this . Collider && touchEventData . Collider2D == this . Collider2D && touchEventData . RectTransform == this . RectTransform && touchEventData . GameObjectAttached == this . GameObjectAttached && touchEventData . IsInside == this . IsInside && touchEventData . SortingLayer == this . SortingLayer && touchEventData . DragCallback == this . DragCallback && touchEventData . TapCallback == this . TapCallback ) ; } else { isEqual = base . Equals ( obj ) ; } return isEqual ; }
To check equality of the same Touch Event Data
To check equality of the same Touch Event Data
True if objects are equal
True if objects are equal
obj
object
Object to check equality
Object to check equality