diff options
author | Miika Hamalainen <blender@miikah.org> | 2011-10-28 21:00:53 +0400 |
---|---|---|
committer | Miika Hamalainen <blender@miikah.org> | 2011-10-28 21:00:53 +0400 |
commit | 46ae692710467d3622f58e0c5ce371674a6a7d9b (patch) | |
tree | ebd27a8cc3adad65343a6a8d3d22ce02cad24db8 /source/blender/editors/space_outliner | |
parent | fae903e263fd11d788a4e55900ff25f4fc8b26db (diff) | |
parent | 7627a742ab6e630522186b04a71fa40533d87db2 (diff) |
Merge with trunk r41342
Diffstat (limited to 'source/blender/editors/space_outliner')
-rw-r--r-- | source/blender/editors/space_outliner/CMakeLists.txt | 1 | ||||
-rw-r--r-- | source/blender/editors/space_outliner/outliner_draw.c | 10 | ||||
-rw-r--r-- | source/blender/editors/space_outliner/outliner_tools.c | 4 |
3 files changed, 8 insertions, 7 deletions
diff --git a/source/blender/editors/space_outliner/CMakeLists.txt b/source/blender/editors/space_outliner/CMakeLists.txt index d969a80a678..27b4a568860 100644 --- a/source/blender/editors/space_outliner/CMakeLists.txt +++ b/source/blender/editors/space_outliner/CMakeLists.txt @@ -1,4 +1,3 @@ -# $Id: CMakeLists.txt 12931 2007-12-17 18:20:48Z theeth $ # ***** BEGIN GPL LICENSE BLOCK ***** # # This program is free software; you can redistribute it and/or diff --git a/source/blender/editors/space_outliner/outliner_draw.c b/source/blender/editors/space_outliner/outliner_draw.c index 91365e9e7de..cf9bf3de1b8 100644 --- a/source/blender/editors/space_outliner/outliner_draw.c +++ b/source/blender/editors/space_outliner/outliner_draw.c @@ -310,11 +310,15 @@ static void namebutton_cb(bContext *C, void *tsep, char *oldname) } /* Check the library target exists */ if (te->idcode == ID_LI) { - char expanded[FILE_MAXDIR + FILE_MAXFILE]; - BLI_strncpy(expanded, ((Library *)tselem->id)->name, FILE_MAXDIR + FILE_MAXFILE); + Library *lib= (Library *)tselem->id; + char expanded[FILE_MAX]; + + BKE_library_filepath_set(lib, lib->name); + + BLI_strncpy(expanded, lib->name, sizeof(expanded)); BLI_path_abs(expanded, G.main->name); if (!BLI_exists(expanded)) { - BKE_report(CTX_wm_reports(C), RPT_ERROR, "This path does not exist, correct this before saving"); + BKE_reportf(CTX_wm_reports(C), RPT_ERROR, "Library path '%s' does not exist, correct this before saving", expanded); } } } diff --git a/source/blender/editors/space_outliner/outliner_tools.c b/source/blender/editors/space_outliner/outliner_tools.c index 78907fbd1ed..a4f67f91763 100644 --- a/source/blender/editors/space_outliner/outliner_tools.c +++ b/source/blender/editors/space_outliner/outliner_tools.c @@ -310,9 +310,7 @@ static void object_delete_cb(bContext *C, Scene *scene, TreeElement *te, TreeSto static void id_local_cb(bContext *UNUSED(C), Scene *UNUSED(scene), TreeElement *UNUSED(te), TreeStoreElem *UNUSED(tsep), TreeStoreElem *tselem) { if (tselem->id->lib && (tselem->id->flag & LIB_EXTERN)) { - tselem->id->lib= NULL; - tselem->id->flag= LIB_LOCAL; - new_id(NULL, tselem->id, NULL); + id_clear_lib_data(NULL, tselem->id); } } |