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>2013-09-16 08:04:44 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-09-16 08:04:44 +0400
commit23626e0149f25f13855735bbb7f65121e0c40ca0 (patch)
tree2688b304463fee3a042496727032f6772d447642 /source/blender/editors/space_node/node_select.c
parent43bd8c2b28d06953b64ed6d1e72cead9e42463a0 (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/editors/space_node/node_select.c')
-rw-r--r--source/blender/editors/space_node/node_select.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/editors/space_node/node_select.c b/source/blender/editors/space_node/node_select.c
index 6ce31783bff..958a3433337 100644
--- a/source/blender/editors/space_node/node_select.c
+++ b/source/blender/editors/space_node/node_select.c
@@ -831,7 +831,8 @@ static int node_select_same_type_step_exec(bContext *C, wmOperator *op)
if (active->totr.xmax < ar->v2d.cur.xmin || active->totr.xmin > ar->v2d.cur.xmax ||
active->totr.ymax < ar->v2d.cur.ymin || active->totr.ymin > ar->v2d.cur.ymax)
{
- space_node_view_flag(C, snode, CTX_wm_region(C), NODE_SELECT);
+ const int smooth_viewtx = WM_operator_smooth_viewtx_get(op);
+ space_node_view_flag(C, snode, ar, NODE_SELECT, smooth_viewtx);
}
}
@@ -895,7 +896,7 @@ static void node_find_call_cb(struct bContext *C, void *UNUSED(arg1), void *arg2
if (active->totr.xmax < ar->v2d.cur.xmin || active->totr.xmin > ar->v2d.cur.xmax ||
active->totr.ymax < ar->v2d.cur.ymin || active->totr.ymin > ar->v2d.cur.ymax)
{
- space_node_view_flag(C, snode, ar, NODE_SELECT);
+ space_node_view_flag(C, snode, ar, NODE_SELECT, U.smooth_viewtx);
}
}