Debug commit;

If a group duplicator uses a group with no users, it draws in red. Needed
because this seems to happen in unknown cases...
This commit is contained in:
Ton Roosendaal
2005-12-12 09:18:56 +00:00
parent 7daa8d0bca
commit d2a3d5e79c
3 changed files with 10 additions and 11 deletions

View File

@@ -5971,9 +5971,6 @@ void BLO_library_append(SpaceFile *sfile, char *dir, int idcode)
/* make copy of the 'last loaded filename', we need to restore it */
BLI_strncpy(filename, G.sce, sizeof(filename));
printf("G.sce %s\n", filename);
printf("fd->filename %s\n", fd->filename);
printf("dir %s\n", dir);
BLI_strncpy(G.sce, fd->filename, sizeof(filename)); // already opened file, to reconstruct relative paths
@@ -6007,11 +6004,9 @@ void BLO_library_append(SpaceFile *sfile, char *dir, int idcode)
read_libraries(fd, &fd->mainlist);
if(sfile->flag & FILE_STRINGCODE) {
printf("mainl->curlib->name %s\n", mainl->curlib->name);
/* uses old .blend file (*filename) as reference */
BLI_makestringcode(filename, mainl->curlib->name);
printf("after mainl->curlib->name %s\n", mainl->curlib->name);
/* the caller checks for appended library, so we make sure names match */
BLI_strncpy(dir, mainl->curlib->name, sizeof(mainl->curlib->name));
}

View File

@@ -2120,6 +2120,10 @@ static void draw_dupli_objects(View3D *v3d, Base *base)
int color= (base->flag & SELECT)?TH_SELECT:TH_WIRE;
char dt, dtx;
/* debug */
if(base->object->dup_group && base->object->dup_group->id.us<1)
color= TH_REDALERT;
tbase.flag= OB_FROMDUPLI|base->flag;
lb= object_duplilist(G.scene, base->object);

View File

@@ -42,16 +42,16 @@
#include "BLI_blenlib.h"
#include "DNA_action_types.h"
#include "DNA_constraint_types.h"
#include "DNA_curve_types.h"
#include "DNA_ipo_types.h"
#include "DNA_object_types.h"
#include "DNA_nla_types.h"
#include "DNA_screen_types.h"
#include "DNA_space_types.h"
#include "DNA_scene_types.h"
#include "DNA_ipo_types.h"
#include "DNA_curve_types.h"
#include "DNA_object_types.h"
#include "DNA_userdef_types.h"
#include "DNA_action_types.h"
#include "DNA_nla_types.h"
#include "DNA_constraint_types.h"
#include "BKE_action.h"
#include "BKE_depsgraph.h"