Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Craddock <nzcraddock@gmail.com>2020-04-25 05:22:46 +0300
committerNathan Craddock <nzcraddock@gmail.com>2020-04-25 05:22:46 +0300
commit4ab85a338055b1d53a5a4c4e0cfc04c6300efcc3 (patch)
treedbbf1c6dc5f02ddaa5336369ed5a350992c6646c /source/blender/editors/space_outliner/outliner_sync.c
parent5d14463e1aee44a99d37f6d94804c9e8407ee4fd (diff)
Cleanup: Select sync from outliner
Move the condition to check if selection syncing is enabled to inside the syncing function rather than before each time it is called.
Diffstat (limited to 'source/blender/editors/space_outliner/outliner_sync.c')
-rw-r--r--source/blender/editors/space_outliner/outliner_sync.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/editors/space_outliner/outliner_sync.c b/source/blender/editors/space_outliner/outliner_sync.c
index 35dd91ff061..852773d3979 100644
--- a/source/blender/editors/space_outliner/outliner_sync.c
+++ b/source/blender/editors/space_outliner/outliner_sync.c
@@ -351,8 +351,9 @@ static void outliner_sync_selection_from_outliner(Scene *scene,
/* Set clean outliner and mark other outliners for syncing */
void ED_outliner_select_sync_from_outliner(bContext *C, SpaceOutliner *soops)
{
- /* Don't sync in certain outliner display modes */
- if (ELEM(soops->outlinevis, SO_LIBRARIES, SO_DATA_API, SO_ID_ORPHANS)) {
+ /* Don't sync if not checked or in certain outliner display modes */
+ if (!(soops->flag & SO_SYNC_SELECT) ||
+ ELEM(soops->outlinevis, SO_LIBRARIES, SO_DATA_API, SO_ID_ORPHANS)) {
return;
}