Fix: Copy register handling for cagire-desktop (Linux)

This commit is contained in:
2026-02-02 18:25:02 +01:00
parent f1902e18d3
commit 0aaa3efbb0
2 changed files with 7 additions and 0 deletions

View File

@@ -20,6 +20,7 @@ All notable changes to this project will be documented in this file.
### Fixed
- Scope/spectrum ratio asymmetry in Left/Right layout modes.
- Updated `cpal` dependency from 0.15 to 0.17 to fix type mismatch with `doux` audio backend.
- Copy/paste (Ctrl+C/V/X) not working in desktop version due to egui intercepting clipboard shortcuts.
## [0.0.3] - 2026-02-02

View File

@@ -40,6 +40,12 @@ fn convert_event(event: &egui::Event) -> Option<KeyEvent> {
}
None
}
// egui intercepts Ctrl+C/V/X and converts them to these high-level events
// instead of passing through raw Key events (see egui issue #4065).
// Synthesize the equivalent KeyEvent so the application's input handler receives them.
egui::Event::Copy => Some(KeyEvent::new(KeyCode::Char('c'), KeyModifiers::CONTROL)),
egui::Event::Cut => Some(KeyEvent::new(KeyCode::Char('x'), KeyModifiers::CONTROL)),
egui::Event::Paste(_) => Some(KeyEvent::new(KeyCode::Char('v'), KeyModifiers::CONTROL)),
_ => None,
}
}