Collapse all directories even when nothing is selected #1287
Conversation
Looks good to me. Can you please write some tests to cover this updated behavior? |
@50Wliu sure thing, happy to. How can I run the tests on my local machine? Looking through the CONTRIBUTING file and the |
You can run them using (Also, ignore the Appveyor failure. We have a few known flakes on it.) |
2c0a3e7
to
d6a4099
@50Wliu, updated! |
Thank you! |
Thanks for merging @50Wliu! When is this expected to work into a release of Atom/what can I follow along with? |
I'll be cutting a new release of tree-view today, which should make its way into Atom 1.34.0. |
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.
Requirements
Description of the Change
This pull request updates the
collapseDirectory
method so that when theallDirectories
parameter is set totrue
, all directories will be closed, even if nothing is selected in the tree view. Previously, if nothing was selected in the tree view, this method would return before collapsing anything (even ifallDirectories
was set totrue
.Alternate Designs
N/A
Benefits
Triggering collapse-all will always collapse all directories, even if an item isn't currently selected in the tree-view.
Possible Drawbacks
None that I'm aware of.
Applicable Issues
None that I'm aware of.