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

SelectionModel: Fix for missing SelectionChanged event raise #2359

Conversation

Felix-Dev
Copy link
Contributor

Description

Fixes the missing SelectionChanged event raise when switching from SelectionMode Multiple to Single while more than one item is currently selected.

Also added two API tests:

  • One test to cover event raising. This is the API test to cover this specific issue.
  • One test to test if the selection is still correct after switching from Multiple to Single selection mode. This test helps in keeping the event test above focused solely on event raise testing.

Motivation and Context

Fixes #2358.

How Has This Been Tested?

Added API test.

@msft-github-bot msft-github-bot added the needs-triage Issue needs to be triaged by the area owners label Apr 30, 2020
@ranjeshj ranjeshj added area-ItemsRepeater team-Controls Issue for the Controls team and removed needs-triage Issue needs to be triaged by the area owners labels Apr 30, 2020
dev/Repeater/APITests/SelectionModelTests.cs Outdated Show resolved Hide resolved
@ranjeshj
Copy link
Contributor

ranjeshj commented May 4, 2020

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@Felix-Dev
Copy link
Contributor Author

I don't think the failing test is because of this PR, is it? 🤔

@ranjeshj
Copy link
Contributor

ranjeshj commented May 5, 2020

I don't think the failing test is because of this PR, is it? 🤔

Seems unrelated. Trying again.

@ranjeshj ranjeshj merged commit 6ab6d30 into microsoft:master May 6, 2020
@Felix-Dev Felix-Dev deleted the user/Felix-Dev/selectionmodel-selectionchanged-issue branch May 6, 2020 19:58
@ghost
Copy link

ghost commented Dec 4, 2020

🎉Microsoft.UI.Xaml v2.5.0 has been released which incorporates this pull request.:tada:

Handy links:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-ItemsRepeater team-Controls Issue for the Controls team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SelectionModel: SelectionChanged event not raised when switching SelectionMode
4 participants