public Droppable(OnDragListener listener, View view)
            {
                this.Listener = listener;
                this.View = view;

                mLastEventHit = false;
            }
Пример #2
0
 // Use this for initialization
 void Start()
 {
     if (gameObject.GetComponent<OnDragListener> () != null) {
         onDragListener = (OnDragListener)gameObject.GetComponent<OnDragListener> ();
     } else {
         throw new System.NotImplementedException ("The gameObject has to component that implements OnDragListener");
     }
 }
 public void RemoveDragListener(OnDragListener listener)
 {
     mDroppables.Remove(listener);
 }
 public void AddDragListener(View view, OnDragListener listener)
 {
     mDroppables.Add(listener, new Droppable(listener, view));
 }