[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37328] trunk/blender/source/blender/ blenloader/intern/readfile.c: fix [#27616] Appending an object from a file brings all existing group links to scene
Campbell Barton
ideasman42 at gmail.com
Thu Jun 9 06:28:54 CEST 2011
Revision: 37328
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=37328
Author: campbellbarton
Date: 2011-06-09 04:28:53 +0000 (Thu, 09 Jun 2011)
Log Message:
-----------
fix [#27616] Appending an object from a file brings all existing group links to scene
When appending from a blend file which had an object already linked, _but_ was not in any scenes.
- the linked object would be instanced.
Modified Paths:
--------------
trunk/blender/source/blender/blenloader/intern/readfile.c
Modified: trunk/blender/source/blender/blenloader/intern/readfile.c
===================================================================
--- trunk/blender/source/blender/blenloader/intern/readfile.c 2011-06-09 03:56:32 UTC (rev 37327)
+++ trunk/blender/source/blender/blenloader/intern/readfile.c 2011-06-09 04:28:53 UTC (rev 37328)
@@ -12742,8 +12742,14 @@
/* when appending, make sure any indirectly loaded objects
* get a base else they cant be accessed at all [#27437] */
if(ob->id.us==1 && is_link==FALSE && ob->id.lib==lib) {
- if(object_in_any_scene(mainvar, ob)==0) {
- do_it= 1;
+
+ /* we may be appending from a scene where we already
+ * have a linked object which is not in any scene [#27616] */
+ if((ob->id.flag & LIB_PRE_EXISTING)==0) {
+
+ if(object_in_any_scene(mainvar, ob)==0) {
+ do_it= 1;
+ }
}
}
}
More information about the Bf-blender-cvs
mailing list