diff options
author | Philipp Oeser <info@graphics-engineer.com> | 2019-04-30 15:32:35 +0300 |
---|---|---|
committer | Philipp Oeser <info@graphics-engineer.com> | 2019-04-30 16:29:31 +0300 |
commit | 40b66ac2a654809f518b3df91c5af2111013cb4d (patch) | |
tree | a7f77ad5f2202758c94dfa5b7056d958a093ef90 /source/blender/editors/transform | |
parent | 34944a203559d8c1b02508e106d6471197d7c5b4 (diff) |
Fix proportional editing always enabled if the property exists in the
operator
Fixes T64010, T64011
Reviewers: brecht
Maniphest Tasks: T64010, T64011
Differential Revision: https://developer.blender.org/D4764
Diffstat (limited to 'source/blender/editors/transform')
-rw-r--r-- | source/blender/editors/transform/transform_generics.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/source/blender/editors/transform/transform_generics.c b/source/blender/editors/transform/transform_generics.c index d3079aebd00..734a6a66358 100644 --- a/source/blender/editors/transform/transform_generics.c +++ b/source/blender/editors/transform/transform_generics.c @@ -1654,12 +1654,15 @@ void initTransInfo(bContext *C, TransInfo *t, wmOperator *op, const wmEvent *eve /* setting PET flag only if property exist in operator. Otherwise, assume it's not supported */ if (op && (prop = RNA_struct_find_property(op->ptr, "use_proportional_edit"))) { if (RNA_property_is_set(op->ptr, prop)) { - int proportional = PROP_EDIT_USE; - if (RNA_boolean_get(op->ptr, "use_proportional_connected")) { - proportional |= PROP_EDIT_CONNECTED; - } - if (RNA_boolean_get(op->ptr, "use_proportional_projected")) { - proportional |= PROP_EDIT_PROJECTED; + int proportional = 0; + if (RNA_boolean_get(op->ptr, "use_proportional_edit")) { + proportional |= PROP_EDIT_USE; + if (RNA_boolean_get(op->ptr, "use_proportional_connected")) { + proportional |= PROP_EDIT_CONNECTED; + } + if (RNA_boolean_get(op->ptr, "use_proportional_projected")) { + proportional |= PROP_EDIT_PROJECTED; + } } t->flag |= initTransInfo_edit_pet_to_flag(proportional); } |