diff options
author | Germano Cavalcante <germano.costa@ig.com.br> | 2021-05-12 04:40:56 +0300 |
---|---|---|
committer | Germano Cavalcante <germano.costa@ig.com.br> | 2021-05-12 05:44:50 +0300 |
commit | cb385a117bf00d0b482aa2660a6b573ab4458026 (patch) | |
tree | 9eda1db07b236f660d4412463f1a4370b5e0342d /source/blender/editors/transform/transform.c | |
parent | cbeeca8167f840798a0977906be911a09e7a63dd (diff) |
Cleanup: Use enum to indicate the current orientation
Improves readability.
Diffstat (limited to 'source/blender/editors/transform/transform.c')
-rw-r--r-- | source/blender/editors/transform/transform.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/transform/transform.c b/source/blender/editors/transform/transform.c index bb3afd77dba..a033568cf84 100644 --- a/source/blender/editors/transform/transform.c +++ b/source/blender/editors/transform/transform.c @@ -782,7 +782,7 @@ static bool transform_event_modal_constraint(TransInfo *t, short modal_type) } else { short orient_index = 1; - if (t->orient_curr == 0 || ELEM(constraint_curr, -1, constraint_new)) { + if (t->orient_curr == O_DEFAULT || ELEM(constraint_curr, -1, constraint_new)) { /* Successive presses on existing axis, cycle orientation modes. */ orient_index = (short)((t->orient_curr + 1) % (int)ARRAY_SIZE(t->orient)); } @@ -1426,7 +1426,7 @@ void saveTransform(bContext *C, TransInfo *t, wmOperator *op) mat3_to_size(t->values_final, tmat); } - BLI_assert(t->orient_curr == 0); + BLI_assert(t->orient_curr == O_DEFAULT); unit_m3(t->spacemtx); t->orient[0].type = V3D_ORIENT_GLOBAL; } |