diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-11-23 10:06:50 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-11-23 10:06:50 +0300 |
commit | 7a7c9ee71a7b73f3c26e554ce11096abce77b874 (patch) | |
tree | b4447acab24478985fb760c9185085629278a78c /source/blender/editors/uvedit | |
parent | a6eb9a3e21894fad2605cf1e4ae228147be71857 (diff) |
Fix uv lasso/box multi-object select logic
Was de-selecting all UV's on each iteration.
Diffstat (limited to 'source/blender/editors/uvedit')
-rw-r--r-- | source/blender/editors/uvedit/uvedit_ops.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/source/blender/editors/uvedit/uvedit_ops.c b/source/blender/editors/uvedit/uvedit_ops.c index 30c0bc741c2..50b7290e8fb 100644 --- a/source/blender/editors/uvedit/uvedit_ops.c +++ b/source/blender/editors/uvedit/uvedit_ops.c @@ -3205,6 +3205,10 @@ static int uv_box_select_exec(bContext *C, wmOperator *op) uint objects_len = 0; Object **objects = BKE_view_layer_array_from_objects_in_edit_mode_unique_data_with_uvs(view_layer, &objects_len); + if (SEL_OP_USE_PRE_DESELECT(sel_op)) { + uv_select_all_perform_multi(scene, ima, objects, objects_len, SEL_DESELECT); + } + /* don't indent to avoid diff noise! */ for (uint ob_index = 0; ob_index < objects_len; ob_index++) { Object *obedit = objects[ob_index]; @@ -3214,10 +3218,6 @@ static int uv_box_select_exec(bContext *C, wmOperator *op) const int cd_loop_uv_offset = CustomData_get_offset(&em->bm->ldata, CD_MLOOPUV); - if (SEL_OP_USE_PRE_DESELECT(sel_op)) { - uv_select_all_perform_multi(scene, ima, objects, objects_len, SEL_DESELECT); - } - /* do actual selection */ if (use_face_center && !pinned) { /* handle face selection mode */ @@ -3486,6 +3486,10 @@ static bool do_lasso_select_mesh_uv( uint objects_len = 0; Object **objects = BKE_view_layer_array_from_objects_in_edit_mode_unique_data_with_uvs(view_layer, &objects_len); + if (SEL_OP_USE_PRE_DESELECT(sel_op)) { + uv_select_all_perform_multi(scene, ima, objects, objects_len, SEL_DESELECT); + } + /* don't indent to avoid diff noise! */ for (uint ob_index = 0; ob_index < objects_len; ob_index++) { Object *obedit = objects[ob_index]; @@ -3496,10 +3500,6 @@ static bool do_lasso_select_mesh_uv( const int cd_loop_uv_offset = CustomData_get_offset(&em->bm->ldata, CD_MLOOPUV); - if (SEL_OP_USE_PRE_DESELECT(sel_op)) { - uv_select_all_perform_multi(scene, ima, objects, objects_len, SEL_DESELECT); - } - if (use_face_center) { /* Face Center Sel */ BM_ITER_MESH (efa, &iter, em->bm, BM_FACES_OF_MESH) { BM_elem_flag_disable(efa, BM_ELEM_TAG); |