Skip to content

fix: Windows zoom shortcuts and keep chat preview file after workspace tab#982

Merged
su8su merged 3 commits intomainfrom
fix_some_bugs
May 7, 2026
Merged

fix: Windows zoom shortcuts and keep chat preview file after workspace tab#982
su8su merged 3 commits intomainfrom
fix_some_bugs

Conversation

@su8su
Copy link
Copy Markdown
Contributor

@su8su su8su commented May 7, 2026

No description provided.

Copy link
Copy Markdown
Contributor

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b87dc6c694

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".


export function registerZoomShortcuts(win: BrowserWindow): void {
win.webContents.on('before-input-event', (event, input) => {
const action = getZoomShortcutAction(input);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Gate zoom handling to keyDown events

When a user presses a zoom accelerator, Electron's before-input-event is delivered for both keydown and keyup, but this handler maps every input event to an action. For shortcuts such as Ctrl+-/Ctrl+=, the keyup still carries the modifier state, so the zoom level can change twice for one keystroke (for example 0 → -2 instead of 0 → -1). Check input.type === 'keyDown' before applying the zoom action.

Useful? React with 👍 / 👎.

@su8su su8su merged commit fc13237 into main May 7, 2026
5 checks passed
@su8su su8su deleted the fix_some_bugs branch May 7, 2026 03:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant