|
|
@ -18,7 +18,6 @@ fn use_logo(_: bool) -> bool {
|
|
|
|
false
|
|
|
|
false
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#[cfg(not(target_os = "macos"))]
|
|
|
|
#[cfg(not(target_os = "macos"))]
|
|
|
|
fn use_alt(alt: bool) -> bool {
|
|
|
|
fn use_alt(alt: bool) -> bool {
|
|
|
|
alt
|
|
|
|
alt
|
|
|
@ -166,11 +165,14 @@ impl KeyboardManager {
|
|
|
|
.send(UiCommand::Keyboard(keybinding_string))
|
|
|
|
.send(UiCommand::Keyboard(keybinding_string))
|
|
|
|
.expect("Could not send keyboard ui command");
|
|
|
|
.expect("Could not send keyboard ui command");
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
let key_text = if self.alt && cfg!(target_os = "macos") {
|
|
|
|
let is_dead_key = key_event.text_with_all_modifiers().is_some()
|
|
|
|
key_event.text_with_all_modifiers()
|
|
|
|
&& key_event.text.is_none();
|
|
|
|
} else {
|
|
|
|
let key_text =
|
|
|
|
key_event.text
|
|
|
|
if (self.alt || is_dead_key) && cfg!(target_os = "macos") {
|
|
|
|
};
|
|
|
|
key_event.text_with_all_modifiers()
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
key_event.text
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
if let Some(key_text) = key_text {
|
|
|
|
if let Some(key_text) = key_text {
|
|
|
|
// This is not a control key, so we rely upon winit to determine if
|
|
|
|
// This is not a control key, so we rely upon winit to determine if
|
|
|
|