nokola
Topic Author
Posts: 186
Joined: 10 Mar 2015, 05:29

How to stop manipulation inertia in ListBox/ScrollViewer?

03 Feb 2019, 23:03

I have a ListBox with list of fonts that the user can scroll through and a separate control for paging through the fonts.
pagescroll.png
pagescroll.png (28.25 KiB) Viewed 153 times
When the user switches to another page, I replace the contents of the ListBox with another set of fonts and scroll to position 0.
There are situations when a user starts scrolling the ScrollViewer using touch on phone, then realizes they want to switch to another page and quickly presses the page switch buttons.

When the above happens, the ListBox keeps scrolling even though its contents are now different.
How do I cancel the inertia velocity for the ListBox to "stop it in its tracks"? :)

Thanks!
 
User avatar
jsantos
Site Admin
Posts: 2468
Joined: 20 Jan 2012, 17:18
Contact:

Re: How to stop manipulation inertia in ListBox/ScrollViewer?

05 Feb 2019, 21:01

It seems we have something missing here. How would you achieve that in WPF? Could you please report a ticket about it and follow the discussion there?

Thanks!
 
User avatar
jsantos
Site Admin
Posts: 2468
Joined: 20 Jan 2012, 17:18
Contact:

Re: How to stop manipulation inertia in ListBox/ScrollViewer?

05 Feb 2019, 21:01

 
nokola
Topic Author
Posts: 186
Joined: 10 Mar 2015, 05:29

Re: How to stop manipulation inertia in ListBox/ScrollViewer?

05 Feb 2019, 23:17

I would assume it "just works" when I call ScrollToHorizontalIndex()

There's no scenario I can think of where ScrollTo...() would have the control keep scrolling based on random previous user action.

Opened https://www.noesisengine.com/bugs/view.php?id=1405

Who is online

Users browsing this forum: No registered users and 3 guests