From 11f9552b967b128f6530615c6ca68141144bf08c Mon Sep 17 00:00:00 2001 From: bunnie Date: Sun, 14 Jan 2024 22:53:45 +0800 Subject: [PATCH] don't format key lookup tables --- services/keyboard/src/mappings/azerty.rs | 3 ++- services/keyboard/src/mappings/dvorak.rs | 1 + services/keyboard/src/mappings/qwerty.rs | 1 + services/keyboard/src/mappings/qwertz.rs | 1 + 4 files changed, 5 insertions(+), 1 deletion(-) diff --git a/services/keyboard/src/mappings/azerty.rs b/services/keyboard/src/mappings/azerty.rs index f47c3f6a2..fa3ba2e27 100644 --- a/services/keyboard/src/mappings/azerty.rs +++ b/services/keyboard/src/mappings/azerty.rs @@ -1,6 +1,7 @@ use crate::{RowCol, ScanCode}; /// Compute the azerty key mapping of row/col to key tuples +#[rustfmt::skip] pub(crate) fn map_azerty(code: RowCol) -> ScanCode { let rc = (code.r, code.c); @@ -70,4 +71,4 @@ pub(crate) fn map_azerty(code: RowCol) -> ScanCode { _ => ScanCode {key: None, shift: None, hold: None, alt: None} } -} \ No newline at end of file +} diff --git a/services/keyboard/src/mappings/dvorak.rs b/services/keyboard/src/mappings/dvorak.rs index dde975bb0..c1406e3cb 100644 --- a/services/keyboard/src/mappings/dvorak.rs +++ b/services/keyboard/src/mappings/dvorak.rs @@ -1,5 +1,6 @@ use crate::{RowCol, ScanCode}; /// Compute the dvorak key mapping of row/col to key tuples +#[rustfmt::skip] pub(crate) fn map_dvorak(code: RowCol) -> ScanCode { let rc = (code.r, code.c); diff --git a/services/keyboard/src/mappings/qwerty.rs b/services/keyboard/src/mappings/qwerty.rs index af100e3ae..42a5e9b35 100644 --- a/services/keyboard/src/mappings/qwerty.rs +++ b/services/keyboard/src/mappings/qwerty.rs @@ -1,6 +1,7 @@ use crate::{RowCol, ScanCode}; /// Compute the qwerty key mapping of row/col to key tuples +#[rustfmt::skip] pub(crate) fn map_qwerty(code: RowCol) -> ScanCode { let rc = (code.r, code.c); diff --git a/services/keyboard/src/mappings/qwertz.rs b/services/keyboard/src/mappings/qwertz.rs index 490b1ee6c..7e474ec40 100644 --- a/services/keyboard/src/mappings/qwertz.rs +++ b/services/keyboard/src/mappings/qwertz.rs @@ -1,6 +1,7 @@ use crate::{RowCol, ScanCode}; /// Compute the qwertz key mapping of row/col to key tuples +#[rustfmt::skip] pub(crate) fn map_qwertz(code: RowCol) -> ScanCode { let rc = (code.r, code.c);