Fix T55568: second click event ignored

Double-click handling caused the second click to be ignored
for keymaps that only handle click.
This commit is contained in:
Campbell Barton 2018-06-21 10:58:03 +02:00
parent f1bc9331b1
commit b681461c84
Notes: blender-bot 2023-02-14 06:42:53 +01:00
Referenced by issue #55568, Pressing tab twice fast doesn't toggle edit mode twice
1 changed files with 7 additions and 0 deletions

View File

@ -2329,6 +2329,13 @@ static int wm_handlers_do(bContext *C, wmEvent *event, ListBase *handlers)
else if (event->val == KM_DBL_CLICK) {
event->val = KM_PRESS;
action |= wm_handlers_do_intern(C, event, handlers);
event->val = KM_RELEASE;
action |= wm_handlers_do_intern(C, event, handlers);
if (wm_action_not_handled(action)) {
event->val = KM_CLICK;
action |= wm_handlers_do_intern(C, event, handlers);
}
/* revert value if not handled */
if (wm_action_not_handled(action)) {