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:
authorCampbell Barton <ideasman42@gmail.com>2010-11-17 18:16:49 +0300
committerCampbell Barton <ideasman42@gmail.com>2010-11-17 18:16:49 +0300
commitc8bcabaf40c287515e69d95afa9f13ad2178af4b (patch)
tree94e930fdf28ac22aa4efcfc4e1b470643ca71f9a /source/blender/editors/object/object_edit.c
parent5a37333053fb6791c222b3e375eb16214e22ddda (diff)
bugfix [#24685] Changing mode bypasses undo suppression
Editmode undo operator was using the operator OPTYPE_UNDO flag as well as its own EM_DO_UNDO option. This gave 2 problems. - python suppressed undos would fail (as in the report). - Undo push was called twice on exiting editmode for no reason. Use the operator undo in this case.
Diffstat (limited to 'source/blender/editors/object/object_edit.c')
-rw-r--r--source/blender/editors/object/object_edit.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/object/object_edit.c b/source/blender/editors/object/object_edit.c
index 118c649adde..d9e0140c699 100644
--- a/source/blender/editors/object/object_edit.c
+++ b/source/blender/editors/object/object_edit.c
@@ -511,7 +511,7 @@ static int editmode_toggle_exec(bContext *C, wmOperator *UNUSED(op))
if(!CTX_data_edit_object(C))
ED_object_enter_editmode(C, EM_WAITCURSOR);
else
- ED_object_exit_editmode(C, EM_FREEDATA|EM_FREEUNDO|EM_WAITCURSOR|EM_DO_UNDO);
+ ED_object_exit_editmode(C, EM_FREEDATA|EM_FREEUNDO|EM_WAITCURSOR); /* had EM_DO_UNDO but op flag calls undo too [#24685] */
return OPERATOR_FINISHED;
}