Skip to content

fix: Improve keyboard shortcuts and window management#84

Merged
eyelock merged 2 commits into
mainfrom
fix/keyboard-shortcuts-cmd-w-cmd-q
Jan 25, 2026
Merged

fix: Improve keyboard shortcuts and window management#84
eyelock merged 2 commits into
mainfrom
fix/keyboard-shortcuts-cmd-w-cmd-q

Conversation

@eyelock
Copy link
Copy Markdown
Owner

@eyelock eyelock commented Jan 25, 2026

Summary

Fixes power user keyboard shortcuts to follow standard macOS conventions and improve window management during Phase 1 testing.

Changes

Keyboard Shortcuts

  • Cmd+W: Now closes window (keeps app running, preserves sessions)
    • Standard macOS behavior like Notes, Mail, etc.
    • App stays in dock with dot indicator
    • Can reopen from dock to restore session
  • Cmd+Shift+W: Closes current tab (moved from Cmd+W)
    • Avoids conflict with standard window close
    • More specific action for tab management
  • Cmd+Option+Z: Toggle zoom mode
    • Moved from Cmd+Shift+Z to avoid Redo conflict
    • Cmd+Shift+Z is standard macOS Redo shortcut

Window Management

  • Red X button: Now shows confirmation dialog when terminals running
    • Matches Cmd+Q confirmation behavior
    • Prevents accidental session loss
    • Window closes properly (hides, doesn't minimize)
  • Window close: Properly hides window using orderOut(nil)
    • Previously was minimizing to dock
    • Now correctly closes/hides window

Documentation

  • Updated Docs/Help/keyboard-shortcuts.md with:
    • New "Window & Application" section
    • All current shortcuts organized by category
    • Standard macOS shortcuts (Cmd+M, Cmd+H, Cmd+,)

Testing

All shortcuts tested and working:

  • ✅ Cmd+W closes window, app stays running
  • ✅ Cmd+Shift+W closes current tab
  • ✅ Cmd+Q shows confirmation when terminals running
  • ✅ Red X button shows confirmation and closes window
  • ✅ Cmd+Option+Z toggles zoom mode
  • ✅ No conflicts with standard macOS shortcuts

Technical Details

  • Window delegate setup uses polling to handle SwiftUI window lifecycle
  • windowShouldClose delegate method handles confirmation
  • orderOut(nil) properly hides window without minimizing
  • No breaking changes to existing functionality

🤖 Generated with Claude Code

- Cmd+W now closes window (keeps app running, preserves sessions)
- Cmd+Shift+W closes current tab (moved from Cmd+W)
- Red X button shows confirmation dialog when terminals running
- Cmd+Option+Z for toggle zoom (was Cmd+Shift+Z, avoiding Redo conflict)
- Window close properly hides window without minimizing
- Updated keyboard shortcuts documentation

Fixes power user workflow with standard macOS shortcuts.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@claude
Copy link
Copy Markdown

claude Bot commented Jan 25, 2026

Code review

No issues found. Checked for bugs and CLAUDE.md compliance.

The 'sign' target was removed in PR #83 and merged into the build
process, but the 'debug' target still depended on it, causing:
  make: *** No rule to make target 'sign', needed by 'debug'. Stop.

Fixed by updating debug to depend on 'build' instead.

Caught by Claude Code bot review.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@eyelock eyelock merged commit 50c6fa7 into main Jan 25, 2026
8 checks passed
@eyelock eyelock deleted the fix/keyboard-shortcuts-cmd-w-cmd-q branch January 25, 2026 09:38
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