Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2019-08-14 16:29:46 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-08-14 16:32:24 +0300
commit03b2371387dcae9f801cabbc1819b1d7e3350829 (patch)
tree0300655f20a06a8e5c807b5fe6263b47c686dedb /source/blender/blenloader/intern/readfile.c
parentbc4fe45aef7e52f9e7a2bd5e370c6791c58af832 (diff)
Cleanup: move trailing comments to avoid wrapping code
Some statements were split across multiple lines because of their trailing comments. In most cases it's clearer to put the comments above.
Diffstat (limited to 'source/blender/blenloader/intern/readfile.c')
-rw-r--r--source/blender/blenloader/intern/readfile.c33
1 files changed, 21 insertions, 12 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index bcee606ea7b..23807de2537 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -679,8 +679,10 @@ static Main *blo_find_main(FileData *fd, const char *filepath, const char *relab
/* Add library data-block itself to 'main' Main, since libraries are **never** linked data.
* Fixes bug where you could end with all ID_LI data-blocks having the same name... */
lib = BKE_libblock_alloc(mainlist->first, ID_LI, BLI_path_basename(filepath), 0);
- lib->id.us = ID_FAKE_USERS(
- lib); /* Important, consistency with main ID reading code from read_libblock(). */
+
+ /* Important, consistency with main ID reading code from read_libblock(). */
+ lib->id.us = ID_FAKE_USERS(lib);
+
BLI_strncpy(lib->name, filepath, sizeof(lib->name));
BLI_strncpy(lib->filepath, name1, sizeof(lib->filepath));
@@ -3367,8 +3369,10 @@ static void direct_link_workspace(FileData *fd, WorkSpace *workspace, const Main
for (WorkSpaceDataRelation *relation = workspace->hook_layout_relations.first; relation;
relation = relation->next) {
- relation->parent = newglobadr(
- fd, relation->parent); /* data from window - need to access through global oldnew-map */
+
+ /* data from window - need to access through global oldnew-map */
+ relation->parent = newglobadr(fd, relation->parent);
+
relation->value = newdataadr(fd, relation->value);
}
@@ -9156,8 +9160,9 @@ static BHead *read_libblock(FileData *fd, Main *main, BHead *bhead, const int ta
/* do after read_struct, for dna reconstruct */
lb = which_libbase(main, idcode);
if (lb) {
- oldnewmap_insert(
- fd->libmap, bhead->old, id, bhead->code); /* for ID_LINK_PLACEHOLDER check */
+ /* for ID_LINK_PLACEHOLDER check */
+ oldnewmap_insert(fd->libmap, bhead->old, id, bhead->code);
+
BLI_addtail(lb, id);
}
else {
@@ -9524,8 +9529,10 @@ static void lib_link_all(FileData *fd, Main *main)
lib_link_material(fd, main);
lib_link_texture(fd, main);
lib_link_image(fd, main);
- lib_link_ipo(
- fd, main); /* XXX deprecated... still needs to be maintained for version patches still */
+
+ /* XXX deprecated... still needs to be maintained for version patches still. */
+ lib_link_ipo(fd, main);
+
lib_link_key(fd, main);
lib_link_world(fd, main);
lib_link_light(fd, main);
@@ -9539,8 +9546,10 @@ static void lib_link_all(FileData *fd, Main *main)
lib_link_armature(fd, main);
lib_link_action(fd, main);
lib_link_vfont(fd, main);
- lib_link_nodetree(fd,
- main); /* has to be done after scene/materials, this will verify group nodes */
+
+ /* Has to be done after scene/materials, this will verify group nodes. */
+ lib_link_nodetree(fd, main);
+
lib_link_palette(fd, main);
lib_link_brush(fd, main);
lib_link_paint_curve(fd, main);
@@ -11585,8 +11594,8 @@ static void library_link_end(Main *mainl,
BKE_main_id_tag_all(mainvar, LIB_TAG_NEW, false);
- fix_relpaths_library(BKE_main_blendfile_path(mainvar),
- mainvar); /* make all relative paths, relative to the open blend file */
+ /* Make all relative paths, relative to the open blend file. */
+ fix_relpaths_library(BKE_main_blendfile_path(mainvar), mainvar);
/* Give a base to loose objects and collections.
* Only directly linked objects & collections are instantiated by