[Bf-blender-cvs] [1f3143fcc7b] blender2.8: Outliner: rename Data-Blocks to Data API, to make clear it's low level stuff.

Brecht Van Lommel noreply at git.blender.org
Thu May 17 14:30:46 CEST 2018


Commit: 1f3143fcc7b6e939732662268aa969e4a4a52e5e
Author: Brecht Van Lommel
Date:   Thu May 17 12:20:10 2018 +0200
Branches: blender2.8
https://developer.blender.org/rB1f3143fcc7b6e939732662268aa969e4a4a52e5e

Outliner: rename Data-Blocks to Data API, to make clear it's low level stuff.

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

M	release/scripts/startup/bl_ui/space_outliner.py
M	source/blender/blenloader/intern/versioning_260.c
M	source/blender/blenloader/intern/versioning_280.c
M	source/blender/editors/space_outliner/outliner_draw.c
M	source/blender/editors/space_outliner/outliner_edit.c
M	source/blender/editors/space_outliner/outliner_select.c
M	source/blender/editors/space_outliner/outliner_tree.c
M	source/blender/makesdna/DNA_space_types.h
M	source/blender/makesrna/intern/rna_space.c

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

diff --git a/release/scripts/startup/bl_ui/space_outliner.py b/release/scripts/startup/bl_ui/space_outliner.py
index 6441f70b4d8..de5c5a408d5 100644
--- a/release/scripts/startup/bl_ui/space_outliner.py
+++ b/release/scripts/startup/bl_ui/space_outliner.py
@@ -40,7 +40,7 @@ class OUTLINER_HT_header(Header):
 
         OUTLINER_MT_editor_menus.draw_collapsible(context, layout)
 
-        if space.display_mode == 'DATABLOCKS':
+        if space.display_mode == 'DATA_API':
             layout.separator()
 
             row = layout.row(align=True)
@@ -87,7 +87,7 @@ class OUTLINER_MT_editor_menus(Menu):
 
         layout.menu("OUTLINER_MT_view")
 
-        if space.display_mode == 'DATABLOCKS':
+        if space.display_mode == 'DATA_API':
             layout.menu("OUTLINER_MT_edit_datablocks")
 
         elif space.display_mode == 'ORPHAN_DATA':
@@ -105,7 +105,7 @@ class OUTLINER_MT_view(Menu):
 
         space = context.space_data
 
-        if space.display_mode != 'DATABLOCKS':
+        if space.display_mode != 'DATA_API':
             layout.prop(space, "use_sort_alpha")
             layout.prop(space, "show_restrict_columns")
             layout.separator()
diff --git a/source/blender/blenloader/intern/versioning_260.c b/source/blender/blenloader/intern/versioning_260.c
index 4049912b586..1d8bea40381 100644
--- a/source/blender/blenloader/intern/versioning_260.c
+++ b/source/blender/blenloader/intern/versioning_260.c
@@ -2268,7 +2268,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *main)
 						          SO_GROUPS,
 						          SO_LIBRARIES,
 						          SO_SEQUENCE,
-						          SO_DATABLOCKS))
+						          SO_DATA_API))
 						{
 							so->outlinevis = SO_SCENES;
 						}
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c
index eb351a247ab..add02f2bda0 100644
--- a/source/blender/blenloader/intern/versioning_280.c
+++ b/source/blender/blenloader/intern/versioning_280.c
@@ -884,7 +884,7 @@ void blo_do_versions_280(FileData *fd, Library *UNUSED(lib), Main *main)
 							          SO_GROUPS,
 							          SO_LIBRARIES,
 							          SO_SEQUENCE,
