chore(cargo): update all crate dependencies
This commit is contained in:
parent
b0cbb54bf2
commit
03c440b97a
17 changed files with 136 additions and 46 deletions
|
|
@ -4,7 +4,7 @@ version = "0.1.0"
|
|||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
open = "5.3.2"
|
||||
open = "5.3.3"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
path = "../../"
|
||||
|
|
|
|||
|
|
@ -7,10 +7,10 @@ edition = "2021"
|
|||
|
||||
[dependencies]
|
||||
once_cell = "1"
|
||||
rust-embed = "8.6.0"
|
||||
rust-embed = "8.11.0"
|
||||
tracing = "0.1"
|
||||
env_logger = "0.10.2"
|
||||
log = "0.4.26"
|
||||
log = "0.4.29"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
git = "https://github.com/pop-os/libcosmic"
|
||||
|
|
|
|||
|
|
@ -8,8 +8,8 @@ default = ["wayland"]
|
|||
wayland = ["libcosmic/wayland"]
|
||||
|
||||
[dependencies]
|
||||
tracing = "0.1.41"
|
||||
tracing-subscriber = "0.3.19"
|
||||
tracing = "0.1.44"
|
||||
tracing-subscriber = "0.3.22"
|
||||
tracing-log = "0.2.0"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ edition = "2021"
|
|||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
||||
chrono = "0.4.40"
|
||||
chrono = "0.4.42"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
path = "../../"
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ version = "0.1.0"
|
|||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
tracing = "0.1.41"
|
||||
tracing-subscriber = "0.3.19"
|
||||
tracing = "0.1.44"
|
||||
tracing-subscriber = "0.3.22"
|
||||
tracing-log = "0.2.0"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
|
|
|
|||
|
|
@ -19,9 +19,9 @@ libcosmic = { path = "../..", features = [
|
|||
"xdg-portal",
|
||||
] }
|
||||
once_cell = "1.21"
|
||||
slotmap = "1.0.7"
|
||||
slotmap = "1.1.1"
|
||||
env_logger = "0.10"
|
||||
log = "0.4.26"
|
||||
log = "0.4.29"
|
||||
|
||||
[dependencies.cosmic-time]
|
||||
git = "https://github.com/pop-os/cosmic-time"
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ version = "0.1.0"
|
|||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
tracing = "0.1.41"
|
||||
tracing-subscriber = "0.3.19"
|
||||
tracing = "0.1.44"
|
||||
tracing-subscriber = "0.3.22"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
path = "../../"
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ version = "0.1.0"
|
|||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
tracing = "0.1.41"
|
||||
tracing-subscriber = "0.3.19"
|
||||
tracing = "0.1.44"
|
||||
tracing-subscriber = "0.3.22"
|
||||
tracing-log = "0.2.0"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ version = "0.1.0"
|
|||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
tracing = "0.1.41"
|
||||
tracing-subscriber = "0.3.19"
|
||||
tracing = "0.1.44"
|
||||
tracing-subscriber = "0.3.22"
|
||||
tracing-log = "0.2.0"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
|
|
|
|||
|
|
@ -10,10 +10,10 @@ xdg-portal = ["libcosmic/xdg-portal"]
|
|||
|
||||
[dependencies]
|
||||
apply = "0.3.0"
|
||||
tokio = { version = "1.44", features = ["full"] }
|
||||
tracing = "0.1.41"
|
||||
tracing-subscriber = "0.3.19"
|
||||
url = "2.5.4"
|
||||
tokio = { version = "1.49", features = ["full"] }
|
||||
tracing = "0.1.44"
|
||||
tracing-subscriber = "0.3.22"
|
||||
url = "2.5.8"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
features = ["debug", "winit", "wgpu", "wayland", "tokio"]
|
||||
|
|
|
|||
10
examples/subscriptions/Cargo.toml
Normal file
10
examples/subscriptions/Cargo.toml
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[package]
|
||||
name = "subscriptions"
|
||||
version = "0.1.0"
|
||||
edition = "2024"
|
||||
|
||||
[dependencies]
|
||||
|
||||
[dependencies.libcosmic]
|
||||
path = "../../"
|
||||
features = ["debug", "winit", "wgpu", "tokio", "xdg-portal"]
|
||||
80
examples/subscriptions/src/main.rs
Normal file
80
examples/subscriptions/src/main.rs
Normal file
|
|
@ -0,0 +1,80 @@
|
|||
// Copyright 2025 System76 <info@system76.com>
|
||||
// SPDX-License-Identifier: MPL-2.0
|
||||
|
||||
//! Application API example
|
||||
|
||||
use cosmic::app::{Core, Settings, Task};
|
||||
use cosmic::iced::Subscription;
|
||||
use cosmic::{executor, prelude::*, widget};
|
||||
|
||||
/// Runs application with these settings
|
||||
fn main() -> Result<(), Box<dyn std::error::Error>> {
|
||||
cosmic::app::run::<App>(Settings::default(), ())?;
|
||||
Ok(())
|
||||
}
|
||||
|
||||
/// Messages that are used specifically by our [`App`].
|
||||
#[derive(Clone, Debug)]
|
||||
pub enum Message {}
|
||||
|
||||
/// The [`App`] stores application-specific state.
|
||||
pub struct App {
|
||||
core: Core,
|
||||
}
|
||||
|
||||
/// Implement [`cosmic::Application`] to integrate with COSMIC.
|
||||
impl cosmic::Application for App {
|
||||
/// Default async executor to use with the app.
|
||||
type Executor = executor::Default;
|
||||
|
||||
/// Argument received [`cosmic::Application::new`].
|
||||
type Flags = ();
|
||||
|
||||
/// Message type specific to our [`App`].
|
||||
type Message = Message;
|
||||
|
||||
/// The unique application ID to supply to the window manager.
|
||||
const APP_ID: &'static str = "org.cosmic.TextInputsDemo";
|
||||
|
||||
fn core(&self) -> &Core {
|
||||
&self.core
|
||||
}
|
||||
|
||||
fn core_mut(&mut self) -> &mut Core {
|
||||
&mut self.core
|
||||
}
|
||||
|
||||
/// Creates the application, and optionally emits task on initialize.
|
||||
fn init(core: Core, _input: Self::Flags) -> (Self, Task<Self::Message>) {
|
||||
let mut app = App { core };
|
||||
|
||||
let commands = Task::batch(vec![app.update_title()]);
|
||||
|
||||
(app, commands)
|
||||
}
|
||||
|
||||
fn subscription(&self) -> Subscription<Self::Message> {
|
||||
Subscription::none()
|
||||
}
|
||||
|
||||
/// Handle application events here.
|
||||
fn update(&mut self, message: Self::Message) -> Task<Self::Message> {
|
||||
Task::none()
|
||||
}
|
||||
|
||||
/// Creates a view after each update.
|
||||
fn view(&self) -> Element<'_, Self::Message> {
|
||||
widget::row().into()
|
||||
}
|
||||
}
|
||||
|
||||
impl App
|
||||
where
|
||||
Self: cosmic::Application,
|
||||
{
|
||||
fn update_title(&mut self) -> Task<Message> {
|
||||
let window_title = format!("COSMIC Subscriptions Demo");
|
||||
self.set_header_title(window_title.clone());
|
||||
self.set_window_title(window_title, self.core.main_window_id().unwrap())
|
||||
}
|
||||
}
|
||||
|
|
@ -4,8 +4,8 @@ version = "0.1.0"
|
|||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
tracing = "0.1.37"
|
||||
tracing-subscriber = "0.3.17"
|
||||
tracing = "0.1.44"
|
||||
tracing-subscriber = "0.3.22"
|
||||
tracing-log = "0.2.0"
|
||||
chrono = "*"
|
||||
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ version = "0.1.0"
|
|||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
tracing = "0.1.41"
|
||||
tracing-subscriber = "0.3.19"
|
||||
tracing = "0.1.44"
|
||||
tracing-subscriber = "0.3.22"
|
||||
tracing-log = "0.2.0"
|
||||
|
||||
[dependencies.libcosmic]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue