Author Topic: Is "UIScrollView.isDragging" working when Smooth Drag Start is off?  (Read 1877 times)

t_n

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 9
    • View Profile
Hi,

I'm wondering if "UIScrollView.isDragging" is working when Smooth Drag Start is off.

I think it's not, because

  1. mDragStarted = true;

is inside

  1. smoothDragStart && !mDragStarted

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Is "UIScrollView.isDragging" working when Smooth Drag Start is off?
« Reply #1 on: July 15, 2014, 08:06:23 PM »
Add this code in the UIScrollView.Press function inside the "if (pressed)" section:
  1.                                 if (!smoothDragStart)
  2.                                 {
  3.                                         mDragStarted = true;
  4.                                         mDragStartOffset = Vector2.zero;
  5.                                         if (onDragStarted != null) onDragStarted();
  6.                                 }