-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Adding SelectionMode to TabStrip #18109
base: master
Are you sure you want to change the base?
Adding SelectionMode to TabStrip #18109
Conversation
Should I add the same key behaviors as the ListBox? (e.g. Moving with Navigation-Keys or Control to select specific items) |
You can test this PR using the following package version. |
Assert.Equal(-1, target.SelectedIndex); | ||
Assert.Same(null, target.SelectedItem); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unfortunately, we can't change default behavior.
TabStrip.SelectionMode default should be changed to match old behavior, even if it's different from ListBox.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Likely, you only need to revert SelectionModeProperty.OverrideDefaultValue<TabStrip>(SelectionMode.AlwaysSelected);
line.
What does the pull request do?
This implements #17969. In essence, it exposes the
SelectionMode
property to make the selection mode configurable and it disables the behavior that the first item is always selected. This mimics the behavior of theListBox
.What is the current behavior?
First item is always selected and you can't change the SelectionMode.
What is the updated/expected behavior with this PR?
I updated the ControlCatalog to allow to "play" with the settings:
Checklist
Fixed issues
Implements #17969