[Bf-blender-cvs] [9454359a165] blender2.8: Workspace: Clarifying library remap workaround

Dalai Felinto noreply at git.blender.org
Fri Dec 8 16:36:42 CET 2017


Commit: 9454359a165767f04ef73316205eebf3161083ae
Author: Dalai Felinto
Date:   Fri Dec 8 13:27:22 2017 -0200
Branches: blender2.8
https://developer.blender.org/rB9454359a165767f04ef73316205eebf3161083ae

Workspace: Clarifying library remap workaround

WorkSpaceLayout->screen will be made public soon, but meanwhile this makes it
clear why we are not passing layout->screen to CALLBACK_INVOKE in this case.

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

M	source/blender/blenkernel/intern/library_query.c

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

diff --git a/source/blender/blenkernel/intern/library_query.c b/source/blender/blenkernel/intern/library_query.c
index 0bd1c5ff114..4074e0f0dc6 100644
--- a/source/blender/blenkernel/intern/library_query.c
+++ b/source/blender/blenkernel/intern/library_query.c
@@ -984,6 +984,8 @@ void BKE_library_foreach_ID_link(Main *bmain, ID *id, LibraryIDLinkCallback call
 				for (WorkSpaceLayout *layout = layouts->first; layout; layout = layout->next) {
 					bScreen *screen = BKE_workspace_layout_screen_get(layout);
 
+					/* CALLBACK_INVOKE expects an actual pointer, not a variable holding the pointer.
+					 * However we can't acess layout->screen here since we are outside the workspace project. */
 					CALLBACK_INVOKE(screen, IDWALK_CB_NOP);
 					/* allow callback to set a different screen */
 					BKE_workspace_layout_screen_set(layout, screen);



More information about the Bf-blender-cvs mailing list