diff --git a/src/app_tray/compositor/cosmic_comp.rs b/src/app_tray/compositor/cosmic_comp.rs index cb82300..864d1c4 100644 --- a/src/app_tray/compositor/cosmic_comp.rs +++ b/src/app_tray/compositor/cosmic_comp.rs @@ -44,9 +44,8 @@ use iced::{ use once_cell::sync::Lazy; use crate::app_tray::{ - self, compositor::{WindowHandle, WindowInfo}, - AppTray, AppTrayMessage, ApplicationGroup, + AppTrayMessage, ApplicationGroup, }; use super::WaylandOutgoing; @@ -506,7 +505,7 @@ pub struct CosmicCompBackend { wayland_sender: Option>, active_workspaces: Vec, output_list: HashMap, - current_output: String, + _current_output: String, // TODO: Get current output } impl CosmicCompBackend { @@ -515,7 +514,7 @@ impl CosmicCompBackend { wayland_sender: None, active_workspaces: Vec::new(), output_list: HashMap::new(), - current_output: "".to_string(), + _current_output: "".to_string(), } } @@ -706,7 +705,7 @@ impl CosmicCompBackend { .iter() .any(|workspace| t_info.workspace.contains(workspace)) && t_info.output.iter().any(|x| { - self.output_list.get(x).is_some_and(|val| { + self.output_list.get(x).is_some_and(|_val| { true // TODO: Output stuff // val.name.as_ref().is_some_and(|n| *n == self.current_output) }) diff --git a/src/app_tray/compositor/mod.rs b/src/app_tray/compositor/mod.rs index 154a7ec..0ccb023 100644 --- a/src/app_tray/compositor/mod.rs +++ b/src/app_tray/compositor/mod.rs @@ -4,8 +4,6 @@ use cctk::toplevel_info::ToplevelInfo; use cosmic_comp::CosmicCompBackend; use cosmic_protocols::toplevel_info::v1::client::zcosmic_toplevel_handle_v1::ZcosmicToplevelHandleV1; -use crate::app_tray::AppTray; - use super::{AppTrayMessage, ApplicationGroup}; pub mod cosmic_comp; diff --git a/src/app_tray/mod.rs b/src/app_tray/mod.rs index d94c5d6..890649a 100644 --- a/src/app_tray/mod.rs +++ b/src/app_tray/mod.rs @@ -6,14 +6,11 @@ use desktop_entry::DesktopEntryCache; use freedesktop_desktop_entry::DesktopEntry; use iced::{ event::{self, listen_with}, - widget::{button, column, row, Container, Rule}, + widget::{button, column, Container}, Background, Border, Color, Element, Length, Radius, Theme, }; -use crate::{ - app_tray::compositor::{CompositorBackend, WaylandOutgoing, WindowHandle, WindowInfo}, - Message, -}; +use crate::app_tray::compositor::{CompositorBackend, WaylandOutgoing, WindowHandle, WindowInfo}; mod compositor; pub mod desktop_entry; @@ -39,18 +36,6 @@ pub enum AppTrayMessage { RemovedSeat(WlSeat), } -#[derive(Clone, Debug)] -pub enum AppTrayRequest { - Window(WindowOperationMessage), -} - -#[derive(Clone, Debug)] -pub enum WindowOperationMessage { - Activate(WindowHandle), - Minimize(WindowHandle), - Launch(String), -} - impl<'a> Default for AppTrayConfig { fn default() -> Self { Self { diff --git a/src/main.rs b/src/main.rs index 1ab6202..df1d1fb 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,13 +1,11 @@ -use app_tray::{AppTray, AppTrayConfig, AppTrayMessage, ApplicationGroup}; -use cctk::wayland_client::protocol::wl_seat::WlSeat; +use app_tray::{AppTray, AppTrayConfig, AppTrayMessage}; use config::PanelConfig; use iced::{ application::{ actions::layer_surface::SctkLayerSurfaceSettings, layer_surface::Anchor, InitialSurface, }, - event::{self, listen_with}, widget::{column, container::Style}, - Application, Background, Color, Command, Element, Radius, Settings, Subscription, Theme, + Application, Background, Color, Command, Radius, Settings, Theme, }; mod app_tray; @@ -30,14 +28,14 @@ fn main() -> Result<(), iced::Error> { #[derive(Clone, Debug)] struct Panel<'a> { - panel_config: PanelConfig, + _panel_config: PanelConfig, app_tray: AppTray<'a>, } impl<'a> Default for Panel<'a> { fn default() -> Self { Self { - panel_config: PanelConfig::default(), + _panel_config: PanelConfig::default(), app_tray: AppTray::new(AppTrayConfig::default()), } }