Rename dbus. Add asus_armoury client source

This commit is contained in:
Luke D. Jones
2024-12-26 21:36:07 +13:00
parent 62aa1fe04f
commit a1a9c7077a
29 changed files with 203 additions and 131 deletions

View File

@@ -151,10 +151,7 @@ impl CtrlAnime<'static> {
pub async fn add_to_server(self, server: &mut zbus::Connection) {
server
.object_server()
.at(
&ObjectPath::from_str_unchecked("/org/asuslinux/Anime"),
self,
)
.at(&ObjectPath::from_str_unchecked("/xyz/ljones/Anime"), self)
.await
.map_err(|err| {
println!("CtrlAnime: add_to_server {}", err);
@@ -170,7 +167,7 @@ impl CtrlAnime<'static> {
// - Do actions
// - Write config if required
// - Unset inner_early_return
#[interface(name = "org.asuslinux.Daemon")]
#[interface(name = "xyz.ljones.Asusd")]
impl CtrlAnime<'static> {
pub fn insert_asus_gif(
&mut self,

View File

@@ -42,7 +42,7 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
let early_return = Arc::new(AtomicBool::new(false));
// Set up the anime data and run loop/thread
if supported.contains(&"org.asuslinux.Anime".to_string()) {
if supported.contains(&"xyz.ljones.Anime".to_string()) {
if let Some(cfg) = config.active_anime {
let anime_type = get_anime_type();
let anime_config = ConfigAnime::new().set_name(cfg).load();

View File

@@ -1,8 +1,8 @@
//! # `DBus` interface proxy for: `org.asuslinux.Daemon`
//! # `DBus` interface proxy for: `xyz.ljones.Asusd`
//!
//! This code was generated by `zbus-xmlgen` `1.0.0` from `DBus` introspection
//! data. Source: `Interface '/org/asuslinux/Anime' from service
//! 'org.asuslinux.Daemon' on session bus`.
//! data. Source: `Interface '/xyz/ljones/Anime' from service
//! 'xyz.ljones.Asusd' on session bus`.
//!
//! You may prefer to adapt it, instead of using it verbatim.
//!
@@ -23,10 +23,7 @@
use zbus::proxy;
#[proxy(
interface = "org.asuslinux.Daemon",
default_path = "/org/asuslinux/Anime"
)]
#[proxy(interface = "xyz.ljones.Asusd", default_path = "/xyz/ljones/Anime")]
trait Daemon {
/// InsertAsusGif method
fn insert_asus_gif(