How to get selection objects list in outliner?

In 2.7 this was easily accessible through so-called object bases, which there no longer are no entry points to from python afaik. However, one way to determine the objects is by temporarily unhiding things and cross reference the selections.

Made a quick addon out of it. The hotkey is set to J to avoid colliding with the vanilla operator, but can easily be changed.

Updated 7/19/21:

toggle_hide.py
Right-click > Save As

2 Likes