diff options
author | Nathan Craddock <nzcraddock@gmail.com> | 2020-06-21 01:02:54 +0300 |
---|---|---|
committer | Nathan Craddock <nzcraddock@gmail.com> | 2020-06-21 01:15:18 +0300 |
commit | 8ce1a602627350bf986da5e3f60d9edd38006d52 (patch) | |
tree | 376f3b9ae4babac193a0f438fc19ca41e6f60950 /source/blender/editors/space_outliner/outliner_sync.c | |
parent | 2d9ab46e0b6e417b3f9603d047c523cd7677bb20 (diff) |
Fix T71812: Outliner walk navigation not activating
Walk navigation used a separate flag to select the element. This is
because activation and mode toggling were connected until rB702e00f91088
cleaned up the selection logic.
Now walk navigation can activate objects and other elements without
changing modes. This also addresses renaming in the outliner which
did renaming from the active element, not the walk element.
Diffstat (limited to 'source/blender/editors/space_outliner/outliner_sync.c')
-rw-r--r-- | source/blender/editors/space_outliner/outliner_sync.c | 23 |
1 files changed, 7 insertions, 16 deletions
diff --git a/source/blender/editors/space_outliner/outliner_sync.c b/source/blender/editors/space_outliner/outliner_sync.c index 943738680e6..a4be4062746 100644 --- a/source/blender/editors/space_outliner/outliner_sync.c +++ b/source/blender/editors/space_outliner/outliner_sync.c @@ -392,7 +392,6 @@ void ED_outliner_select_sync_from_outliner(bContext *C, SpaceOutliner *soops) } static void outliner_select_sync_from_object(ViewLayer *view_layer, - SpaceOutliner *soops, Object *obact, TreeElement *te, TreeStoreElem *tselem) @@ -404,7 +403,6 @@ static void outliner_select_sync_from_object(ViewLayer *view_layer, if (base && (ob == obact)) { tselem->flag |= TSE_ACTIVE; - outliner_set_walk_element(soops, tselem); } else { tselem->flag &= ~TSE_ACTIVE; @@ -418,8 +416,7 @@ static void outliner_select_sync_from_object(ViewLayer *view_layer, } } -static void outliner_select_sync_from_edit_bone(SpaceOutliner *soops, - EditBone *ebone_active, +static void outliner_select_sync_from_edit_bone(EditBone *ebone_active, TreeElement *te, TreeStoreElem *tselem) { @@ -427,7 +424,6 @@ static void outliner_select_sync_from_edit_bone(SpaceOutliner *soops, if (ebone == ebone_active) { tselem->flag |= TSE_ACTIVE; - outliner_set_walk_element(soops, tselem); } else { tselem->flag &= ~TSE_ACTIVE; @@ -441,8 +437,7 @@ static void outliner_select_sync_from_edit_bone(SpaceOutliner *soops, } } -static void outliner_select_sync_from_pose_bone(SpaceOutliner *soops, - bPoseChannel *pchan_active, +static void outliner_select_sync_from_pose_bone(bPoseChannel *pchan_active, TreeElement *te, TreeStoreElem *tselem) { @@ -451,7 +446,6 @@ static void outliner_select_sync_from_pose_bone(SpaceOutliner *soops, if (pchan == pchan_active) { tselem->flag |= TSE_ACTIVE; - outliner_set_walk_element(soops, tselem); } else { tselem->flag &= ~TSE_ACTIVE; @@ -465,15 +459,12 @@ static void outliner_select_sync_from_pose_bone(SpaceOutliner *soops, } } -static void outliner_select_sync_from_sequence(SpaceOutliner *soops, - Sequence *sequence_active, - TreeStoreElem *tselem) +static void outliner_select_sync_from_sequence(Sequence *sequence_active, TreeStoreElem *tselem) { Sequence *seq = (Sequence *)tselem->id; if (seq == sequence_active) { tselem->flag |= TSE_ACTIVE; - outliner_set_walk_element(soops, tselem); } else { tselem->flag &= ~TSE_ACTIVE; @@ -510,22 +501,22 @@ static void outliner_sync_selection_to_outliner(ViewLayer *view_layer, if (tselem->type == 0 && te->idcode == ID_OB) { if (sync_types->object) { - outliner_select_sync_from_object(view_layer, soops, active_data->object, te, tselem); + outliner_select_sync_from_object(view_layer, active_data->object, te, tselem); } } else if (tselem->type == TSE_EBONE) { if (sync_types->edit_bone) { - outliner_select_sync_from_edit_bone(soops, active_data->edit_bone, te, tselem); + outliner_select_sync_from_edit_bone(active_data->edit_bone, te, tselem); } } else if (tselem->type == TSE_POSE_CHANNEL) { if (sync_types->pose_bone) { - outliner_select_sync_from_pose_bone(soops, active_data->pose_channel, te, tselem); + outliner_select_sync_from_pose_bone(active_data->pose_channel, te, tselem); } } else if (tselem->type == TSE_SEQUENCE) { if (sync_types->sequence) { - outliner_select_sync_from_sequence(soops, active_data->sequence, tselem); + outliner_select_sync_from_sequence(active_data->sequence, tselem); } } else { |