From c83d37ccc07c40813e44658857fc79886099b485 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Wed, 13 Jun 2012 08:35:50 +0000 Subject: mango request - highlight active mask layers. - remove keyframes when all layer data is removed. --- source/blender/editors/mask/mask_ops.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'source/blender/editors/mask') diff --git a/source/blender/editors/mask/mask_ops.c b/source/blender/editors/mask/mask_ops.c index 7c94b79010c..315e40380f9 100644 --- a/source/blender/editors/mask/mask_ops.c +++ b/source/blender/editors/mask/mask_ops.c @@ -957,6 +957,12 @@ static int delete_exec(bContext *C, wmOperator *UNUSED(op)) spline = next_spline; } + + /* not essential but confuses users when there are keys with no data! + * assume if they delete all data from the layer they also dont care about keys */ + if (masklay->splines.first == NULL) { + BKE_mask_layer_free_shapes(masklay); + } } /* TODO: only update edited splines */ -- cgit v1.2.3