Fix new warnings

This commit is contained in:
2025-10-17 23:52:56 -04:00
parent 0a8da6bff0
commit c00fae79f8
5 changed files with 4 additions and 15 deletions
-6
View File
@@ -457,12 +457,6 @@ struct PersistedGamepadMapping {
default_axes: Vec<(Code, (VBKey, VBKey))>,
}
#[derive(Serialize, Deserialize)]
pub struct Shortcut {
pub shortcut: KeyboardShortcut,
pub command: Command,
}
#[derive(Clone, Copy, Serialize, Deserialize, PartialEq, Eq, Hash)]
pub enum Command {
OpenRom,
+2 -2
View File
@@ -50,11 +50,11 @@ impl MemoryClient {
}
fn aligned_memory(start: u32, length: usize) -> BoxBytes {
if start % 4 == 0 && length % 4 == 0 {
if start.is_multiple_of(4) && length.is_multiple_of(4) {
let memory = vec![0u32; length / 4].into_boxed_slice();
return bytemuck::box_bytes_of(memory);
}
if start % 2 == 0 && length % 2 == 0 {
if start.is_multiple_of(2) && length.is_multiple_of(2) {
let memory = vec![0u16; length / 2].into_boxed_slice();
return bytemuck::box_bytes_of(memory);
}
-6
View File
@@ -274,12 +274,6 @@ impl AppWindow for CharacterDataWindow {
}
}
#[derive(Serialize, Deserialize, Clone, PartialEq, Eq, Hash)]
enum CharDataResource {
Character { palette: Palette, index: usize },
CharacterData { palette: Palette },
}
#[derive(Clone, Default, PartialEq, Eq)]
struct CharDataParams {
palette: Palette,