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:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2018-05-24 18:28:35 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2018-05-25 12:16:58 +0300
commit03a80facfc78178632086179e36f1c67128d5c09 (patch)
tree886d3eb3a6bc5cb68aaaae07aa8e0527e4882609 /source/blender/makesrna/intern/rna_scene.c
parent08da2826e0f29a6a43b60deb3b31dac8dba22e6d (diff)
Fix T55183, fix T55174: crashes with workspace / view layer relation.
Don't store pointers to ViewLayer in the workspace, only names. Add specific relation type since the generic mechanism makes the code hard to follow. Integrate with pointer restore for undo and library remapping code to avoid data going out of sync. Also add relation automatically if there doesn't exists one yet in BKE_workspace_view_layer_get, because in general it's really hard to ensure it will exist when making arbitrary scene changes. Differential Revision: https://developer.blender.org/D3432
Diffstat (limited to 'source/blender/makesrna/intern/rna_scene.c')
-rw-r--r--source/blender/makesrna/intern/rna_scene.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_scene.c b/source/blender/makesrna/intern/rna_scene.c
index c55a6ea4a59..b6fd98bce7c 100644
--- a/source/blender/makesrna/intern/rna_scene.c
+++ b/source/blender/makesrna/intern/rna_scene.c
@@ -1485,7 +1485,7 @@ void rna_ViewLayer_name_set(PointerRNA *ptr, const char *value)
{
Scene *scene = (Scene *)ptr->id.data;
ViewLayer *view_layer = (ViewLayer *)ptr->data;
- BKE_view_layer_rename(scene, view_layer, value);
+ BKE_view_layer_rename(G.main, scene, view_layer, value);
}
static void rna_SceneRenderView_name_set(PointerRNA *ptr, const char *value)