public virtual void UpClick(LComponent comp, float x, float y) { if (!_enabled) { return; } if (_downClick) { if (_upTouch != null) { _upTouch.On(x, y); } if (clicks != null) { for (int i = 0, size = clicks.size; i < size; i++) { ClickListener listener = clicks.Get(i); if (listener != null && listener != this) { listener.UpClick(comp, x, y); } } } _downClick = false; } }
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); } } } }