Skip to content

Add edit menu to enable select all shortcut in macOS file dialog#668

Open
for13to1 wants to merge 1 commit into
IENT:developfrom
for13to1:fix/macos-cmd-a-select-all-in-file-dialog
Open

Add edit menu to enable select all shortcut in macOS file dialog#668
for13to1 wants to merge 1 commit into
IENT:developfrom
for13to1:fix/macos-cmd-a-select-all-in-file-dialog

Conversation

@for13to1

Copy link
Copy Markdown
Contributor

On macOS, the native file dialog (NSOpenPanel) does not handle keyboard shortcuts like Cmd+A (Select All) on its own. It requires the parent application to have an Edit menu with a corresponding action linked to the selectAll: selector.

This PR adds a standard Edit menu (Undo, Redo, Cut, Copy, Paste, and Select All) to MainWindow.

Each action is dynamically dispatched to the currently focused widget via QMetaObject::invokeMethod using their platform-standard QKeySequence (which makes the shortcut work in the native file dialog and ensures it is locale-safe).

@for13to1

Copy link
Copy Markdown
Contributor Author

#667

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