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

Prevent file-related menus to be visible for views with no file associated #9

Merged
merged 1 commit into from
Aug 6, 2017

Conversation

mandx
Copy link
Contributor

@mandx mandx commented Aug 5, 2017

sublime_plugin.WindowCommand.is_visible's paths argument is empty for new, unsaved views (like after hitting Ctrl/Cmd+N), so currently the menu will be visible, but crash when trying to manipulate an empty string as a path.

@braver braver merged commit 1b795ff into braver:master Aug 6, 2017
@braver
Copy link
Owner

braver commented Aug 6, 2017

Thanks for finding this oversight and fixing it! 🥇

@mandx
Copy link
Contributor Author

mandx commented Aug 6, 2017 via email

@braver
Copy link
Owner

braver commented Aug 6, 2017

Well, perhaps if paths > 1, you could ask for a target directory and move everything there? Anyway, if you’re up for it, that would be awesome.

@mandx mandx deleted the fix/handle-untargeted-views branch August 7, 2017 00:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants