mirror of
https://github.com/zed-industries/zed.git
synced 2025-01-12 13:24:19 +00:00
Focus terminal view on mouse click in terminal
Before, terminal view focused the parent (pane) instead and, if terminal's search bar was open and focused, pane transferred the focus back
This commit is contained in:
parent
139cbbfd3a
commit
80c779b95e
1 changed files with 2 additions and 1 deletions
|
@ -400,7 +400,8 @@ impl TerminalElement {
|
|||
region = region
|
||||
// Start selections
|
||||
.on_down(MouseButton::Left, move |event, v: &mut TerminalView, cx| {
|
||||
cx.focus_parent();
|
||||
let terminal_view = cx.handle();
|
||||
cx.focus(&terminal_view);
|
||||
v.context_menu.update(cx, |menu, _cx| menu.delay_cancel());
|
||||
if let Some(conn_handle) = connection.upgrade(cx) {
|
||||
conn_handle.update(cx, |terminal, cx| {
|
||||
|
|
Loading…
Reference in a new issue