fbritop Well-Known Member Licensed User Longtime User Apr 29, 2019 #1 Every time I do a CustomListView resize (either by SetLayoutAnimated,height or basePanel), it automatically scrolls to the top of the list. Is there a way to avoid this behavior? xCustomListView v1.71 Thanks FBP Last edited: Apr 29, 2019
Every time I do a CustomListView resize (either by SetLayoutAnimated,height or basePanel), it automatically scrolls to the top of the list. Is there a way to avoid this behavior? xCustomListView v1.71 Thanks FBP
Erel B4X founder Staff member Licensed User Longtime User Apr 30, 2019 #2 You can do something like: Code: Copy Dim FirstVisible As Int = CustomListView1.FirstVisibleIndex CustomListView1.AsView.SetLayoutAnimated(0, 0, 0, Page1.RootPanel.Width, 100dip) Sleep(100) CustomListView1.JumpToItem(FirstVisible) Upvote 0
You can do something like: Code: Copy Dim FirstVisible As Int = CustomListView1.FirstVisibleIndex CustomListView1.AsView.SetLayoutAnimated(0, 0, 0, Page1.RootPanel.Width, 100dip) Sleep(100) CustomListView1.JumpToItem(FirstVisible)
fbritop Well-Known Member Licensed User Longtime User Apr 30, 2019 #3 Thanks @Erel I have already tried that one, but the client discard it as it was not an elgant solution (I think the same). IS there a special reason for this to happen in iOS?. I cannot debug it as it uses the library and it wont compile with the class (xCustomListView) in order to put some watches. Upvote 0
Thanks @Erel I have already tried that one, but the client discard it as it was not an elgant solution (I think the same). IS there a special reason for this to happen in iOS?. I cannot debug it as it uses the library and it wont compile with the class (xCustomListView) in order to put some watches.
Erel B4X founder Staff member Licensed User Longtime User Apr 30, 2019 #4 I haven't deeply investigated it. This seems like the native behavior of ScrollView when it is resized. Upvote 0
I haven't deeply investigated it. This seems like the native behavior of ScrollView when it is resized.