Manage add/remove aura

Serialize aura config filename
This commit is contained in:
Luke D. Jones
2024-03-18 16:22:18 +13:00
parent 014604724f
commit 5c43c31331
30 changed files with 690 additions and 298 deletions

View File

@@ -68,7 +68,7 @@ impl CtrlAnime {
let node = if usb.is_some() {
unsafe { Node::Usb(usb.unwrap_unchecked()) }
} else if hid.is_some() {
unsafe { Node::Hid(hid.unwrap_unchecked()) }
unsafe { Node::Hid(hid.unwrap_unchecked().0) }
} else {
return Err(RogError::Anime(AnimeError::NoDevice));
};

View File

@@ -16,7 +16,7 @@ use super::CtrlAnime;
use crate::error::RogError;
pub const ANIME_ZBUS_NAME: &str = "Anime";
pub const ANIME_ZBUS_PATH: &str = "/org/asuslinux/Anime";
pub const ANIME_ZBUS_PATH: &str = "/org/asuslinux";
async fn get_logind_manager<'a>() -> ManagerProxy<'a> {
let connection = Connection::system()
@@ -43,7 +43,7 @@ impl crate::ZbusRun for CtrlAnimeZbus {
// None of these calls can be guarnateed to succeed unless we loop until okay
// If the try_lock *does* succeed then any other thread trying to lock will not
// grab it until we finish.
#[interface(name = "org.asuslinux.Daemon")]
#[interface(name = "org.asuslinux.Anime")]
impl CtrlAnimeZbus {
/// Writes a data stream of length. Will force system thread to exit until
/// it is restarted