-							          SO_DATABLOCKS,
+							          SO_DATA_API,
 							          SO_ID_ORPHANS,
 							          SO_COLLECTIONS))
 							{
diff --git a/source/blender/editors/space_outliner/outliner_draw.c b/source/blender/editors/space_outliner/outliner_draw.c
index c8765c5016e..a01a4bf187d 100644
--- a/source/blender/editors/space_outliner/outliner_draw.c
+++ b/source/blender/editors/space_outliner/outliner_draw.c
@@ -1720,7 +1720,7 @@ static void outliner_draw_highlights_recursive(
         int start_x, int *io_start_y)
 {
 	const bool is_searching = SEARCHING_OUTLINER(soops) ||
-	                          (soops->outlinevis == SO_DATABLOCKS &&
+	                          (soops->outlinevis == SO_DATA_API &&
 	                           (soops->filter & SO_FILTER_SEARCH) &&
 	                           soops->search_string[0] != 0);
 
@@ -1788,7 +1788,7 @@ static void outliner_draw_tree(
 
 	glBlendFuncSeparate(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA, GL_ONE, GL_ONE_MINUS_SRC_ALPHA); // only once
 
-	if (soops->outlinevis == SO_DATABLOCKS) {
+	if (soops->outlinevis == SO_DATA_API) {
 		/* struct marks */
 		starty = (int)ar->v2d.tot.ymax - UI_UNIT_Y - OL_Y_OFFSET;
 		outliner_draw_struct_marks(ar, soops, &soops->tree, &starty);
@@ -1914,7 +1914,7 @@ void draw_outliner(const bContext *C)
 	/* get extents of data */
 	outliner_height(soops, &soops->tree, &sizey);
 
-	if (soops->outlinevis == SO_DATABLOCKS) {
+	if (soops->outlinevis == SO_DATA_API) {
 		/* RNA has two columns:
 		 *  - column 1 is (max_width + OL_RNA_COL_SPACEX) or
 		 *				 (OL_RNA_COL_X), whichever is wider...
@@ -1964,7 +1964,7 @@ void draw_outliner(const bContext *C)
 	        (bContext *)C, block, scene, view_layer, obedit,
 	        ar, soops, has_restrict_icons, &te_edit);
 
-	if (soops->outlinevis == SO_DATABLOCKS) {
+	if (soops->outlinevis == SO_DATA_API) {
 		/* draw rna buttons */
 		outliner_draw_rnacols(ar, sizex_rna);
 		outliner_draw_rnabuts(block, ar, soops, sizex_rna, &soops->tree);
diff --git a/source/blender/editors/space_outliner/outliner_edit.c b/source/blender/editors/space_outliner/outliner_edit.c
index 4733b09da2f..5187de00cff 100644
--- a/source/blender/editors/space_outliner/outliner_edit.c
+++ b/source/blender/editors/space_outliner/outliner_edit.c
@@ -1340,7 +1340,7 @@ static int ed_operator_outliner_datablocks_active(bContext *C)
 	ScrArea *sa = CTX_wm_area(C);
 	if ((sa) && (sa->spacetype == SPACE_OUTLINER)) {
 		SpaceOops *so = CTX_wm_space_outliner(C);
-		return (so->outlinevis == SO_DATABLOCKS);
+		return (so->outlinevis == SO_DATA_API);
 	}
 	return 0;
 }
diff --git a/source/blender/editors/space_outliner/outliner_select.c b/source/blender/editors/space_outliner/outliner_select.c
index 4bde67d9662..d62f542e1d1 100644
--- a/source/blender/editors/space_outliner/outliner_select.c
+++ b/source/blender/editors/space_outliner/outliner_select.c
@@ -928,7 +928,7 @@ static bool outliner_item_is_co_within_close_toggle(TreeElement *te, float view_
 
 static bool outliner_is_co_within_restrict_columns(const SpaceOops *soops, const ARegion *ar, float view_co_x)
 {
-	return ((soops->outlinevis != SO_DATABLOCKS) &&
+	return ((soops->outlinevis != SO_DATA_API) &&
 	        !(soops->flag & SO_HIDE_RESTRICTCOLS) &&
 	        (view_co_x > ar->v2d.cur.xmax - OL_TOG_RESTRICT_VIEWX));
 }
diff --git a/source/blender/editors/space_outliner/outliner_tree.c b/source/blender/editors/space_outliner/outliner_tree.c
index de8ee5420e7..d9e985bf73e 100644
--- a/source/blender/editors/space_outliner/outliner_tree.c
+++ b/source/blender/editors/space_outliner/outliner_tree.c
@@ -2058,7 +2058,7 @@ void outliner_build_tree(Main *mainvar, Scene *scene, ViewLayer *view_layer, Spa
 	/* Are we looking for something - we want to tag parents to filter child matches
 	 * - NOT in datablocks view - searching all datablocks takes way too long to be useful
 	 * - this variable is only set once per tree build */
-	if (soops->search_string[0] != 0 && soops->outlinevis != SO_DATABLOCKS)
+	if (soops->search_string[0] != 0 && soops->outlinevis != SO_DATA_API)
 		soops->search_flags |= SO_SEARCH_RECURSIVE;
 	else
 		soops->search_flags &= ~SO_SEARCH_RECURSIVE;
@@ -2171,7 +2171,7 @@ void outliner_build_tree(Main *mainvar, Scene *scene, ViewLayer *view_layer, Spa
 			seq = seq->next;
 		}
 	}
-	else if (soops->outlinevis == SO_DATABLOCKS) {
+	else if (soops->outlinevis == SO_DATA_API) {
 		PointerRNA mainptr;
 
 		RNA_main_pointer_create(mainvar, &mainptr);
diff --git a/source/blender/makesdna/DNA_space_types.h b/source/blender/makesdna/DNA_space_types.h
index 4e8c6f7684b..ac6a364b508 100644
--- a/source/blender/makesdna/DNA_space_types.h
+++ b/source/blender/makesdna/DNA_space_types.h
@@ -338,7 +338,7 @@ typedef enum eSpaceOutliner_Mode {
 	/* SO_VERSE_SESSION  = 8, */  /* deprecated! */
 	/* SO_VERSE_MS       = 9, */  /* deprecated! */
 	SO_SEQUENCE       = 10,
-	SO_DATABLOCKS     = 11,
+	SO_DATA_API       = 11,
 	/* SO_USERDEF        = 12, */  /* deprecated! */
 	/* SO_KEYMAP      = 13, */    /* deprecated! */
 	SO_ID_ORPHANS     = 14,
diff --git a/source/blender/makesrna/intern/rna_space.c b/source/blender/makesrna/intern/rna_space.c
index f62d6c61fff..f77ab7d9fc9 100644
--- a/source/blender/makesrna/intern/rna_space.c
+++ b/source/blender/makesrna/intern/rna_space.c
@@ -2076,7 +2076,7 @@ static void rna_def_space_outliner(BlenderRNA *brna)
 		{SO_GROUPS, "GROUPS", 0, "Groups", "Display groups and their data-blocks"},
 		{SO_SEQUENCE, "SEQUENCE", 0, "Sequence", "Display sequence data-blocks"},
 		{SO_LIBRARIES, "LIBRARIES", 0, "Blender File", "Display data of current file and linked libraries"},
-		{SO_DATABLOCKS, "DATABLOCKS", 0, "Data-Blocks", "Display all raw data-blocks"},
+		{SO_DATA_API, "DATA_API", 0, "Data API", "Display low level Blender data and its properties"},
 		{SO_ID_ORPHANS, "ORPHAN_DATA", 0, "Orphan Data",
 		                "Display data-blocks which are unused and/or will be lost when the file is reloaded"},
 		{0, NULL, 0, NULL, NULL}



More information about the Bf-blender-cvs mailing list