Author Topic: UIScrollView  (Read 198702 times)

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UIScrollView
« Reply #105 on: November 15, 2014, 04:32:43 PM »
Put it outside your scroll view. It shouldn't be a child of it.

Root
- Scroll View
-- Content 1
-- Content 2
-- Content 3
- UIWidget with UIDragPanel

ababab5

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 34
    • View Profile
Re: UIScrollView
« Reply #106 on: November 18, 2014, 06:20:35 AM »
Hi,

thanks for your quick reply.

I tried and try again but it doesn't work : I can't drag anymore..

Do I miss something ?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UIScrollView
« Reply #107 on: November 19, 2014, 04:15:14 PM »
Did you reference the scroll view? It won't be able to find it on its own unless you reference it.

ababab5

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 34
    • View Profile
Re: UIScrollView
« Reply #108 on: November 19, 2014, 08:25:23 PM »
Hi,

Thanks again for your reply.

What do you mean by "reference the scroll view" ?

Thanks

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UIScrollView
« Reply #109 on: November 20, 2014, 06:27:43 PM »
The "Scroll View" field on the UIDragScrollView...

ababab5

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 34
    • View Profile
Re: UIScrollView
« Reply #110 on: November 25, 2014, 07:53:53 PM »
Ok it takes time but it works. Thank you !

Velvety

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 1
    • View Profile
Re: UIScrollView
« Reply #111 on: January 02, 2015, 11:00:46 PM »
I've been searching the forums but haven't found a way to do this: I want to programmatically stop dragging a scrollview.  So far it seems like there is no easy way to do this. I may be able to "fake" ending a Press event or something, but I can't figure out how to reliably do that either.  Basically I want to be able to trigger the end of a press/drag on a scrollview so the user is forced to remove their finger and click/drag again if they want to start a new drag.  Is there a way to do this?  How might I cancel/end a drag that is in progress?  Thanks.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UIScrollView
« Reply #112 on: January 04, 2015, 07:45:37 AM »
UIScrollView.Press(false).

jandrefcosta

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 1
    • View Profile
Re: UIScrollView
« Reply #113 on: January 08, 2015, 08:30:20 AM »
Hello, I've some issues with the drag iOs style.
I want it works like native iOs scroll, with more movement than the regular configuration of the UIScrollView.
Let me explain. The movement of the drag elements is less soft, I need it more soft, more sliding, more duration when the finger release. Can I have that with the simple configurations on the panel, or I've edit the code behind the end movement ? The "Momentum and Spring" isn't enough end movement speed.

Thanks

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UIScrollView
« Reply #114 on: January 08, 2015, 09:12:17 AM »
You will need to edit the code.

alexh0101

  • Newbie
  • *
  • Thank You
  • -Given: 4
  • -Receive: 0
  • Posts: 30
    • View Profile
Re: UIScrollView
« Reply #115 on: January 23, 2015, 04:11:05 PM »
Hi,

How can I dynamically shift the scroll view to the n-th item of my grid?
I want the scrollview to show the n-th item when I press a button.

Can't find the property in question in UIScrollView's docs.

Thanks for your help

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UIScrollView
« Reply #116 on: January 23, 2015, 09:54:12 PM »
Use SpringPanel.Begin. Check UICenterOnClick for an example.

porchin

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 4
    • View Profile
Re: UIScrollView
« Reply #117 on: January 29, 2015, 01:14:13 AM »
Hi Aren,

I'm a newbie for NGUI here. I tried to use a scroll view and found that there is an unexpected behavior similar to nerophon post here, has this issue been fixed? if not how can I fix it?

Quote
Hi,

We love the CenterOnChild behavior and are using it to tween our scrollView. Sadly, however, if a user taps / clicks during the tween, the tween is canceled (or overridden?) and the scrollView stops where it is. It does not even snap back to the nearest child.

How can we prevent this behavior? We want the scrollView to NOT stop tweening due to a user press, but a user swipe should still override it with a new tween in the new swipe direction.

Many thanks!

Nick

From my expectation
 - pressing should stop tweening
 - release should continue tweening
 - swipe should override the tween

Thanks in advance :)
« Last Edit: January 29, 2015, 01:31:09 AM by porchin »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UIScrollView
« Reply #118 on: January 29, 2015, 01:27:04 PM »
If this is what I'm thinking of, it was fixed a long time ago. What version of NGUI are you using?

Plimsky

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 1
    • View Profile
Re: UIScrollView
« Reply #119 on: January 30, 2015, 04:01:17 AM »
Hi,

I have a specific case with a scroll view.
I would like to be able to scroll with the scroll wheel vertically AND scroll with a scroll bar horizontally.
I tried with a Unrestricted movement but it doesn't work.



Any ideas ?
Thanks for the help ! :-)