Page MenuHome

Don't select when unhiding

Authored by John Roper (johnroper100) on Jul 11 2015, 11:25 PM.



This fixes the issue where the users was not able to choose if the objects was selected when un-hidden.

Diff Detail

Event Timeline

Thanks to some help from kaito, Severin, and scorpion81, I have finished the patch. It works now.

Julian Eisel (Severin) requested changes to this revision.

Main issue here is that object_hide_view_set_exec shouldn't be touched at all. All the logic should happen in the unhide operator.

Also, in T45230 it was requested to do that on all unhide operators, not only for objects, but we can add that after you got it working with objects. Just to make you aware of it.


Although this shouldn't be needed at all (see my main concern raised), just a general note on this:
Using local flags can be troublesome, this is a good example where this shouldn't be used. The base->flag bit for HIDE_SELECT is already used for BA_WAS_SEL ( (1 << 1) == 2 ) and should better not be touched.
In this case you could just re-use BA_TEMP_TAG, but if you really needed a new flag you should add it to DNA_object_types.h.


Again, would be fixed by addressing main concern, so JFYI: This doesn't work if unselected is true, objects are always revealed without being selected then.


This shouldn't be done here, it should be done in the unhide operator instead. Setting an option for an operation that wasn't executed yet doesn't fit into Blender UX design.

This revision now requires changes to proceed.Jul 16 2015, 1:06 AM
John Roper (johnroper100) edited edge metadata.
John Roper (johnroper100) removed rB Blender as the repository for this revision.
John Roper (johnroper100) updated this revision to Diff 4746.

Fixed the flag issue.

What other unhide operators should I work on (curve/metaball/etc...)?

Julian Eisel (Severin) requested changes to this revision.

That's not really what I requested, the flag shouldn't be needed at all. Read my comments carefully.
If you need more help, poke me on IRC (but give me a bit more time than 3 minutes until you head off again ;) )

Also, latest patch is patched incorrectly, it only shows changes to latest patch.

This revision now requires changes to proceed.Jul 24 2015, 6:56 PM

I don't have time to do any more coding right now, I hope that my work will help someone else get started.