diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-09-16 08:04:44 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-09-16 08:04:44 +0400 |
commit | 23626e0149f25f13855735bbb7f65121e0c40ca0 (patch) | |
tree | 2688b304463fee3a042496727032f6772d447642 /source/blender/windowmanager/intern/wm_event_system.c | |
parent | 43bd8c2b28d06953b64ed6d1e72cead9e42463a0 (diff) |
fix [#36444] view3d.viewnumpad operator should not animate
when running viewport operations with exec() rather then invoke(), perform the action immediately rather then using smoothview.
makes viewport operations usable from python scripts.
Diffstat (limited to 'source/blender/windowmanager/intern/wm_event_system.c')
-rw-r--r-- | source/blender/windowmanager/intern/wm_event_system.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c index 0299ae4c656..46cce278d0e 100644 --- a/source/blender/windowmanager/intern/wm_event_system.c +++ b/source/blender/windowmanager/intern/wm_event_system.c @@ -975,6 +975,8 @@ static int wm_operator_invoke(bContext *C, wmOperatorType *ot, wmEvent *event, wmOperator *op = wm_operator_create(wm, ot, properties, reports); /* if reports == NULL, they'll be initialized */ const short is_nested_call = (wm->op_undo_depth != 0); + op->flag |= OP_IS_INVOKE; + /* initialize setting from previous run */ if (!is_nested_call) { /* not called by py script */ WM_operator_last_properties_init(op); |