WIP: some polish over the winit update to 0.29

This commit is contained in:
Olivier Goffart 2023-09-12 08:20:05 +02:00 committed by Olivier Goffart
parent 0fac958ebf
commit 12cd8e71f1
14 changed files with 99 additions and 125 deletions

View file

@ -67,7 +67,7 @@ namespace slint::platform::key_codes {{
"#
)?;
macro_rules! print_key_codes {
($($char:literal # $name:ident # $($qt:ident)|* # $($winit:ident)|* # $($_xkb:ident)|*;)*) => {
($($char:literal # $name:ident # $($qt:ident)|* # $($winit:ident $(($_pos:ident))?)|* # $($_xkb:ident)|*;)*) => {
$(
writeln!(enums_pub, "/// A constant that represents the key code to be used in slint::Window::dispatch_key_press_event()")?;
writeln!(enums_pub, r#"constexpr std::u8string_view {} = u8"\u{:04x}";"#, stringify!($name), $char as u32)?;