0553f96becced3bd5f812ff0a2ffe90d7fd2b9bd
When a new node tree becomes active based on the context, the node editor was not centered on the new tree. This can easily lead to the situation where there is no node visible, and the user first has to search for the nodes. The reason for this is unexpectedly special: * `snode_set_context` calls `ED_node_tree_start` which adds the `NC_SCENE | ND_NODES` notifier. * Typically, this would update the `View2D` of the region in `node_area_listener`. * However, `snode_set_context` is called from `wm_event_do_refresh_wm_and_depsgraph` which happens after(!) the listeners run. Therefore, the node editor is redrawn before the listener is handled. * During redraw, the stored view center is overridden. When it is later used in the listener, the value is lost already. This patch solves this by updating the view center eagerly when opening changing what node tree is visible, instead of trying to it lazily where the required information might be lost already. Pull Request: https://projects.blender.org/blender/blender/pulls/138389
…
Blender
Blender is the free and open source 3D creation suite. It supports the entirety of the 3D pipeline—modeling, rigging, animation, simulation, rendering, compositing, motion tracking and video editing.
Project Pages
Development
License
Blender as a whole is licensed under the GNU General Public License, Version 3. Individual files may have a different but compatible license.
See blender.org/about/license for details.
Description
Languages
C++
78%
Python
14.9%
C
2.9%
GLSL
1.9%
CMake
1.2%
Other
0.9%
