[Bf-blender-cvs] [5b5d80e8647] greasepencil-object: Invert thumbnail switch to make UI more consistent

Antonio Vazquez noreply at git.blender.org
Mon Jul 16 18:21:33 CEST 2018


Commit: 5b5d80e8647ece10e22cb047ae62ffb1c0580db2
Author: Antonio Vazquez
Date:   Mon Jul 16 18:21:22 2018 +0200
Branches: greasepencil-object
https://developer.blender.org/rB5b5d80e8647ece10e22cb047ae62ffb1c0580db2

Invert thumbnail switch to make UI more consistent

Also changed icon.

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

M	release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
M	source/blender/makesdna/DNA_scene_types.h
M	source/blender/makesrna/intern/rna_scene.c

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

diff --git a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
index a770b567c9b..10d821eb0dc 100644
--- a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
+++ b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
@@ -992,8 +992,8 @@ class _defs_gpencil_paint:
         gp_settings = brush.gpencil_settings
         ts = context.tool_settings
         row = layout.row(align=True)
-        row.prop(ts, "use_gpencil_compact_list", text="", icon="SORTSIZE")
-        if ts.use_gpencil_compact_list is True:
+        row.prop(ts, "use_gpencil_thumbnail_list", text="", icon="IMGDISPLAY")
+        if ts.use_gpencil_thumbnail_list is False:
             row.template_ID(gp_settings, "material", live_icon=True)
         else:
             row.template_greasepencil_color(gp_settings, "material", rows=3, cols=8, scale=0.8)
diff --git a/source/blender/makesdna/DNA_scene_types.h b/source/blender/makesdna/DNA_scene_types.h
index 84f547c9da3..8b794b6e405 100644
--- a/source/blender/makesdna/DNA_scene_types.h
+++ b/source/blender/makesdna/DNA_scene_types.h
@@ -2047,7 +2047,7 @@ typedef enum eGPencil_Flags {
 	/* Add the strokes below all strokes in the layer */
 	GP_TOOL_FLAG_PAINT_ONBACK           = (1 << 2),
 	/* Show compact list of colors */
-	GP_TOOL_FLAG_COMPACT_LIST           = (1 << 3),
+	GP_TOOL_FLAG_THUMBNAIL_LIST           = (1 << 3),
 } eGPencil_Flags;
 
 /* scene->r.simplify_gpencil */
diff --git a/source/blender/makesrna/intern/rna_scene.c b/source/blender/makesrna/intern/rna_scene.c
index ba3a46b02c9..e4acf445213 100644
--- a/source/blender/makesrna/intern/rna_scene.c
+++ b/source/blender/makesrna/intern/rna_scene.c
@@ -2416,8 +2416,8 @@ static void rna_def_tool_settings(BlenderRNA  *brna)
 		"When draw new strokes, the new stroke is drawn below of all strokes in the layer");
 	RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);
 
-	prop = RNA_def_property(srna, "use_gpencil_compact_list", PROP_BOOLEAN, PROP_NONE);
-	RNA_def_property_boolean_sdna(prop, NULL, "gpencil_flags", GP_TOOL_FLAG_COMPACT_LIST);
+	prop = RNA_def_property(srna, "use_gpencil_thumbnail_list", PROP_BOOLEAN, PROP_NONE);
+	RNA_def_property_boolean_negative_sdna(prop, NULL, "gpencil_flags", GP_TOOL_FLAG_THUMBNAIL_LIST);
 	RNA_def_property_ui_text(prop, "Compact List",
 		"Show compact list of color instead of thumbnails");
 	RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);



More information about the Bf-blender-cvs mailing list