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:
authorCampbell Barton <campbell@blender.org>2022-03-02 06:44:34 +0300
committerCampbell Barton <campbell@blender.org>2022-03-02 06:44:34 +0300
commit78372d8b9ca2e923945a009166b9bc04f74ddadf (patch)
treefa0c464b122fcbb24a706e896154004c816450bc /source/blender/editors/animation
parentaa71414dfca7f301e101cce3e72551e7529290ea (diff)
Event System: support "Release Confirms" for click-drag events
Diffstat (limited to 'source/blender/editors/animation')
-rw-r--r--source/blender/editors/animation/anim_markers.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/editors/animation/anim_markers.c b/source/blender/editors/animation/anim_markers.c
index ab51702d628..95125516fe8 100644
--- a/source/blender/editors/animation/anim_markers.c
+++ b/source/blender/editors/animation/anim_markers.c
@@ -700,7 +700,7 @@ static void MARKER_OT_add(wmOperatorType *ot)
typedef struct MarkerMove {
SpaceLink *slink;
ListBase *markers;
- int event_type; /* store invoke-event, to verify */
+ short event_type, event_val; /* store invoke-event, to verify */
int *oldframe, evtx, firstx;
NumInput num;
} MarkerMove;
@@ -844,6 +844,7 @@ static int ed_marker_move_invoke(bContext *C, wmOperator *op, const wmEvent *eve
mm->evtx = event->xy[0];
mm->firstx = event->xy[0];
mm->event_type = event->type;
+ mm->event_val = event->val;
/* add temp handler */
WM_event_add_modal_handler(C, op);
@@ -941,7 +942,7 @@ static int ed_marker_move_modal(bContext *C, wmOperator *op, const wmEvent *even
case EVT_PADENTER:
case LEFTMOUSE:
case MIDDLEMOUSE:
- if (WM_event_is_modal_tweak_exit(event, mm->event_type)) {
+ if (WM_event_is_modal_drag_exit(event, mm->event_type, mm->event_val)) {
ed_marker_move_exit(C, op);
WM_event_add_notifier(C, NC_SCENE | ND_MARKERS, NULL);
WM_event_add_notifier(C, NC_ANIMATION | ND_MARKERS, NULL);