Commit: e98b9d3c9c7b4a3a81fdb09c11a1c92acdb7ad1a
Author: Antonio Vazquez
Date: Mon Jun 11 11:27:14 2018 +0200
Branches: greasepencil-object
https://developer.blender.org/rBe98b9d3c9c7b4a3a81fdb09c11a1c92acdb7ad1a
Remove mode switching custom code
This code is not required because the mode switching is not done with keys 1..9
===================================================================
M source/blender/editors/object/object_edit.c
===================================================================
diff --git a/source/blender/editors/object/object_edit.c
b/source/blender/editors/object/object_edit.c
index adc21405748..e70ea243958 100644
--- a/source/blender/editors/object/object_edit.c
+++ b/source/blender/editors/object/object_edit.c
@@ -1366,26 +1366,6 @@ static int object_mode_set_exec(bContext *C, wmOperator
*op)
const bool toggle = RNA_boolean_get(op->ptr, "toggle");
if (use_submode) {
- /* grease pencil modes that reuse the same modes but only
- * for grease pencil objects
- */
- if (ob) {
- if (ob->type == OB_GPENCIL) {
- if (mode == OB_MODE_EDIT) {
- mode = OB_MODE_GPENCIL_EDIT;
- }
- if (mode == OB_MODE_SCULPT) {
- mode = OB_MODE_GPENCIL_SCULPT;
- }
- if (mode == OB_MODE_TEXTURE_PAINT) {
- mode = OB_MODE_GPENCIL_PAINT;
- }
- if (mode == OB_MODE_WEIGHT_PAINT) {
- mode = OB_MODE_GPENCIL_WEIGHT;
- }
- }
- }
-
/* When not changing modes use submodes, see: T55162. */
if (toggle == false) {
if (mode == restore_mode) {
_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs