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

[Windows] Fixed the exception when using CarouselView PeekAreaInsets Property in OnSizeAllocated method #26865

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

Vignesh-SF3580
Copy link
Contributor

Issue Detail

A layout cycle exception occurs on Windows when using PeekAreaInsets in the OnSizeAllocated method.

Root Cause

The InvalidateMeasure method was being called individually on each ItemContentControl within ListViewBase. This led to multiple redundant measure invalidations, causing an infinite loop and triggering a layout cycle exception.

Description of Change

The individual InvalidateMeasure calls on each ItemContentControl were replaced with a single InvalidateMeasure call on the parent ListViewBase, ensuring efficient layout recalculations and preventing layout cycle issues.

Tested the behaviour in the following platforms

  • Android
  • Windows
  • iOS
  • Mac

Issues Fixed

Fixes #26822

Screenshots

Before
image

After
image

@dotnet-policy-service dotnet-policy-service bot added the community ✨ Community Contribution label Dec 30, 2024
Copy link
Contributor

Hey there @Vignesh-SF3580! Thank you so much for your PR! Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

@karthikraja-arumugam karthikraja-arumugam added the partner/syncfusion Issues / PR's with Syncfusion collaboration label Dec 31, 2024
@Vignesh-SF3580 Vignesh-SF3580 marked this pull request as ready for review January 2, 2025 13:05
@Vignesh-SF3580 Vignesh-SF3580 requested a review from a team as a code owner January 2, 2025 13:05
@Redth
Copy link
Member

Redth commented Jan 2, 2025

/azp run

Copy link

Azure Pipelines successfully started running 3 pipeline(s).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community ✨ Community Contribution partner/syncfusion Issues / PR's with Syncfusion collaboration
Projects
None yet
3 participants