From 600fd1c6f0ed5025068598bfb98f6881f2563acd Mon Sep 17 00:00:00 2001 From: Germano Cavalcante Date: Wed, 20 May 2020 16:22:10 -0300 Subject: Fix T76919: Wrong orientation when changing translate to rotate During the refactor of the transform operations, in an attempt to maintain previous behavior, the default orientation of the translate and resize operations became `Global` and the rotate operation became `View`. Now the default is always `View`, and on redo, the translate and rotate operations are saved as `Global`. --- source/blender/editors/transform/transform_generics.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'source/blender/editors/transform/transform_generics.c') diff --git a/source/blender/editors/transform/transform_generics.c b/source/blender/editors/transform/transform_generics.c index 4472facf183..a33186cd9d3 100644 --- a/source/blender/editors/transform/transform_generics.c +++ b/source/blender/editors/transform/transform_generics.c @@ -1660,15 +1660,11 @@ void initTransInfo(bContext *C, TransInfo *t, wmOperator *op, const wmEvent *eve orient_type_scene += index_custom; } - short orient_type_default = V3D_ORIENT_GLOBAL; + short orient_type_default = V3D_ORIENT_VIEW; short orient_type_constraint[2]; if (op && (prop = RNA_struct_find_property(op->ptr, "orient_axis"))) { t->orient_axis = RNA_property_enum_get(op->ptr, prop); - - /* For transfor modes that require "orient_axis" use - * `V3D_ORIENT_VIEW` as default. */ - orient_type_default = V3D_ORIENT_VIEW; } if (op && (prop = RNA_struct_find_property(op->ptr, "orient_axis_ortho"))) { t->orient_axis_ortho = RNA_property_enum_get(op->ptr, prop); -- cgit v1.2.3