When invoking 'generate overrides' respect teh last user action wrt select-all/deselect-all#52992
Merged
CyrusNajmabadi merged 3 commits intodotnet:mainfrom Apr 29, 2021
Merged
Conversation
…elect-all/deselect-all
ryzngard
reviewed
Apr 28, 2021
|
|
||
| return SpecializedCollections.SingletonEnumerable( | ||
| new ApplyChangesOperation(newDocument.Project.Solution)); | ||
| return new CodeActionOperation[] |
Contributor
There was a problem hiding this comment.
Can you add a unit test showing the select all/deselect all option saving?
ryzngard
approved these changes
Apr 28, 2021
Contributor
Author
|
Yup. I can try to find a way to test taht. Non-trivial as it's practically entirely at the UI layer :-/ |
c3506ca to
e14e8ff
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #47806
The general idea is this: eery time the user chooses 'select all' or 'deselect all' in the dialog, we use that as hint to the next opening of hte dialog to decide if we should start with all items selected or deselected.
This means that if someone is in a mode where they're overrriding all/most of hte members (for example, when creating types that suclass Object and override Equals/GetHashCode/ToString) that they continue selecting all members. However, if they're in a mode where they're overriding a small set of items (for example, object hierarchies with tons of virtual members) they can choose to 'deselect all' and then in the future only have to select the items they care about, isntead of deselecting the items they don't care about.
This is a partial mitigation for #47806. Other things we'd likely want to do are allow for a filter-box to filter down to a smaller set of symbols by name that hte user cares about, as well as allowing symbols to be grouped by their containing type to make browsing easier.