[Bf-blender-cvs] [a8fa2d9321c] greasepencil-object: Fix infinite loop in mode set
Antonio Vazquez
noreply at git.blender.org
Fri Feb 9 17:50:24 CET 2018
Commit: a8fa2d9321c508188774e8edca05bf86e8d61912
Author: Antonio Vazquez
Date: Fri Feb 9 17:50:11 2018 +0100
Branches: greasepencil-object
https://developer.blender.org/rBa8fa2d9321c508188774e8edca05bf86e8d61912
Fix infinite loop in mode set
The mode set entered in an infinite loop
===================================================================
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 f5e0edb01aa..af2deab2e50 100644
--- a/source/blender/editors/object/object_edit.c
+++ b/source/blender/editors/object/object_edit.c
@@ -1597,7 +1597,7 @@ static int object_mode_set_exec(bContext *C, wmOperator *op)
if ((ob->data) && (ob->data == gpd)) {
if (ELEM(mode, OB_MODE_OBJECT, OB_MODE_EDIT, OB_MODE_POSE)) {
workspace->object_mode_restore = OB_MODE_OBJECT;
- if (ELEM(workspace->object_mode, OB_MODE_OBJECT, OB_MODE_EDIT, OB_MODE_GPENCIL_EDIT)) {
+ if (ELEM(workspace->object_mode, OB_MODE_EDIT, OB_MODE_GPENCIL_EDIT)) {
WM_operator_name_call(C, "GPENCIL_OT_editmode_toggle", WM_OP_EXEC_REGION_WIN, NULL);
}
if (workspace->object_mode == OB_MODE_GPENCIL_PAINT) {
More information about the Bf-blender-cvs
mailing list