Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Add distinct macOS Command and platform Shortcut keys - #4129

#4129
Open
ifromstone wants to merge 3 commits into
FlaxEngine:masterFlaxEngine/FlaxEngine:masterfrom
ifromstone:dev/MacOSCommandKeyHandlingifromstone/FlaxEngine:dev/MacOSCommandKeyHandlingCopy head branch name to clipboard
Open

Add distinct macOS Command and platform Shortcut keys#4129
ifromstone wants to merge 3 commits into
FlaxEngine:masterFlaxEngine/FlaxEngine:masterfrom
ifromstone:dev/MacOSCommandKeyHandlingifromstone/FlaxEngine:dev/MacOSCommandKeyHandlingCopy head branch name to clipboard

Conversation

@ifromstone

@ifromstone ifromstone commented May 30, 2026

Copy link
Copy Markdown
Contributor

Summary

This change adds proper macOS Command key support while preserving Control as a distinct physical key. It introduces a logical KeyboardKeys.Shortcut modifier, which resolves to Command on macOS and Control on other platforms, and updates editor default shortcuts to use that logical modifier.

Motivation

Previously, macOS Command was treated like Control in several places. That made common editor shortcuts such as Command+C/Command+V unreliable and also made it impossible to distinguish physical Control from Command. On macOS, these keys have different meanings: Command is the primary application shortcut modifier, while Control remains a separate modifier used by text editing and other workflows.

What Changed

  • Added KeyboardKeys.Command for the physical Apple Command key.
  • Added KeyboardKeys.Shortcut for platform-default application shortcuts.
  • Resolved Shortcut centrally in input queries:
    • macOS: Shortcut -> Command
    • other platforms: Shortcut -> Control
  • Updated editor default bindings from Control-based shortcuts to Shortcut-based shortcuts.
  • Updated shortcut display code so menus and tooltips show platform-friendly labels.
  • Updated input binding capture so pressing the platform shortcut key stores Shortcut rather than a physical Command/Control binding.
  • Fixed macOS text input so Command combinations do not also insert text characters.
  • Updated text box handling so editor-configured bindings are respected, and Command+Backspace follows macOS text editing behavior.
  • Fixes a macOS-specific stuck-key case for Command shortcuts.

Notes

This does not migrate existing user settings. Existing customized bindings remain as-is, while reset/default settings use Shortcut.

Physical Control still means Control on macOS. A user can explicitly bind Control+C/Control+V (for example), and those bindings will not be treated as Command+C/Command+V.

Introduce KeyboardKeys.Command as the physical macOS Command key and
KeyboardKeys.Shortcut as the platform-default shortcut modifier. Editor
default shortcuts now use Shortcut so they map to Command on macOS and
Control elsewhere, while physical Control remains distinct.
@mafiesto4 mafiesto4 added enhancement New feature or request platform input User input (keyboard, mouse, gamepads, touch) labels May 31, 2026
@mafiesto4 mafiesto4 added this to the 1.13 milestone May 31, 2026
Track non-modifier keys pressed while Command is held on macOS and release them
when Command is released.
@ifromstone
ifromstone marked this pull request as draft June 1, 2026 21:52
@ifromstone
ifromstone marked this pull request as ready for review June 3, 2026 17:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request input User input (keyboard, mouse, gamepads, touch) platform

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.