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

Add API method to set the active view in a group (without switching focus to it) #1320

Open
mattst opened this issue Aug 9, 2016 · 2 comments

Comments

@mattst
Copy link

mattst commented Aug 9, 2016

I would like a method added to the API to set the active view in any group.

The Window class currently contains the active_view_in_group(group) method which returns the active view in the specified group.

A companion method for this would be useful: set_active_view_in_group(group, view) to allow the active view in any group to be changed. At the moment the active view in a group can only be changed by using focus_view(view) which switches the focus to that view. In some circumstances you could use that and then immediately switch the focus back, but not, for example, from the on_highlighted method of the show_quick_panel() panel without that panel losing focus.

This would be useful because it would give plugin developers greater control of what is displayed in the window's groups.

Thanks.

@keith-hall
Copy link
Collaborator

You may also want to cross post this at the API Suggestions thread on the forums

@mnieber
Copy link

mnieber commented Dec 12, 2018

This feature would make the following work-around obsolete: https://stackoverflow.com/questions/30626639/how-to-restore-focus-to-quick-panel-after-focusing-some-other-group-to-open-a-fi

I'm mentioning this for people who need the work-around, and also as a suggestion to update the SO item once the feature is there.

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

No branches or pull requests

3 participants