From a0c2c518fab09b2f2a56a8d1d298fb3758627da4 Mon Sep 17 00:00:00 2001 From: Philipp Oeser Date: Mon, 24 Apr 2023 14:16:32 +0200 Subject: [PATCH] Fix #107294 : Node Editor "Frame All/Selected" ignore Smooth View Caused by 3a1cf838ca09. Smooth view transitions only work when an operator is **invoked** (wont work from **exec**, see `WM_operator_smooth_viewtx_get`). Now 3a1cf838ca09 changed the `operator_context` for some other operators in the menu to 'EXEC_REGION_WIN' (for good reason). But setting `operator_context` on a `uiLayout` will set context on the **root** layout (not the actual sublayout alone), so all following operators "inherited" the [changed] context. Now make sure following operators get properly invoked again by giving the right context. --- scripts/startup/bl_ui/space_node.py | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/startup/bl_ui/space_node.py b/scripts/startup/bl_ui/space_node.py index 4b40d203c6d..e16c6e1e77c 100644 --- a/scripts/startup/bl_ui/space_node.py +++ b/scripts/startup/bl_ui/space_node.py @@ -261,6 +261,7 @@ class NODE_MT_view(Menu): layout.separator() + layout.operator_context = 'INVOKE_REGION_WIN' layout.operator("node.view_selected") layout.operator("node.view_all") -- 2.30.2