Page MenuHome

Fix T62438: Unhide all doesn't set newly visible objects to selected
ClosedPublic

Authored by Dalai Felinto (dfelinto) on Mar 15 2019, 6:52 PM.

Details

Summary

The select option in the operator was never working because we were
trying to select an object considered unselectable (since it was hidden).

Besides, and this part is up to debate, the commit that brought H/Alt+H
back (rB0619f960c2999) deliberately had it not selecting the objects when
running from the outliner.

I think both changes should be made, as separate commits. But would like
to hear from the team. Specially because we also have an unhide all
exclusive to the outliner which unhides collections too, and should be
the only operator we need there (until we sync outliner and viewport
objects selection).

(T62438)

Diff Detail

Repository
rB Blender

Event Timeline

This change seems fine.

I don't have a strong opinion on Alt+H selecting unhidden objects when run from the outliner.

CC @Julien Kaspar (JulienKaspar) or @Pablo Vazquez (pablovazquez).

This revision is now accepted and ready to land.Mar 15 2019, 8:01 PM
This revision was automatically updated to reflect the committed changes.

Thanks @Brecht Van Lommel (brecht), committed as:

As mentioned in the commits (and here) if we agree on I gladly change how OUTLINER_OT_unhide_all works.

@Dalai Felinto (dfelinto) I think we had this conversation before during the code quest. Here's my feedback on the topic:

All the time in edit mode I select and hide geometry as a quick way of saving a selection for later without it being in the way of me selecting even more. Once I have everything selected that I need I hit Alt + H and I have my full selection. Anything that will be hidden was first selected so it makes sense when it's shown again that it is still selected. And this behaviour is extremely useful, even in object mode. It's even possible in other modes like pose mode.
I don't like the behaviour that an object that is hidden and then show again becomes stays deselected. It's inconsistent with the other modes and makes the use case of what I described above much harder.
The workaround for me with the behaviour of this commit would be to temporarily create a collection to link the selected objects into and hiding the collection ... or just never hide something again if I want to keep it selected.
This is extremely slow in comparison though.

Keeping it the way it worked before this commit and how it worked in 2.79 is just plain more useful. This commit just gives the user no advantage whatsoever so why change it?

Hi @Julien Kaspar (JulienKaspar) I clearly expressed myself poorly. I agree with you and this is the exact behaviour that I implemented. But to be sure, please try a build after said commits, to see if this is what you had in mind.

@Dalai Felinto (dfelinto) Ah ok. The latest build I downloaded at home clearly wasn't the most up to date. As far as I can see it's now working just as I expected it to.