Skip to content

Scrollview does not fire scroll events when background color is set #10431

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

Closed
JWiseCoder opened this issue Nov 6, 2023 · 2 comments · Fixed by #10432
Closed

Scrollview does not fire scroll events when background color is set #10431

JWiseCoder opened this issue Nov 6, 2023 · 2 comments · Fixed by #10432
Assignees
Labels

Comments

@JWiseCoder
Copy link

Referenced in #10368, scroll events in scroll views do not fire when that scroll view has a background set. I was able to reproduce this using the following test code:

<ScrollView
    orientation="horizontal"
    style="background-color: black;"
    (scroll)="onScroll($event)"
>
    <StackLayout
        orientation="horizontal"
        [height]="200">
        <StackLayout width="100" backgroundColor="red"></StackLayout>
        <StackLayout width="100" backgroundColor="blue"></StackLayout>
        <StackLayout width="100" backgroundColor="green"></StackLayout>
        <StackLayout width="100" backgroundColor="yellow"></StackLayout>
    </StackLayout>
</ScrollView>

With the background color style in place, the scroll event does not fire. If I remove it, the scroll event fires normally.

referenced in #10368 (comment)_

@CatchABus
Copy link
Contributor

@JWiseCoder Can you try changes in #10432? I'm pretty sure they fix your problem.

@JWiseCoder
Copy link
Author

@CatchABus Yes, that change fixes that issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants