Skip to content

Focus is stolen when switching tabs in "Open in Editor" mode #4700

@matsumo-and

Description

@matsumo-and

What happened?

When using Cline in "Open in Editor" mode (as a tab panel), the editor steals focus back to Cline's chat input whenever switching between Cline and other code tabs. This makes it difficult to work with multiple files as the focus is constantly pulled back to Cline.

Expected behavior

When switching between tabs, focus should remain on the tab/editor that the user clicked on. The chat input should only be focused when explicitly requested (e.g., via keyboard shortcut Cmd/Ctrl+').

Steps to reproduce

  1. Open Cline in the sidebar
  2. Click "Open in Editor" button (or use the command)
  3. Open any code file in another tab
  4. Click on the code file tab to focus on it
  5. Click back on the Cline tab
  6. Try to click on the code file tab again
  7. Notice that focus is immediately stolen back to Cline's chat input

Relevant API REQUEST output

Provider/Model

none

Operating System

macOS Monterey

System Info

Apple M1 (2020)

Cline Version

3.18.3

Additional context

cline_issue.mov

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions