From 593d9724079e54a79a5d3c007af826fd6ea9bf6f Mon Sep 17 00:00:00 2001 From: Antonio Vazquez Date: Fri, 6 Dec 2019 16:30:21 +0100 Subject: Fix T72215: Insert Blank Keyframe Active Layer) creates a new frame in all layers The default parameter was saved and the next time the operator was used, if it was used all layers, the default value changed. --- source/blender/editors/gpencil/gpencil_edit.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'source/blender/editors/gpencil') diff --git a/source/blender/editors/gpencil/gpencil_edit.c b/source/blender/editors/gpencil/gpencil_edit.c index 418df724a08..a87db4543e4 100644 --- a/source/blender/editors/gpencil/gpencil_edit.c +++ b/source/blender/editors/gpencil/gpencil_edit.c @@ -1615,6 +1615,8 @@ static int gp_blank_frame_add_exec(bContext *C, wmOperator *op) void GPENCIL_OT_blank_frame_add(wmOperatorType *ot) { + PropertyRNA *prop; + /* identifiers */ ot->name = "Insert Blank Frame"; ot->idname = "GPENCIL_OT_blank_frame_add"; @@ -1626,13 +1628,15 @@ void GPENCIL_OT_blank_frame_add(wmOperatorType *ot) ot->exec = gp_blank_frame_add_exec; ot->poll = gp_add_poll; - /* properties */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; - RNA_def_boolean(ot->srna, - "all_layers", - false, - "All Layers", - "Create blank frame in all layers, not only active"); + + /* properties */ + prop = RNA_def_boolean(ot->srna, + "all_layers", + false, + "All Layers", + "Create blank frame in all layers, not only active"); + RNA_def_property_flag(prop, PROP_SKIP_SAVE); } /* ******************* Delete Active Frame ************************ */ -- cgit v1.2.3