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:
authorJoshua Leung <aligorith@gmail.com>2009-09-08 06:09:14 +0400
committerJoshua Leung <aligorith@gmail.com>2009-09-08 06:09:14 +0400
commit6808e15c8d20819deddd6b175668d11a6c6f454d (patch)
tree5beae41d3b50753e3e328749f59b7dad8235bfd9 /source/blender/editors/object/object_edit.c
parent00838f05d23cbd2dfefeab10d9d5345bbad25ea6 (diff)
2.5 - Mode Switching Bugfixes
This commit some of the many bugs here (it's still not perfect now, but much better than it was): * Moving in/out of Object, Edit, and Pose Modes for Armatures should now work smoothly. Operators should work nicely in the appropriate modes now (select linked might be a bit tempermental still, since it uses mouse-position). * Fixed the 'mysterious' memory leaks when changing modes. These were only caused when using the mode switching menu in the 3D-View. * Went through bullet-proofing some of the operator calling functions against NULL operator id-name strings.
Diffstat (limited to 'source/blender/editors/object/object_edit.c')
-rw-r--r--source/blender/editors/object/object_edit.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/editors/object/object_edit.c b/source/blender/editors/object/object_edit.c
index 9ef250d7963..9e61bbd3fb5 100644
--- a/source/blender/editors/object/object_edit.c
+++ b/source/blender/editors/object/object_edit.c
@@ -7247,7 +7247,7 @@ static EnumPropertyItem *object_mode_set_itemsf(bContext *C, PointerRNA *ptr, in
static const char *object_mode_op_string(int mode)
{
- if(mode == OB_MODE_EDIT)
+ if(mode & OB_MODE_EDIT)
return "OBJECT_OT_editmode_toggle";
if(mode == OB_MODE_SCULPT)
return "SCULPT_OT_sculptmode_toggle";
@@ -7333,6 +7333,8 @@ void ED_object_toggle_modes(bContext *C, int mode)
WM_operator_name_call(C, "PAINT_OT_texture_paint_toggle", WM_OP_EXEC_REGION_WIN, NULL);
if(mode & OB_MODE_PARTICLE_EDIT)
WM_operator_name_call(C, "PARTICLE_OT_particle_edit_toggle", WM_OP_EXEC_REGION_WIN, NULL);
+ if(mode & OB_MODE_POSE)
+ WM_operator_name_call(C, "OBJECT_OT_posemode_toggle", WM_OP_EXEC_REGION_WIN, NULL);
}
/* game property ops */