From cac438a786cf221a907104e6c5b63028845b90b4 Mon Sep 17 00:00:00 2001 From: Ashley Wulber Date: Wed, 15 Feb 2023 10:40:52 -0500 Subject: [PATCH] cleanup(bluetooth): remove some dbg! statements & fix typos --- ...com.system76.CosmicAppletBluetooth.desktop | 10 ++--- cosmic-applet-bluetooth/src/app.rs | 40 +++++++++---------- cosmic-applet-bluetooth/src/config.rs | 2 +- 3 files changed, 26 insertions(+), 26 deletions(-) diff --git a/cosmic-applet-bluetooth/data/com.system76.CosmicAppletBluetooth.desktop b/cosmic-applet-bluetooth/data/com.system76.CosmicAppletBluetooth.desktop index 677183e1..c53075cb 100644 --- a/cosmic-applet-bluetooth/data/com.system76.CosmicAppletBluetooth.desktop +++ b/cosmic-applet-bluetooth/data/com.system76.CosmicAppletBluetooth.desktop @@ -1,12 +1,12 @@ [Desktop Entry] -Name=Cosmic Applet Network -Comment=Write a GTK + Rust application +Name=Cosmic Applet Bluetooth +Comment=COSMIC Panel Applet for managing bluetooth Type=Application Exec=cosmic-applet-bluetooth Terminal=false -Categories=GNOME;GTK; -Keywords=Gnome;GTK; +Categories=COSMIC;Iced; +Keywords=COSMIC;Iced; # Translators: Do NOT translate or transliterate this text (this is an icon file name)! -Icon=com.system76.CosmicAppletNetwork.svg +Icon=com.system76.CosmicAppletBluetooth.svg StartupNotify=true NoDisplay=true diff --git a/cosmic-applet-bluetooth/src/app.rs b/cosmic-applet-bluetooth/src/app.rs index da3a44fa..8d884442 100644 --- a/cosmic-applet-bluetooth/src/app.rs +++ b/cosmic-applet-bluetooth/src/app.rs @@ -165,44 +165,44 @@ impl Application for CosmicBluetoothApplet { } // TODO handle agent events BluerEvent::AgentEvent(event) => match event { - crate::bluetooth::BluerAgentEvent::DisplayPinCode(d, code) => { - dbg!((d.name, code)); + crate::bluetooth::BluerAgentEvent::DisplayPinCode(_d, _code) => { + // dbg!((d.name, code)); } - crate::bluetooth::BluerAgentEvent::DisplayPasskey(d, code) => { - dbg!((d.name, code)); + crate::bluetooth::BluerAgentEvent::DisplayPasskey(_d, _code) => { + // dbg!((d.name, code)); } - crate::bluetooth::BluerAgentEvent::RequestPinCode(d) => { + crate::bluetooth::BluerAgentEvent::RequestPinCode(_d) => { // TODO anything to be done here? - dbg!("request pin code", d.name); + // dbg!("request pin code", d.name); } - crate::bluetooth::BluerAgentEvent::RequestPasskey(d) => { + crate::bluetooth::BluerAgentEvent::RequestPasskey(_d) => { // TODO anything to be done here? - dbg!("request passkey", d.name); + // dbg!("request passkey", d.name); } crate::bluetooth::BluerAgentEvent::RequestConfirmation(d, code, tx) => { - dbg!("request confirmation", &d.name, &code); + // dbg!("request confirmation", &d.name, &code); self.request_confirmation.replace((d, code, tx)); // let _ = tx.send(false); } - crate::bluetooth::BluerAgentEvent::RequestDeviceAuthorization(d, _tx) => { + crate::bluetooth::BluerAgentEvent::RequestDeviceAuthorization(_d, _tx) => { // TODO anything to be done here? - dbg!("request device authorization", d.name); + // dbg!("request device authorization", d.name); // let_ = tx.send(false); } crate::bluetooth::BluerAgentEvent::RequestServiceAuthorization( - d, - service, + _d, + _service, _tx, ) => { // my headphones seem to always request this // doesn't seem to be defined in the UX mockups - dbg!( - "request service authorization", - d.name, - bluer::id::Service::try_from(service) - .map(|s| s.to_string()) - .unwrap_or_else(|_| "unknown".to_string()) - ); + // dbg!( + // "request service authorization", + // d.name, + // bluer::id::Service::try_from(service) + // .map(|s| s.to_string()) + // .unwrap_or_else(|_| "unknown".to_string()) + // ); } }, }, diff --git a/cosmic-applet-bluetooth/src/config.rs b/cosmic-applet-bluetooth/src/config.rs index 42153094..356affb6 100644 --- a/cosmic-applet-bluetooth/src/config.rs +++ b/cosmic-applet-bluetooth/src/config.rs @@ -1,3 +1,3 @@ -pub const APP_ID: &str = "com.system76.CosmicAppletNetwork"; +pub const APP_ID: &str = "com.system76.CosmicAppletBluetooth"; pub const PROFILE: &str = ""; pub const VERSION: &str = "0.1.0";