public void OnPointerExit(PointerEventData eventData) { var cardModel = CardModel.GetPointerDrag(eventData); if (cardModel != null && cardModel.DropTarget == this) { cardModel.DropTarget = null; } }
public void OnPointerExit(PointerEventData eventData) { CardModel cardModel = CardModel.GetPointerDrag(eventData); if (cardModel != null && cardModel.PlaceHolderCardZone == this) { cardModel.PlaceHolderCardZone = null; } OnLayout?.Invoke(); }
public void OnPointerEnter(PointerEventData eventData) { CardModel cardModel = CardModel.GetPointerDrag(eventData); if (cardModel != null && (type != CardZoneType.Area || cardModel.transform.parent != transform) && !cardModel.IsStatic) { cardModel.PlaceHolderCardZone = this; } }
public void OnPointerEnter(PointerEventData eventData) { var cardModel = CardModel.GetPointerDrag(eventData); if (cardModel == null) { return; } cardModel.DropTarget = this; cardModel.HighlightMode = HighlightMode.Off; }
public void OnDrop(PointerEventData eventData) { var cardModel = CardModel.GetPointerDrag(eventData); if (cardModel == null || cardModel.ParentCardZone != null && cardModel.ParentCardZone.type != CardZoneType.Area || cardModel.PlaceHolderCardZone != null && cardModel.PlaceHolderCardZone.type != CardZoneType.Area) { return; } var drawerViewer = DropHandler as DrawerViewer; if (drawerViewer != null && Index != null) { drawerViewer.AddCard(cardModel.Value, Index ?? 0); } else { DropHandler.OnDrop(cardModel); } }
public void OnDrop(PointerEventData eventData) { CardModel cardModel = CardModel.GetPointerDrag(eventData); if (cardModel != null && cardModel.PlaceHolder == null && cardModel.ParentCardStack == null) dropHandler.OnDrop(cardModel); }
public void OnPointerEnter(PointerEventData eventData) { CardModel cardModel = CardModel.GetPointerDrag(eventData); if (cardModel != null) cardModel.DropTarget = this; }