version 1.304, 2020/02/11 07:01:08 |
version 1.305, 2020/02/19 14:25:00 |
|
|
break; |
break; |
} |
} |
c->tty.mouse_drag_flag = 0; |
c->tty.mouse_drag_flag = 0; |
|
goto out; |
return (key); |
|
} |
} |
|
|
/* Convert to a key binding. */ |
/* Convert to a key binding. */ |
|
|
if (key == KEYC_UNKNOWN) |
if (key == KEYC_UNKNOWN) |
return (KEYC_UNKNOWN); |
return (KEYC_UNKNOWN); |
|
|
|
out: |
/* Apply modifiers if any. */ |
/* Apply modifiers if any. */ |
if (b & MOUSE_MASK_META) |
if (b & MOUSE_MASK_META) |
key |= KEYC_ESCAPE; |
key |= KEYC_ESCAPE; |
|
|
if (b & MOUSE_MASK_SHIFT) |
if (b & MOUSE_MASK_SHIFT) |
key |= KEYC_SHIFT; |
key |= KEYC_SHIFT; |
|
|
|
if (log_get_level() != 0) |
|
log_debug("mouse key is %s", key_string_lookup_key (key)); |
return (key); |
return (key); |
} |
} |
|
|
|
|
* Mouse drag is in progress, so fire the callback (now that |
* Mouse drag is in progress, so fire the callback (now that |
* the mouse event is valid). |
* the mouse event is valid). |
*/ |
*/ |
if (key == KEYC_DRAGGING) { |
if ((key & KEYC_MASK_KEY) == KEYC_DRAGGING) { |
c->tty.mouse_drag_update(c, m); |
c->tty.mouse_drag_update(c, m); |
goto out; |
goto out; |
} |
} |