[Bf-blender-cvs] [8edb116a815] workspaces: Don't append temporary screen-layouts with workspaces

Julian Eisel noreply at git.blender.org
Thu Apr 6 23:47:37 CEST 2017


Commit: 8edb116a815547fb2b4131b4e9083afd2d7b3bfd
Author: Julian Eisel
Date:   Thu Apr 6 23:46:58 2017 +0200
Branches: workspaces
https://developer.blender.org/rB8edb116a815547fb2b4131b4e9083afd2d7b3bfd

Don't append temporary screen-layouts with workspaces

===================================================================

M	source/blender/blenloader/intern/readfile.c

===================================================================

diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 996064933f1..cd650ef8bdd 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -2757,8 +2757,17 @@ static void lib_link_workspaces(FileData *fd, Main *bmain)
 		BKE_workspace_layout_iter_begin(layout, layouts->first)
 		{
 			bScreen *screen = newlibadr(fd, id->lib, BKE_workspace_layout_screen_get(layout));
+
 			if (screen) {
 				BKE_workspace_layout_screen_set(layout, screen);
+
+				if (ID_IS_LINKED_DATABLOCK(id)) {
+					screen->winid = 0;
+					if (screen->temp) {
+						/* delete temp layouts when appending */
+						BKE_workspace_layout_remove(workspace, layout, bmain);
+					}
+				}
 			}
 		}
 		BKE_workspace_layout_iter_end;




More information about the Bf-blender-cvs mailing list