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:
authorAntonioya <blendergit@gmail.com>2018-08-28 09:16:30 +0300
committerAntonioya <blendergit@gmail.com>2018-08-28 09:18:09 +0300
commit9a9b1e98849131358041cf2bb83bf7b7c9828119 (patch)
tree290cba0b98a1c6937670d8f578c189039123700a /source/blender/makesrna/intern/rna_brush.c
parent039b11f3497731572e36904b03550438b706df34 (diff)
GP: Revert replace custom function by standard API
Using custom api breaks material at object level
Diffstat (limited to 'source/blender/makesrna/intern/rna_brush.c')
-rw-r--r--source/blender/makesrna/intern/rna_brush.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/source/blender/makesrna/intern/rna_brush.c b/source/blender/makesrna/intern/rna_brush.c
index bc5b1fa7f13..3df84a3a85b 100644
--- a/source/blender/makesrna/intern/rna_brush.c
+++ b/source/blender/makesrna/intern/rna_brush.c
@@ -171,7 +171,6 @@ static EnumPropertyItem rna_enum_gpencil_brush_icons_items[] = {
#include "BKE_colorband.h"
#include "BKE_brush.h"
#include "BKE_icons.h"
-#include "BKE_material.h"
#include "BKE_gpencil.h"
#include "BKE_paint.h"
@@ -426,7 +425,7 @@ static void rna_Brush_material_update(bContext *C, PointerRNA *ptr)
BrushGpencilSettings *gpencil_settings = br->gpencil_settings;
if (gpencil_settings->material != NULL) {
- index = BKE_object_material_slot_find_index(ob, gpencil_settings->material);
+ index = BKE_gpencil_get_material_index(ob, gpencil_settings->material);
if ((index > 0) && (ob->actcol != index)) {
ob->actcol = index;
/* update other brushes to keep all synchro */