Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntonioya <blendergit@gmail.com>2019-04-16 11:04:07 +0300
committerAntonioya <blendergit@gmail.com>2019-04-16 11:04:20 +0300
commit0d686ccc52902428271abe66382523b0c82f7fcd (patch)
tree4199e3b4ca372a03223b647ae531903137c7fdd5
parent777446ed7d05c35ef2ab98f83b7968daaf74344b (diff)
GPencil: Disable G/R/S transformations in Sculpt and Weight Paint mode
These transformations must be only available in Object and Edit mode. Reviewed by: @mendio @pepeland
-rw-r--r--source/blender/editors/transform/transform_conversions.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/source/blender/editors/transform/transform_conversions.c b/source/blender/editors/transform/transform_conversions.c
index a3ee7dd5635..217dd194f57 100644
--- a/source/blender/editors/transform/transform_conversions.c
+++ b/source/blender/editors/transform/transform_conversions.c
@@ -8941,8 +8941,11 @@ void createTransData(bContext *C, TransInfo *t)
has_transform_context = false;
}
}
- else if (ob && (ob->mode == OB_MODE_PAINT_GPENCIL)) {
- /* In grease pencil draw mode all transformations must be canceled. */
+ else if ((ob) &&
+ (ELEM(ob->mode, OB_MODE_PAINT_GPENCIL,
+ OB_MODE_SCULPT_GPENCIL, OB_MODE_WEIGHT_GPENCIL)))
+ {
+ /* In grease pencil all transformations must be canceled if not Object or Edit. */
has_transform_context = false;
}
else {