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

Remove modifiers from keybinding - #5588

#5588
Merged
stefanhaller merged 2 commits into
masterjesseduffield/lazygit:masterfrom
remove-modifiers-from-keybindingjesseduffield/lazygit:remove-modifiers-from-keybindingCopy head branch name to clipboard
May 6, 2026
Merged

Remove modifiers from keybinding#5588
stefanhaller merged 2 commits into
masterjesseduffield/lazygit:masterfrom
remove-modifiers-from-keybindingjesseduffield/lazygit:remove-modifiers-from-keybindingCopy head branch name to clipboard

Conversation

@stefanhaller

Copy link
Copy Markdown
Collaborator

Followup to #5563; I forgot to do this there.

I noticed that it compares key.keyName and key.str separately instead of calling
key.Equals, but instead of deciding whether that's a problem, just delete the
function when nobody needs it.
Modifiers were moved into Key in 22169e2, but the separate Modifier field
on types.Binding and gocui.keybinding was left behind. The keypress matcher
already compares modifiers via Key.Equals, so the old field is never read on
the dispatch path; it just got passed through SetKeybinding and stored.

Drop it from gocui.keybinding, types.Binding, and the SetKeybinding /
DeleteKeybinding signatures, and remove every now-redundant Modifier:
gocui.ModNone struct field. Mouse bindings keep their own Modifier (on
ViewMouseBinding) since that path still consults it.
@stefanhaller stefanhaller added the ignore-for-release This will exclude the PR from release notes label May 6, 2026
@stefanhaller
stefanhaller enabled auto-merge May 6, 2026 07:53
@stefanhaller
stefanhaller merged commit 434abc7 into master May 6, 2026
14 checks passed
@stefanhaller
stefanhaller deleted the remove-modifiers-from-keybinding branch May 6, 2026 07:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ignore-for-release This will exclude the PR from release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

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