mirror of
https://github.com/Zedfrigg/ironbar.git
synced 2025-09-15 19:26:58 +02:00
refactor: update to rust 2024, fix strict clippy warnings
This commit is contained in:
parent
79c917857c
commit
202c19efd4
57 changed files with 132 additions and 124 deletions
|
@ -1,4 +1,4 @@
|
|||
use crate::{await_sync, Ironbar};
|
||||
use crate::{Ironbar, await_sync};
|
||||
use color_eyre::Result;
|
||||
use std::collections::HashMap;
|
||||
use std::path::Path;
|
||||
|
@ -129,16 +129,14 @@ impl Clients {
|
|||
}
|
||||
|
||||
#[cfg(feature = "hyprland")]
|
||||
pub fn hyprland(&mut self) -> ClientResult<compositor::hyprland::Client> {
|
||||
let client = if let Some(client) = &self.hyprland {
|
||||
pub fn hyprland(&mut self) -> Arc<compositor::hyprland::Client> {
|
||||
if let Some(client) = &self.hyprland {
|
||||
client.clone()
|
||||
} else {
|
||||
let client = Arc::new(compositor::hyprland::Client::new());
|
||||
self.hyprland.replace(client.clone());
|
||||
client
|
||||
};
|
||||
|
||||
Ok(client)
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "cairo")]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue