Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ScrollView.ScrollToAsync(x, y false) returns before scroll is completed (when #7295

Closed
philipag opened this issue May 18, 2022 · 4 comments · Fixed by #15984
Closed

ScrollView.ScrollToAsync(x, y false) returns before scroll is completed (when #7295

philipag opened this issue May 18, 2022 · 4 comments · Fixed by #15984
Assignees
Labels
area-controls-scrollview ScrollView fixed-in-7.0.96 Look for this fix in 7.0.96 SR8! fixed-in-7.0.100 fixed-in-7.0.101 fixed-in-8.0.0-rc.1.9171 Look for this fix in 8.0.0-rc.1.9171 p/1 Work that is important, and has been scheduled for release in this or an upcoming sprint partner/cat 😻 this is an issue that impacts one of our partners or a customer our advisory team is engaged with platform/android 🤖 platform/iOS 🍎 s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage t/bug Something isn't working
Milestone

Comments

@philipag
Copy link

Description

As shown in the repro sample, ScrollView.ScrollToAsync(,,false) returns immediately and before the actual scroll is completed.
When scrolling with animation enabled things appear to work better and the await completes at least very close to the end of the scroll (not sure it's the actual end either).

Steps to Reproduce

  1. Compile and run the repro sample on Android and iOS
  2. On both platforms, the scroll change has no effect when the second breakpoint hits (after calling ScrollToAsync).
  3. Only when continuing to run does the scroll position actually change.
  4. I think even with animation enabled the await completes a little bit before the animated scroll completes.

The await should only complete after the scroll itself is completed. This causes various issue including breaking code when trying to chain scrolls.

If the current behavior is intended then the documentation should clearly state the limitation/bug since the current behavior is unexpected and problematic.

layoutbug16.zip

Version with bug

Release Candidate 3 (current)

Last version that worked well

Unknown/Other

Affected platforms

iOS, Android, I was not able test on other platforms

Affected platform versions

Android 11, iOS 15

Did you find any workaround?

Add "await Task.Delay{100}" after the scroll but this is a terrible kludge.

Relevant log output

No response

@philipag philipag added s/needs-verification Indicates that this issue needs initial verification before further triage will happen t/bug Something isn't working labels May 18, 2022
@Eilon Eilon added the area-layout StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter label May 18, 2022
@v-longmin v-longmin added s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage and removed s/needs-verification Indicates that this issue needs initial verification before further triage will happen labels May 19, 2022
@v-longmin
Copy link

Verified repro on VS 17.3.0 Preview 1.0 [32427.505.main]. Repro project:
layoutbug16.zip

@PureWeen PureWeen added this to the 6.0-servicing milestone Jun 28, 2022
@Redth Redth modified the milestones: 6.0-servicing, Backlog Aug 30, 2022
@ghost
Copy link

ghost commented Aug 30, 2022

We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process.

@hartez hartez added the area-controls-scrollview ScrollView label Oct 9, 2022
@samhouts samhouts removed s/verified Verified / Reproducible Issue ready for Engineering Triage s/triaged Issue has been reviewed labels Apr 5, 2023
@Zhanglirong-Winnie Zhanglirong-Winnie added s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage labels May 9, 2023
@Zhanglirong-Winnie
Copy link

Verified this issue with Visual Studio Enterprise 17.6.0 Preview 5.0. Can repro on Android platform with above project.
layoutbug16.zip
ScrollView

@mikeparker104 mikeparker104 added the partner/cat 😻 this is an issue that impacts one of our partners or a customer our advisory team is engaged with label Jun 27, 2023
@samhouts samhouts added the p/1 Work that is important, and has been scheduled for release in this or an upcoming sprint label Jun 28, 2023
@jsuarezruiz jsuarezruiz self-assigned this Jul 3, 2023
@jsuarezruiz jsuarezruiz moved this to In Progress in MAUI SDK Ongoing Jul 3, 2023
@jsuarezruiz
Copy link
Contributor

The issue will be fixed by https://github.com/dotnet/maui/tree/fix-7295

@github-project-automation github-project-automation bot moved this from In Progress to Done in MAUI SDK Ongoing Aug 21, 2023
@samhouts samhouts added the fixed-in-8.0.0-rc.1.9171 Look for this fix in 8.0.0-rc.1.9171 label Sep 12, 2023
@samhouts samhouts added the fixed-in-7.0.96 Look for this fix in 7.0.96 SR8! label Oct 10, 2023
@ghost ghost locked as resolved and limited conversation to collaborators Nov 9, 2023
@Eilon Eilon removed the area-layout StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter label May 14, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-controls-scrollview ScrollView fixed-in-7.0.96 Look for this fix in 7.0.96 SR8! fixed-in-7.0.100 fixed-in-7.0.101 fixed-in-8.0.0-rc.1.9171 Look for this fix in 8.0.0-rc.1.9171 p/1 Work that is important, and has been scheduled for release in this or an upcoming sprint partner/cat 😻 this is an issue that impacts one of our partners or a customer our advisory team is engaged with platform/android 🤖 platform/iOS 🍎 s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage t/bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.