Page MenuHome

Cleanup: de-duplicate code for instancing objects when linking
ClosedPublic

Authored by Campbell Barton (campbellbarton) on Sep 9 2020, 6:56 AM.

Details

Summary

This de-duplicates operations on an objects base when instantiating objects created when linking.


This is a follow up to D8792, Sybren suggested to de-duplicate the logic.

I don't have a strong opinion on this as it's only wrapping two function calls and some optional assignments. OTOH it has the advantage that all Base operations are handled in one place.

Diff Detail

Repository
rB Blender
Branch
TEMP-CLEANUP-LINKING (branched from master)
Build Status
Buildable 10072
Build 10072: arc lint + arc unit

Event Timeline

Campbell Barton (campbellbarton) requested review of this revision.Sep 9 2020, 6:56 AM
Campbell Barton (campbellbarton) created this revision.
  • Add comment regarding inconsistency with setting object active.

LGTM, always better to factorize logic, even if only for a few lines of code.

source/blender/blenloader/intern/readfile.c
10341

This does not seem to be related to the purpose of this patch? Is it actually needed, and why?

This revision is now accepted and ready to land.Sep 22 2020, 2:01 PM