public void Stop() { if (pointerId != PanelManager.NON_EXISTING_TOUCH) { if (!panel.IsDocked) { ((UnanchoredPanelGroup)panel.Group).RestrictPanelToBounds(panel); } pointerId = PanelManager.NON_EXISTING_TOUCH; #if ENABLE_CURSOR_MANAGEMENT PanelCursorHandler.OnEndResize(); #endif } }
public void OnBeginDrag(PointerEventData eventData) { // Cancel drag event if panel is already being resized by another pointer // or panel is anchored to a fixed anchor in that direction if (!panel.CanResizeInDirection(direction)) { eventData.pointerDrag = null; return; } pointerId = eventData.pointerId; secondDirection = GetSecondDirection(eventData.pressPosition); #if ENABLE_CURSOR_MANAGEMENT PanelCursorHandler.OnBeginResize(direction, secondDirection); #endif }
public void OnEndDrag(PointerEventData eventData) { if (eventData.pointerId != pointerId) { return; } if (!panel.IsDocked) { ((UnanchoredPanelGroup)panel.Group).RestrictPanelToBounds(panel); } pointerId = PanelManager.NON_EXISTING_TOUCH; #if ENABLE_CURSOR_MANAGEMENT PanelCursorHandler.OnEndResize(); #endif }
public void OnPointerExit(PointerEventData eventData) { PanelCursorHandler.OnPointerExit(this); }
public void OnPointerEnter(PointerEventData eventData) { PanelCursorHandler.OnPointerEnter(this, eventData); }
private void Awake() { instance = this; }