Fix two mouse event bugs (#2835)
This PR fixes two bugs we discovered in Zed's mouse event handling while investigating an interesting and mysterious bug we we were seeing, where spurious `MouseMoved` events would continuously be dispatched after control-clicking. Release Notes: - Fixed a rendering glitch that could occur after control-clicking certain elements.
This commit is contained in:
commit
40030f32d9
3 changed files with 14 additions and 6 deletions
|
@ -1087,7 +1087,10 @@ extern "C" fn handle_view_event(this: &Object, _: Sel, native_event: id) {
|
|||
button: MouseButton::Left,
|
||||
modifiers: Modifiers { ctrl: true, .. },
|
||||
..
|
||||
}) => return,
|
||||
}) => {
|
||||
window_state_borrow.synthetic_drag_counter += 1;
|
||||
return;
|
||||
}
|
||||
|
||||
_ => None,
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue