chore: align applets with local stack

This commit is contained in:
Lionel DARNIS 2026-05-23 20:49:24 +02:00
parent bcc8072a3b
commit 82e00a3e16
37 changed files with 292 additions and 440 deletions

View file

@ -12,7 +12,7 @@ drm = "0.14.1"
futures.workspace = true
i18n-embed-fl.workspace = true
i18n-embed.workspace = true
libcosmic.workspace = true
cosmic.workspace = true
rust-embed.workspace = true
rustc-hash.workspace = true
tokio.workspace = true
@ -24,9 +24,7 @@ zbus.workspace = true
serde.workspace = true
[dependencies.cosmic-settings-upower-subscription]
git = "https://github.com/pop-os/cosmic-settings"
# path = "../../cosmic-settings/subscriptions/upower"
path = "../../cosmic-settings/subscriptions/upower"
[dependencies.cosmic-settings-daemon-subscription]
git = "https://github.com/pop-os/cosmic-settings"
# path = "../../cosmic-settings/subscriptions/settings-daemon"
path = "../../cosmic-settings/subscriptions/settings-daemon"

View file

@ -40,7 +40,7 @@ use cosmic_settings_upower_subscription::{
};
use rustc_hash::FxHashMap;
use std::{path::PathBuf, sync::LazyLock, time::Duration};
use std::{path::PathBuf, time::Duration};
use tokio::sync::mpsc::UnboundedSender;
// XXX improve
@ -172,6 +172,7 @@ impl CosmicBatteryApplet {
}
#[derive(Debug, Clone)]
#[allow(dead_code)]
enum Message {
TogglePopup,
CloseRequested(window::Id),
@ -511,7 +512,7 @@ impl cosmic::Application for CosmicBatteryApplet {
Task::none()
}
fn view(&self) -> Element<Message> {
fn view(&self) -> Element<'_, Message> {
let is_horizontal = match self.core.applet.anchor {
PanelAnchor::Top | PanelAnchor::Bottom => true,
PanelAnchor::Left | PanelAnchor::Right => false,