Avoid capturing mouse press when text_editor is unfocused
This commit is contained in:
parent
ea8696eac2
commit
a7bc1e7da4
1 changed files with 4 additions and 2 deletions
|
|
@ -768,6 +768,10 @@ where
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if !matches!(binding, Binding::Unfocus) {
|
||||||
|
shell.capture_event();
|
||||||
|
}
|
||||||
|
|
||||||
apply_binding(
|
apply_binding(
|
||||||
binding,
|
binding,
|
||||||
self.content,
|
self.content,
|
||||||
|
|
@ -780,8 +784,6 @@ where
|
||||||
if let Some(focus) = &mut state.focus {
|
if let Some(focus) = &mut state.focus {
|
||||||
focus.updated_at = Instant::now();
|
focus.updated_at = Instant::now();
|
||||||
}
|
}
|
||||||
|
|
||||||
shell.capture_event();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue