Skip to content

Include headers/footers in EmptySource count so they show up when ItemsSource is null - #15979

Merged
PureWeen merged 2 commits into
mainfrom
fix-8934
Jul 10, 2023
Merged

PureWeen merged 2 commits into
mainfrom
fix-8934

Conversation

@hartez

@hartez hartez commented Jul 3, 2023 •

Copy link
Copy Markdown
Contributor

Description of Change

The EmptySource on Android is aware of the header and footer, but doesn't include them in the Count. Which means that the adapters don't know to display them when the ItemSource is null.

This change adjusts the reported Count from EmptySource to account for the presence of the header and footer.

This is an alternate (and more correct) solution to #15688.

Issues Fixed

Fixes #8934

@jsuarezruiz jsuarezruiz added the area-controls-collectionview CollectionView, CarouselView, IndicatorView label Jul 4, 2023

@PureWeen PureWeen left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add some additional tests that would cover the case(s) found by the legacy gallery?

@mattleibow

Copy link
Copy Markdown
Member

/rebase

@mattleibow

Copy link
Copy Markdown
Member

I see the less correct #15688 is merged... yuet no conflicts even since it touches the same files...

@mattleibow

mattleibow commented Jul 5, 2023 •

Copy link
Copy Markdown
Member

I see it was reverted actually: #15886

This is the issue that Shane was referring to: https://devdiv.visualstudio.com/DevDiv/_build/results?buildId=7979402&view=ms.vss-test-web.build-test-results-tab

Screenshot 2023-07-05 at 9 47 13 PM

@hartez

hartez commented Jul 5, 2023

Copy link
Copy Markdown
Contributor Author

Can we add some additional tests that would cover the case(s) found by the legacy gallery?

Aren't they covered by the legacy gallery tests?

@PureWeen

PureWeen commented Jul 7, 2023

Copy link
Copy Markdown
Member

Can we add some additional tests that would cover the case(s) found by the legacy gallery?

Aren't they covered by the legacy gallery tests?

We only run these tests on the main/feature branches. Ideally, we'll grow enough coverage inside our new appium tests/device tests (which run on every PR) that we can eventually just obsolete our legacy gallery tests once we feel that we've pretty much reached coverage parity.

@jsuarezruiz
jsuarezruiz requested a review from PureWeen July 10, 2023 14:53
@PureWeen
PureWeen merged commit b9f64e1 into main Jul 10, 2023
@PureWeen
PureWeen deleted the fix-8934 branch July 10, 2023 14:55
@github-actions github-actions Bot locked and limited conversation to collaborators Dec 8, 2023
@samhouts samhouts added the fixed-in-8.0.0-preview.7.8842 Look for this fix in 8.0.0-preview.7.8842! label Aug 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-controls-collectionview CollectionView, CarouselView, IndicatorView fixed-in-8.0.0-preview.7.8842 Look for this fix in 8.0.0-preview.7.8842!

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Collection View Header and Empty View not showing on Android when ItemSource is null

6 participants