Ensure we dont double copy

This commit is contained in:
Kovid Goyal
2026-05-29 07:52:38 +05:30
parent d6b662e706
commit 52b44f4f1a

View File

@@ -221,9 +221,9 @@ class Mappings:
# On macOS copy_or_noop is mapped to Cmd+C by default and gets
# disabled when there is no copyable text so special case it
# and pass it on.
if is_macos:
if is_macos and (w := get_boss().active_window):
for action in global_key_action:
if action.definition == 'copy_or_noop':
if action.definition == 'copy_or_noop' and not w.screen.has_selection():
return False
return True
if key_action is None: