Skip to content

Add Alt+Tab / Alt+Shift+Tab window-switching navigation actions - #1

Merged
badcode64 merged 1 commit into
badcode64:mainfrom
bhasden:feature/alt-tab-window-switching
Aug 14, 2026
Merged

Add Alt+Tab / Alt+Shift+Tab window-switching navigation actions#1
badcode64 merged 1 commit into
badcode64:mainfrom
bhasden:feature/alt-tab-window-switching

Conversation

@bhasden

@bhasden bhasden commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Adds four new NavigationAction presets under the existing "Navigation Action" mapping type, so Windows switchers can map Alt+Tab / Alt+Shift+Tab to macOS window/app switching without hand-crafting a raw key-swap rule:
    • Switch App → ⌘Tab
    • Switch Window → ⌘` (cycles windows within the frontmost app)
    • Switch App (Reverse) → ⇧⌘Tab
    • Switch Window (Reverse) → ⇧⌘` (for going back with Alt+Shift+Tab)
  • Adds matching localizedName branches and translated strings for all 14 supported languages in Localization.swift, following the existing action* naming/dictionary pattern.

Test plan

  • swiftc compiles cleanly (both files, arm64 target, no warnings)
  • ./build.sh produces a signed universal BC64Keys.app
  • Manually verified in the running app: created a Navigation Action rule with source Option+Tab → Switch App, and Option+Shift+Tab → Switch App (Reverse); both trigger the expected macOS behavior
  • Maintainer review of translation strings (best-effort, not native-speaker verified)

Windows users expect Alt+Tab to cycle windows/apps. Add four new
NavigationAction presets so this can be mapped without needing raw
key-swap rules: Switch App (⌘Tab), Switch Window (⌘`), and their
reverse (⇧⌘Tab / ⇧⌘`) counterparts for going back. Localized in all
14 supported languages.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings August 12, 2026 18:43

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR adds new preset NavigationActions to support Windows-style Alt+Tab / Alt+Shift+Tab window/app switching mappings, along with localized display strings so users can select these actions without creating raw key-swap rules.

Changes:

  • Adds four new NavigationAction presets for app/window switching (forward and reverse) using ⌘Tab and ⌘`.
  • Extends NavigationAction.localizedName to provide localized UI labels for the new actions.
  • Adds new L10n entries (and translations) for the four “Switch *” action labels.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
Sources/BC64Keys/Localization.swift Adds actionSwitchApp, actionSwitchWindow, and reverse variants with translations used by the UI.
Sources/BC64Keys/BC64KeysApp.swift Adds new NavigationAction presets and localized-name mapping branches for the new switch actions.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@bhasden

bhasden commented Aug 12, 2026

Copy link
Copy Markdown
Contributor Author

@badcode64 Please let me know if you'd like this PR done differently. I tried to adhere to the CONTRIBUTING.md guidelines. I commonly switch back and forth between Windows and MacOS and your BC64Keys app has helped simplify that transition. An Alt+Tab mapping was one of the first things I ran up against that wasn't supported. I couldn't use the key swap functionality because MacOS kept taking over the Cmd+Tab target keypress. Let me know if I missed some existing functionality somewhere.

@badcode64

Copy link
Copy Markdown
Owner

Hi @bhasden — thanks for using BC64Keys, and thanks for the PR. It's well put together, I'll review it as soon as I can.

The Alt+Tab mapping is a good idea. The reason I never added it myself is that I use a separate app of mine for window switching:

BadCode64 Window Manager

It handles app switching, and also switching between multiple windows of the same app — so if you have several projects open in Cursor or VS Code, it can cycle through those too. You might find it useful alongside BC64Keys.

That said, having the presets built into BC64Keys makes sense for people who don't want a second app running, so I'm not against the change at all. I'll get back to you after I've gone through the diff.

@bhasden

bhasden commented Aug 13, 2026

Copy link
Copy Markdown
Contributor Author

Hi @bhasden — thanks for using BC64Keys, and thanks for the PR. It's well put together, I'll review it as soon as I can.

The Alt+Tab mapping is a good idea. The reason I never added it myself is that I use a separate app of mine for window switching:

BadCode64 Window Manager

It handles app switching, and also switching between multiple windows of the same app — so if you have several projects open in Cursor or VS Code, it can cycle through those too. You might find it useful alongside BC64Keys.

That said, having the presets built into BC64Keys makes sense for people who don't want a second app running, so I'm not against the change at all. I'll get back to you after I've gone through the diff.

Well that makes sense. Thanks for the link. I'll check out the separate Window Manager app.

@badcode64
badcode64 merged commit 1a31135 into badcode64:main Aug 14, 2026
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.

3 participants