# terminal_view: Fix focusing of center-pane terminals \(\#37359\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/7327ef662b0012c29f11db283ca422f474752a72)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 7327ef662b0012c29f11db283ca422f474752a72

Requested commit: 7327ef662b0012c29f11db283ca422f474752a72

Commit: 7327ef662b0012c29f11db283ca422f474752a72

Tree: f45ffda963a1dacff125a1ed501cafab83c545f2

Author: Moritz von Göwels

Committer: GitHub

## Message

```
terminal_view: Fix focusing of center-pane terminals (#37359)

With `reveal_stragegy=always` + `reveal_target=center`,
`TerminalPanel::spawn_task` activates & focuses the pane of the task.
This works fine in the terminal pane but doesn't for
`reveal_target=center`.

Please note: I'm not verified familiar with the architecture and
internal APIs of zed. If there's a better way or if this fix is a bad
idea, I'm fine with adapting this 😃

Closes #35908

Release Notes:

- Fixed task focus when re-spawning a task with `reveal_target=center`

---------

Co-authored-by: Marshall Bowers <git@maxdeviant.com>
```

## Parents

- [c1ca7303a86362e3b985c37e296bb28c31a351a6](https://git.cafe/gitcafe/zed/commit/c1ca7303a86362e3b985c37e296bb28c31a351a6?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/7327ef662b0012c29f11db283ca422f474752a72?format=markdown)
