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:
authorAntony Riakiotakis <kalast@gmail.com>2014-09-18 14:07:17 +0400
committerAntony Riakiotakis <kalast@gmail.com>2014-09-18 14:07:17 +0400
commitb247e19ff10c74c756ec94b3d4f910383190f172 (patch)
tree703c16f7c890aae6a67543bf412c51a386e79eb5 /source/blender/editors/sculpt_paint/paint_ops.c
parente6271d236752b8551d8d401ff6aff8e92efde18e (diff)
Palettes
* Remove some duplication in deletion code * Fix crash when restoring file from last saved state.
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_ops.c')
-rw-r--r--source/blender/editors/sculpt_paint/paint_ops.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_ops.c b/source/blender/editors/sculpt_paint/paint_ops.c
index 90161fa87dd..9eaaf5fe122 100644
--- a/source/blender/editors/sculpt_paint/paint_ops.c
+++ b/source/blender/editors/sculpt_paint/paint_ops.c
@@ -228,8 +228,9 @@ static int palette_color_delete_exec(bContext *C, wmOperator *UNUSED(op))
{
Paint *paint = BKE_paint_get_active_from_context(C);
Palette *palette = paint->palette;
+ PaletteColor *color = BLI_findlink(&palette->colors, palette->active_color);
- BKE_palette_color_delete(palette);
+ BKE_palette_color_remove(palette, color);
return OPERATOR_FINISHED;
}