chore: updates after iced-rebase
This commit is contained in:
parent
bd0d180482
commit
71d9d6d5bb
41 changed files with 1786 additions and 2396 deletions
|
|
@ -23,7 +23,7 @@ use cosmic::{
|
|||
iced_core::{Background, Border},
|
||||
scroll::DiscreteScrollState,
|
||||
surface,
|
||||
widget::{Id, autosize, container, horizontal_space, vertical_space},
|
||||
widget::{Id, autosize, container, space},
|
||||
};
|
||||
|
||||
use crate::{
|
||||
|
|
@ -196,10 +196,10 @@ impl cosmic::Application for IcedWorkspacesApplet {
|
|||
(suggested_window_size.0.get() as f32, suggested_total as f32)
|
||||
};
|
||||
|
||||
let content = row!(content, vertical_space().height(Length::Fixed(height)))
|
||||
let content = row!(content, space::vertical().height(Length::Fixed(height)))
|
||||
.align_y(Alignment::Center);
|
||||
|
||||
let content = column!(content, horizontal_space().width(Length::Fixed(width)))
|
||||
let content = column!(content, space::horizontal().width(Length::Fixed(width)))
|
||||
.align_x(Alignment::Center);
|
||||
|
||||
let btn = button(
|
||||
|
|
@ -323,7 +323,7 @@ impl cosmic::Application for IcedWorkspacesApplet {
|
|||
])
|
||||
}
|
||||
|
||||
fn style(&self) -> Option<cosmic::iced_runtime::Appearance> {
|
||||
fn style(&self) -> Option<cosmic::iced::theme::Style> {
|
||||
Some(cosmic::applet::style())
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,16 +22,15 @@ pub enum WorkspacesUpdate {
|
|||
}
|
||||
|
||||
pub fn workspaces() -> iced::Subscription<WorkspacesUpdate> {
|
||||
Subscription::run_with_id(
|
||||
std::any::TypeId::of::<WorkspacesUpdate>(),
|
||||
Subscription::run_with(std::any::TypeId::of::<WorkspacesUpdate>(), |_| {
|
||||
stream::channel(50, move |mut output| async move {
|
||||
let mut state = State::Waiting;
|
||||
|
||||
loop {
|
||||
state = start_listening(state, &mut output).await;
|
||||
}
|
||||
}),
|
||||
)
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
async fn start_listening(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue