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:
authorRedMser <RedMser>2022-07-12 13:56:53 +0300
committerSybren A. Stüvel <sybren@blender.org>2022-07-12 14:00:56 +0300
commit4344b2bf19e5f678de0d2cd5311a10390f123578 (patch)
treeca7cb78faeae0ef0ab6efe535de114c9e13b026d /source/blender/editors/animation/anim_markers.c
parent52b7f2b089071a6d2281e369ab820c9406e06c4e (diff)
Markers: Make delete confirmation depend on key used
Add a 'Delete Confirmation' operator property to the 'Delete Marker' operator. This determines whether the user is asked to confirm the deletion or not. Defaults so that only {key X} ({key Backspace} for industry compatible keymap) prompts for deletion, whereas {key Del} does not show the confirmation popup. This also makes the default keymap for marker deletion consistent with the common delete operators (such as objects and keyframes). Reviewed By: sybren Differential Revision: https://developer.blender.org/D13818
Diffstat (limited to 'source/blender/editors/animation/anim_markers.c')
-rw-r--r--source/blender/editors/animation/anim_markers.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/animation/anim_markers.c b/source/blender/editors/animation/anim_markers.c
index 03a2caf4b7d..3608140a29d 100644
--- a/source/blender/editors/animation/anim_markers.c
+++ b/source/blender/editors/animation/anim_markers.c
@@ -1588,12 +1588,13 @@ static void MARKER_OT_delete(wmOperatorType *ot)
ot->idname = "MARKER_OT_delete";
/* api callbacks */
- ot->invoke = WM_operator_confirm;
+ ot->invoke = WM_operator_confirm_or_exec;
ot->exec = ed_marker_delete_exec;
ot->poll = ed_markers_poll_selected_no_locked_markers;
/* flags */
ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
+ WM_operator_properties_confirm_or_exec(ot);
}
/** \} */