Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Make 'Split <direction>' context menu option work with directories #1190

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

jarle
Copy link

@jarle jarle commented Oct 5, 2017

Description of the Change

Currently, right clicking and selecting Split <direction> only works for single files; selecting Split <direction> on directories opens an empty pane, as explained in atom/atom#14201.

This PR makes the Split <direction> option open the contents of a directory in separate tabs within a single split pane instead. It does so by overriding the already existing context menu options Split <direction>(inherited from atom base), making it launch tree-view-specific commands.

Benefits

The context menu items will get a Split functionality for directories that makes sense, without adding any new items to the menu.

The implemented functionality can be useful in many scenarios. Example use case: opening all tests in a directory in the same right pane at once.

Possible Drawbacks

There is currently no warning when opening a directory containing many items.

Applicable Issues

Fixes #1189
Fixes atom/atom#14201 (for tree-view only)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants