From 0c302e8d23d067e3b4dfe4e079b50012751069cd Mon Sep 17 00:00:00 2001 From: Andrea Ciliberti Date: Tue, 2 Jan 2024 16:26:43 +0100 Subject: [PATCH] Fix lints --- ctru-rs/examples/file-explorer.rs | 2 +- ctru-rs/examples/mii-selector.rs | 2 +- ctru-rs/src/applets/swkbd.rs | 6 ++++++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/ctru-rs/examples/file-explorer.rs b/ctru-rs/examples/file-explorer.rs index 3ad37c9..49855ab 100644 --- a/ctru-rs/examples/file-explorer.rs +++ b/ctru-rs/examples/file-explorer.rs @@ -165,7 +165,7 @@ impl<'a> FileExplorer<'a> { fn get_input_and_run(&mut self, action: impl FnOnce(&mut Self, String)) { let mut keyboard = SoftwareKeyboard::default(); - match keyboard.get_string(2048) { + match keyboard.get_string(2048, &self.apt, &self.gfx) { Ok((path, Button::Right)) => { // Clicked "OK". action(self, path); diff --git a/ctru-rs/examples/mii-selector.rs b/ctru-rs/examples/mii-selector.rs index 3b2b0ef..55b6b15 100644 --- a/ctru-rs/examples/mii-selector.rs +++ b/ctru-rs/examples/mii-selector.rs @@ -21,7 +21,7 @@ fn main() { mii_selector.set_title("Great Mii Selector!"); // Launch the Mii Selector and use its result to print the selected Mii's information. - match mii_selector.launch() { + match mii_selector.launch(&apt, &gfx) { Ok(result) => { println!("Mii type: {:?}", result.mii_type); println!("Name: {:?}", result.mii_data.name); diff --git a/ctru-rs/src/applets/swkbd.rs b/ctru-rs/src/applets/swkbd.rs index b4a2ba3..768d942 100644 --- a/ctru-rs/src/applets/swkbd.rs +++ b/ctru-rs/src/applets/swkbd.rs @@ -710,6 +710,12 @@ impl Default for SoftwareKeyboard { } } +impl Default for ParentalLock { + fn default() -> Self { + ParentalLock::new() + } +} + impl Display for Error { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { match self {