示例#1
0
 public virtual void DoClick(LComponent comp)
 {
     if (!_enabled)
     {
         return;
     }
     if (_allTouch != null)
     {
         _allTouch.On(SysTouch.GetX(), SysTouch.GetY());
     }
     if (clicks != null)
     {
         for (int i = 0, size = clicks.size; i < size; i++)
         {
             ClickListener listener = clicks.Get(i);
             if (listener != null && listener != this)
             {
                 listener.DoClick(comp);
             }
         }
     }
 }
示例#2
0
 public bool IsUp()
 {
     return(SysTouch.IsUp() &&
            (previousState == LTouchLocationState.Pressed || previousState == LTouchLocationState.Dragged) &&
            (state == LTouchLocationState.Released));
 }
示例#3
0
 public bool IsDown()
 {
     return(SysTouch.IsDown() &&
            (previousState == LTouchLocationState.Pressed && (state == LTouchLocationState.Pressed || state == LTouchLocationState.Dragged)));
 }
示例#4
0
 public bool IsDrag()
 {
     return(SysTouch.IsDrag() &&
            (previousState == LTouchLocationState.Dragged && state == LTouchLocationState.Dragged));
 }