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-07-04 14:00:46 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2018-07-04 19:40:33 +0300
commitc43443d530bff67693dc2db4efdca6307703ce61 (patch)
tree40305a5fe154a25387c3fd3afcbfc560346bf383 /source/blender/makesdna
parent4e2228525fc9bbcff58e315c5e3bbc193cd63a0b (diff)
Workspaces: store view layer per main window, instead of per workspace.
It was a bit odd that the scene was stored per window but not the view layer. The reasoning was that you would use different view layers for different tasks. This is still possible, but it's more predictable to switch them both explicitly, and with child window support manually syncing the view layers between multiple windows is no longer needed as often.
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r--source/blender/makesdna/DNA_windowmanager_types.h3
-rw-r--r--source/blender/makesdna/DNA_workspace_types.h8
2 files changed, 2 insertions, 9 deletions
diff --git a/source/blender/makesdna/DNA_windowmanager_types.h b/source/blender/makesdna/DNA_windowmanager_types.h
index 0ef9e9b134a..bd2811d3306 100644
--- a/source/blender/makesdna/DNA_windowmanager_types.h
+++ b/source/blender/makesdna/DNA_windowmanager_types.h
@@ -188,8 +188,9 @@ typedef struct wmWindow {
struct wmWindow *parent; /* Parent window */
- struct Scene *scene; /* The scene displayed in this window. */
+ struct Scene *scene; /* Active scene displayed in this window. */
struct Scene *new_scene; /* temporary when switching */
+ char view_layer_name[64]; /* Active view layer displayed in this window. */
struct WorkSpaceInstanceHook *workspace_hook;
diff --git a/source/blender/makesdna/DNA_workspace_types.h b/source/blender/makesdna/DNA_workspace_types.h
index f07dc195455..2b0f74a54ee 100644
--- a/source/blender/makesdna/DNA_workspace_types.h
+++ b/source/blender/makesdna/DNA_workspace_types.h
@@ -129,7 +129,6 @@ typedef struct WorkSpace {
/* Store for each hook (so for each window) which layout has
* been activated the last time this workspace was visible. */
ListBase hook_layout_relations DNA_PRIVATE_WORKSPACE_READ_WRITE; /* WorkSpaceDataRelation */
- ListBase scene_layer_relations; /* WorkSpaceSceneRelation */
/* Feature tagging (use for addons) */
ListBase owner_ids DNA_PRIVATE_WORKSPACE_READ_WRITE; /* wmOwnerID */
@@ -190,13 +189,6 @@ typedef struct WorkSpaceDataRelation {
#endif /* DNA_PRIVATE_WORKSPACE_READ_WRITE */
-typedef struct WorkSpaceSceneRelation {
- struct WorkSpaceSceneRelation *next, *prev;
-
- struct Scene *scene;
- char view_layer[64]; /* MAX_NAME */
-} WorkSpaceSceneRelation;
-
/**
* Little wrapper to store data that is going to be per window, but comming from the workspace.
* It allows us to keep workspace and window data completely separate.