Compare commits

...

11 commits

Author SHA1 Message Date
6f514db1b4 chore: use local cosmic-text checkout 2026-05-25 11:34:55 +02:00
331aba9d95 yoda: use local dbus settings bindings 2026-05-25 09:55:11 +02:00
f19473a05c chore: align subscriptions with local stack 2026-05-23 20:49:24 +02:00
16172ad5a3 yoda: relocate local fork paths from ~/Devels to ~/Projets/COSMIC
Mise à jour des path= absolus (libcosmic, cosmic-config, cosmic-theme,
iced_futures/winit, window_clipboard, dnd, mime, cosmic-text) après
consolidation des forks cosmic-* sous ~/Projets/COSMIC/.

Inclut subscriptions/sound/Cargo.toml (libcosmic-yoda).

Leyoda 2026 – GPLv3
2026-05-16 18:08:59 +02:00
d8a5350fee yoda wayland-v5: redirect window_clipboard + cosmic-text to local forks
Propagates the [patch] blocks added in cosmic-yoterm v5 to keep the
whole yoda app family on a single Wayland-only stack. Without these,
iced_winit fails to select a window_clipboard version because our
fork exposes a `wayland` feature that upstream doesn't.

- window_clipboard → /home/lionel/Devels/window_clipboard (x11 gated
  behind opt-in feature)
- cosmic-text → /home/lionel/Devels/cosmic-text (EAW terminal_cells +
  upstream PR#503 applied)
2026-04-24 07:09:49 +02:00
546299dbb7 lockfile: libcosmic-yoda 0.1.0-yoda -> 0.1.0-yoda.2
Picks up the yoda-v2 libcosmic changes (color_picker Theme ref +
context_menu/menu winit ungate). Binary rebuilt and installed.
2026-04-23 18:46:17 +02:00
999e2ba4e5 yoda: rebase onto libcosmic-yoda via path deps + macOS controls toggle
Fresh rewiring from upstream master (78644a3) — the previous attempt on
051f4f9 was 137 commits behind and hit API drift (cosmic::iced_futures,
Subscription::run_with_id). Upstream master uses the newer API
(cosmic::iced::stream + Subscription::run_with) which our libcosmic-yoda
already supports.

Yoda wiring:
- [workspace.dependencies.libcosmic] (git pop-os) -> libcosmic-yoda { path, wayland }
- cosmic-config + iced_winit workspace deps -> path to libcosmic-yoda submodule
- [patch.pop-os/libcosmic] redirects transitive cosmic-config + cosmic-theme +
  iced_futures + iced_winit to our local paths so the graph resolves to a
  single copy (cosmic-bg/comp/idle/panel configs unify cleanly against master)
- subscriptions/sound + page + cosmic-settings inner Cargo.toml: libcosmic ->
  libcosmic-yoda (workspace + direct variants)
- winit feature dropped from libcosmic-yoda deps (our fork is Wayland-only)

Cherry-picked from leyoda/local/window-controls-position @ 52ce463:
- cosmic-settings/src/pages/desktop/window_management.rs — macOS toggle UI
- i18n/en + fr/cosmic_settings.ftl — translations

Installed at /usr/bin/cosmic-settings (yoda build, 78 MB).
Pre-yoda pacman version kept at /usr/bin/cosmic-settings.pre-yoda-fork.
2026-04-23 17:33:22 +02:00
Ashley Wulber
78644a32e3
Revert "Changes the PageInner.size field to have no explicit default.… (#1977)
… It is only initialized (not None) when PageInner.panel_config is
initialized. This implementation fails faster and more verbose, when
program is in an unintended state."

This reverts commit ba5fb65b44.

- [x] I have disclosed use of any AI generated code in my commit
messages.
- If you are using an LLM, and do not fully understand the changes it is
making to the code base, do not create a PR.
- In our experience, AI generated code often results in overly complex
code that lacks enough context for a proper fix or feature inclusion.
This results in considerably longer code reviews. Due to this, AI
authored or partially authored PRs may be closed without comment.
- [x] I understand these changes in full and will be able to respond to
review comments.
- [x] My change is accurately described in the commit message.
- [x] My contribution is tested and working as described.
- [x] I have read the [Developer Certificate of
Origin](https://developercertificate.org/) and certify my contribution
under its conditions.

Co-authored-by: Levi Portenier <levi@system76.com>
2026-04-22 14:33:37 -06:00
Tony Wasserka
c04e49e218 fix(wallpapers): follow symlinks when scanning wallpaper directories
On NixOS, /run/current-system/sw/share/backgrounds lists all wallpapers
installed on the system. The folder entries are symbolic links to the actual
PNG files (each in a dedicated nix store path). Previously WalkDir would skip
over these, resulting in cosmic-settings displaying an empty wallpaper list.

By following symbolic links, the list is now properly populated.
2026-04-22 22:10:24 +02:00
Vukašin Vojinović
26f0fb0609 chore(default_apps): reduce code duplication
Also fixes the flex items wrapping too early by setting the FlexRow width to Shrink.
2026-04-22 22:10:06 +02:00
Vukašin Vojinović
317de19eb3 fix(shortcuts): modified count for accessibility and tiling
These weren't being set previously, so they never showed up.
Also updates remaining things here to use ListButton.
2026-04-22 22:10:06 +02:00
28 changed files with 220 additions and 579 deletions

226
Cargo.lock generated
View file

@ -104,7 +104,6 @@ dependencies = [
[[package]] [[package]]
name = "accounts-zbus" name = "accounts-zbus"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"zbus", "zbus",
] ]
@ -355,12 +354,6 @@ version = "0.7.6"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7c02d123df017efcdfbd739ef81735b36c5ba83ec3c59c80a9d7ecc718f92e50" checksum = "7c02d123df017efcdfbd739ef81735b36c5ba83ec3c59c80a9d7ecc718f92e50"
[[package]]
name = "as-raw-xcb-connection"
version = "1.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "175571dd1d178ced59193a6fc02dde1b972eb0bc56c892cde9beeceac5bf0f6b"
[[package]] [[package]]
name = "as-slice" name = "as-slice"
version = "0.2.1" version = "0.2.1"
@ -831,7 +824,6 @@ dependencies = [
[[package]] [[package]]
name = "bluez-zbus" name = "bluez-zbus"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"futures-channel", "futures-channel",
"futures-util", "futures-util",
@ -1135,7 +1127,6 @@ dependencies = [
[[package]] [[package]]
name = "clipboard_macos" name = "clipboard_macos"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/window_clipboard.git?tag=sctk-0.20#f68595ee0e62fbd6589f4709b5aaa5c3c7ea5f6c"
dependencies = [ dependencies = [
"objc", "objc",
"objc-foundation", "objc-foundation",
@ -1145,22 +1136,12 @@ dependencies = [
[[package]] [[package]]
name = "clipboard_wayland" name = "clipboard_wayland"
version = "0.2.2" version = "0.2.2"
source = "git+https://github.com/pop-os/window_clipboard.git?tag=sctk-0.20#f68595ee0e62fbd6589f4709b5aaa5c3c7ea5f6c"
dependencies = [ dependencies = [
"dnd", "dnd",
"mime 0.1.0", "mime 0.1.0",
"smithay-clipboard", "smithay-clipboard",
] ]
[[package]]
name = "clipboard_x11"
version = "0.4.2"
source = "git+https://github.com/pop-os/window_clipboard.git?tag=sctk-0.20#f68595ee0e62fbd6589f4709b5aaa5c3c7ea5f6c"
dependencies = [
"thiserror 1.0.69",
"x11rb",
]
[[package]] [[package]]
name = "cocoa" name = "cocoa"
version = "0.25.0" version = "0.25.0"
@ -1199,7 +1180,7 @@ checksum = "fe6d2e5af09e8c8ad56c969f2157a3d4238cebc7c55f0a517728c38f7b200f81"
dependencies = [ dependencies = [
"serde", "serde",
"termcolor", "termcolor",
"unicode-width 0.1.14", "unicode-width 0.2.2",
] ]
[[package]] [[package]]
@ -1369,7 +1350,7 @@ version = "0.1.0"
source = "git+https://github.com/pop-os/cosmic-protocols//?rev=d0e95be#d0e95be25e423cfe523b11111a3666ed7aaf0dc4" source = "git+https://github.com/pop-os/cosmic-protocols//?rev=d0e95be#d0e95be25e423cfe523b11111a3666ed7aaf0dc4"
dependencies = [ dependencies = [
"bitflags 2.11.1", "bitflags 2.11.1",
"cosmic-protocols", "cosmic-protocols 0.1.0",
"libc", "libc",
"smithay-client-toolkit", "smithay-client-toolkit",
"wayland-client", "wayland-client",
@ -1391,7 +1372,6 @@ dependencies = [
[[package]] [[package]]
name = "cosmic-config" name = "cosmic-config"
version = "1.0.0" version = "1.0.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"atomicwrites", "atomicwrites",
"cosmic-config-derive", "cosmic-config-derive",
@ -1412,7 +1392,6 @@ dependencies = [
[[package]] [[package]]
name = "cosmic-config-derive" name = "cosmic-config-derive"
version = "1.0.0" version = "1.0.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"quote", "quote",
"syn 2.0.117", "syn 2.0.117",
@ -1421,7 +1400,6 @@ dependencies = [
[[package]] [[package]]
name = "cosmic-dbus-a11y" name = "cosmic-dbus-a11y"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"zbus", "zbus",
] ]
@ -1429,7 +1407,6 @@ dependencies = [
[[package]] [[package]]
name = "cosmic-dbus-networkmanager" name = "cosmic-dbus-networkmanager"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"bitflags 2.11.1", "bitflags 2.11.1",
"derive_builder", "derive_builder",
@ -1514,12 +1491,25 @@ dependencies = [
"wayland-server", "wayland-server",
] ]
[[package]]
name = "cosmic-protocols"
version = "0.2.0"
dependencies = [
"bitflags 2.11.1",
"wayland-backend",
"wayland-client",
"wayland-protocols",
"wayland-protocols-wlr",
"wayland-scanner",
"wayland-server",
]
[[package]] [[package]]
name = "cosmic-randr" name = "cosmic-randr"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/cosmic-randr#6e8e795970fa06d434af22775e415b517f7552d3" source = "git+https://github.com/pop-os/cosmic-randr#6e8e795970fa06d434af22775e415b517f7552d3"
dependencies = [ dependencies = [
"cosmic-protocols", "cosmic-protocols 0.1.0",
"indexmap 2.14.0", "indexmap 2.14.0",
"thiserror 2.0.18", "thiserror 2.0.18",
"tokio", "tokio",
@ -1556,7 +1546,7 @@ dependencies = [
"cosmic-idle-config", "cosmic-idle-config",
"cosmic-mime-apps", "cosmic-mime-apps",
"cosmic-panel-config", "cosmic-panel-config",
"cosmic-protocols", "cosmic-protocols 0.1.0",
"cosmic-randr", "cosmic-randr",
"cosmic-randr-shell", "cosmic-randr-shell",
"cosmic-settings-a11y-manager-subscription", "cosmic-settings-a11y-manager-subscription",
@ -1588,7 +1578,7 @@ dependencies = [
"itertools 0.14.0", "itertools 0.14.0",
"itoa", "itoa",
"jiff", "jiff",
"libcosmic", "libcosmic-yoda",
"locale1", "locale1",
"locales-rs", "locales-rs",
"mime 0.3.17", "mime 0.3.17",
@ -1627,7 +1617,7 @@ dependencies = [
name = "cosmic-settings-a11y-manager-subscription" name = "cosmic-settings-a11y-manager-subscription"
version = "1.0.7" version = "1.0.7"
dependencies = [ dependencies = [
"cosmic-protocols", "cosmic-protocols 0.2.0",
"iced_futures", "iced_futures",
"num-derive", "num-derive",
"num-traits", "num-traits",
@ -1686,8 +1676,7 @@ dependencies = [
[[package]] [[package]]
name = "cosmic-settings-daemon" name = "cosmic-settings-daemon"
version = "0.1.0" version = "0.1.1-yoda.1"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"zbus", "zbus",
] ]
@ -1737,7 +1726,7 @@ version = "1.0.7"
dependencies = [ dependencies = [
"derive_setters", "derive_setters",
"downcast-rs 2.0.2", "downcast-rs 2.0.2",
"libcosmic", "libcosmic-yoda",
"regex", "regex",
"slab", "slab",
"slotmap", "slotmap",
@ -1762,7 +1751,7 @@ dependencies = [
"cosmic-pipewire", "cosmic-pipewire",
"futures", "futures",
"intmap", "intmap",
"libcosmic", "libcosmic-yoda",
"numtoa", "numtoa",
"rustix 1.1.4", "rustix 1.1.4",
"tokio", "tokio",
@ -1803,8 +1792,7 @@ dependencies = [
[[package]] [[package]]
name = "cosmic-text" name = "cosmic-text"
version = "0.18.2" version = "0.19.0"
source = "git+https://github.com/pop-os/cosmic-text.git#4d74f795cc771fdcc7ea0f9cacba63fcf036fad6"
dependencies = [ dependencies = [
"bitflags 2.11.1", "bitflags 2.11.1",
"fontdb", "fontdb",
@ -1822,12 +1810,12 @@ dependencies = [
"unicode-linebreak", "unicode-linebreak",
"unicode-script", "unicode-script",
"unicode-segmentation", "unicode-segmentation",
"unicode-width 0.2.2",
] ]
[[package]] [[package]]
name = "cosmic-theme" name = "cosmic-theme"
version = "1.0.0" version = "1.0.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"almost", "almost",
"configparser", "configparser",
@ -1940,12 +1928,6 @@ dependencies = [
"uncased", "uncased",
] ]
[[package]]
name = "ctor-lite"
version = "0.1.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e162d0c2e2068eb736b71e5597eff0b9944e6b973cd9f37b6a288ab9bf20e300"
[[package]] [[package]]
name = "cursor-icon" name = "cursor-icon"
version = "1.2.0" version = "1.2.0"
@ -2202,7 +2184,6 @@ dependencies = [
[[package]] [[package]]
name = "dnd" name = "dnd"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/window_clipboard.git?tag=sctk-0.20#f68595ee0e62fbd6589f4709b5aaa5c3c7ea5f6c"
dependencies = [ dependencies = [
"bitflags 2.11.1", "bitflags 2.11.1",
"mime 0.1.0", "mime 0.1.0",
@ -2237,45 +2218,6 @@ name = "dpi"
version = "0.1.2" version = "0.1.2"
source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366" source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366"
[[package]]
name = "drm"
version = "0.11.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a0f8a69e60d75ae7dab4ef26a59ca99f2a89d4c142089b537775ae0c198bdcde"
dependencies = [
"bitflags 2.11.1",
"bytemuck",
"drm-ffi",
"drm-fourcc",
"rustix 0.38.44",
]
[[package]]
name = "drm-ffi"
version = "0.7.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "41334f8405792483e32ad05fbb9c5680ff4e84491883d2947a4757dc54cb2ac6"
dependencies = [
"drm-sys",
"rustix 0.38.44",
]
[[package]]
name = "drm-fourcc"
version = "2.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0aafbcdb8afc29c1a7ee5fbe53b5d62f4565b35a042a662ca9fecd0b54dae6f4"
[[package]]
name = "drm-sys"
version = "0.6.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2d09ff881f92f118b11105ba5e34ff8f4adf27b30dae8f12e28c193af1c83176"
dependencies = [
"libc",
"linux-raw-sys 0.6.5",
]
[[package]] [[package]]
name = "dyn-clone" name = "dyn-clone"
version = "1.0.20" version = "1.0.20"
@ -2820,16 +2762,6 @@ dependencies = [
"version_check", "version_check",
] ]
[[package]]
name = "gethostname"
version = "1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1bd49230192a3797a9a4d6abe9b3eed6f7fa4c8a8a4947977c6f80025f92cbd8"
dependencies = [
"rustix 1.1.4",
"windows-link 0.2.1",
]
[[package]] [[package]]
name = "getrandom" name = "getrandom"
version = "0.2.17" version = "0.2.17"
@ -3151,7 +3083,6 @@ checksum = "f558a64ac9af88b5ba400d99b579451af0d39c6d360980045b91aac966d705e2"
[[package]] [[package]]
name = "hostname1-zbus" name = "hostname1-zbus"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"zbus", "zbus",
] ]
@ -3250,7 +3181,6 @@ dependencies = [
[[package]] [[package]]
name = "iced" name = "iced"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"dnd", "dnd",
"iced_accessibility", "iced_accessibility",
@ -3271,7 +3201,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_accessibility" name = "iced_accessibility"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"accesskit", "accesskit",
"accesskit_winit", "accesskit_winit",
@ -3280,7 +3209,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_core" name = "iced_core"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"bitflags 2.11.1", "bitflags 2.11.1",
"bytes", "bytes",
@ -3305,7 +3233,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_debug" name = "iced_debug"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"iced_core", "iced_core",
"iced_futures", "iced_futures",
@ -3315,7 +3242,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_futures" name = "iced_futures"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"futures", "futures",
"iced_core", "iced_core",
@ -3329,7 +3255,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_graphics" name = "iced_graphics"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"bitflags 2.11.1", "bitflags 2.11.1",
"bytemuck", "bytemuck",
@ -3350,7 +3275,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_program" name = "iced_program"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"iced_graphics", "iced_graphics",
"iced_runtime", "iced_runtime",
@ -3359,7 +3283,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_renderer" name = "iced_renderer"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"iced_graphics", "iced_graphics",
"iced_tiny_skia", "iced_tiny_skia",
@ -3371,7 +3294,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_runtime" name = "iced_runtime"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"bytes", "bytes",
"cosmic-client-toolkit", "cosmic-client-toolkit",
@ -3387,7 +3309,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_tiny_skia" name = "iced_tiny_skia"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"bytemuck", "bytemuck",
"cosmic-text", "cosmic-text",
@ -3404,9 +3325,7 @@ dependencies = [
[[package]] [[package]]
name = "iced_wgpu" name = "iced_wgpu"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"as-raw-xcb-connection",
"bitflags 2.11.1", "bitflags 2.11.1",
"bytemuck", "bytemuck",
"cosmic-client-toolkit", "cosmic-client-toolkit",
@ -3423,19 +3342,16 @@ dependencies = [
"rustc-hash 2.1.2", "rustc-hash 2.1.2",
"rustix 0.38.44", "rustix 0.38.44",
"thiserror 2.0.18", "thiserror 2.0.18",
"tiny-xlib",
"wayland-backend", "wayland-backend",
"wayland-client", "wayland-client",
"wayland-protocols", "wayland-protocols",
"wayland-sys", "wayland-sys",
"wgpu", "wgpu",
"x11rb",
] ]
[[package]] [[package]]
name = "iced_widget" name = "iced_widget"
version = "0.14.2" version = "0.14.2"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"cosmic-client-toolkit", "cosmic-client-toolkit",
"dnd", "dnd",
@ -3455,7 +3371,6 @@ dependencies = [
[[package]] [[package]]
name = "iced_winit" name = "iced_winit"
version = "0.14.0" version = "0.14.0"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"cosmic-client-toolkit", "cosmic-client-toolkit",
"cursor-icon", "cursor-icon",
@ -4565,9 +4480,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "52ff2c0fe9bc6cb6b14a0592c2ff4fa9ceb83eea9db979b0487cd054946a2b8f" checksum = "52ff2c0fe9bc6cb6b14a0592c2ff4fa9ceb83eea9db979b0487cd054946a2b8f"
[[package]] [[package]]
name = "libcosmic" name = "libcosmic-yoda"
version = "1.0.0" version = "0.1.0-yoda.2"
source = "git+https://github.com/pop-os/libcosmic#3f9e93067b31d9ba81a4e3a28653b3380c61c352"
dependencies = [ dependencies = [
"apply", "apply",
"ashpd 0.12.3", "ashpd 0.12.3",
@ -4743,12 +4657,6 @@ version = "0.4.15"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab"
[[package]]
name = "linux-raw-sys"
version = "0.6.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2a385b1be4e5c3e362ad2ffa73c392e53f031eaa5b7d648e64cd87f27f6063d7"
[[package]] [[package]]
name = "linux-raw-sys" name = "linux-raw-sys"
version = "0.12.1" version = "0.12.1"
@ -4770,7 +4678,6 @@ checksum = "11d3d7f243d5c5a8b9bb5d6dd2b1602c0cb0b9db1621bafc7ed66e35ff9fe092"
[[package]] [[package]]
name = "locale1" name = "locale1"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"zbus", "zbus",
] ]
@ -4981,7 +4888,6 @@ dependencies = [
[[package]] [[package]]
name = "mime" name = "mime"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/window_clipboard.git?tag=sctk-0.20#f68595ee0e62fbd6589f4709b5aaa5c3c7ea5f6c"
dependencies = [ dependencies = [
"smithay-clipboard", "smithay-clipboard",
] ]
@ -5113,7 +5019,6 @@ dependencies = [
[[package]] [[package]]
name = "nm-secret-agent-manager" name = "nm-secret-agent-manager"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"zbus", "zbus",
] ]
@ -7008,12 +6913,10 @@ name = "softbuffer"
version = "0.4.1" version = "0.4.1"
source = "git+https://github.com/pop-os/softbuffer?tag=cosmic-4.0#a3f77e251e7422803f693df6e3fc313c010c4dcb" source = "git+https://github.com/pop-os/softbuffer?tag=cosmic-4.0#a3f77e251e7422803f693df6e3fc313c010c4dcb"
dependencies = [ dependencies = [
"as-raw-xcb-connection",
"bytemuck", "bytemuck",
"cfg_aliases 0.2.1", "cfg_aliases 0.2.1",
"cocoa", "cocoa",
"core-graphics", "core-graphics",
"drm",
"fastrand", "fastrand",
"foreign-types", "foreign-types",
"js-sys", "js-sys",
@ -7023,14 +6926,12 @@ dependencies = [
"raw-window-handle", "raw-window-handle",
"redox_syscall 0.5.18", "redox_syscall 0.5.18",
"rustix 0.38.44", "rustix 0.38.44",
"tiny-xlib",
"wasm-bindgen", "wasm-bindgen",
"wayland-backend", "wayland-backend",
"wayland-client", "wayland-client",
"wayland-sys", "wayland-sys",
"web-sys", "web-sys",
"windows-sys 0.52.0", "windows-sys 0.52.0",
"x11rb",
] ]
[[package]] [[package]]
@ -7351,7 +7252,6 @@ dependencies = [
[[package]] [[package]]
name = "timedate-zbus" name = "timedate-zbus"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"zbus", "zbus",
] ]
@ -7382,19 +7282,6 @@ dependencies = [
"strict-num", "strict-num",
] ]
[[package]]
name = "tiny-xlib"
version = "0.2.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0324504befd01cab6e0c994f34b2ffa257849ee019d3fb3b64fb2c858887d89e"
dependencies = [
"as-raw-xcb-connection",
"ctor-lite",
"libloading",
"pkg-config",
"tracing",
]
[[package]] [[package]]
name = "tinystr" name = "tinystr"
version = "0.8.3" version = "0.8.3"
@ -7754,7 +7641,6 @@ checksum = "ebc1c04c71510c7f702b52b7c350734c9ff1295c464a03335b00bb84fc54f853"
[[package]] [[package]]
name = "upower_dbus" name = "upower_dbus"
version = "0.3.2" version = "0.3.2"
source = "git+https://github.com/pop-os/dbus-settings-bindings#507e342c21d3ce6ae41b1d4f3fa2f0ad5ee23e75"
dependencies = [ dependencies = [
"serde", "serde",
"serde_repr", "serde_repr",
@ -8372,12 +8258,10 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
[[package]] [[package]]
name = "window_clipboard" name = "window_clipboard"
version = "0.4.1" version = "0.4.1"
source = "git+https://github.com/pop-os/window_clipboard.git?tag=sctk-0.20#f68595ee0e62fbd6589f4709b5aaa5c3c7ea5f6c"
dependencies = [ dependencies = [
"clipboard-win", "clipboard-win",
"clipboard_macos", "clipboard_macos",
"clipboard_wayland", "clipboard_wayland",
"clipboard_x11",
"dnd", "dnd",
"mime 0.1.0", "mime 0.1.0",
"raw-window-handle", "raw-window-handle",
@ -8901,7 +8785,6 @@ dependencies = [
"winit-wayland", "winit-wayland",
"winit-web", "winit-web",
"winit-win32", "winit-win32",
"winit-x11",
] ]
[[package]] [[package]]
@ -8952,7 +8835,6 @@ dependencies = [
"smol_str", "smol_str",
"tracing", "tracing",
"winit-core", "winit-core",
"x11-dl",
"xkbcommon-dl", "xkbcommon-dl",
] ]
@ -9070,29 +8952,6 @@ dependencies = [
"winit-core", "winit-core",
] ]
[[package]]
name = "winit-x11"
version = "0.31.0-beta.2"
source = "git+https://github.com/pop-os/winit.git?tag=cosmic-0.14#261cda54017f98a12dc55569c864430fe6770366"
dependencies = [
"bitflags 2.11.1",
"bytemuck",
"calloop",
"cursor-icon",
"dpi",
"libc",
"percent-encoding",
"raw-window-handle",
"rustix 1.1.4",
"smol_str",
"tracing",
"winit-common",
"winit-core",
"x11-dl",
"x11rb",
"xkbcommon-dl",
]
[[package]] [[package]]
name = "winnow" name = "winnow"
version = "0.6.24" version = "0.6.24"
@ -9223,39 +9082,6 @@ dependencies = [
"either", "either",
] ]
[[package]]
name = "x11-dl"
version = "2.21.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "38735924fedd5314a6e548792904ed8c6de6636285cb9fec04d5b1db85c1516f"
dependencies = [
"libc",
"once_cell",
"pkg-config",
]
[[package]]
name = "x11rb"
version = "0.13.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9993aa5be5a26815fe2c3eacfc1fde061fc1a1f094bf1ad2a18bf9c495dd7414"
dependencies = [
"as-raw-xcb-connection",
"gethostname",
"libc",
"libloading",
"once_cell",
"rustix 1.1.4",
"x11rb-protocol",
"xcursor",
]
[[package]]
name = "x11rb-protocol"
version = "0.13.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ea6fc2961e4ef194dcbfe56bb845534d0dc8098940c7e5c012a258bfec6701bd"
[[package]] [[package]]
name = "xcursor" name = "xcursor"
version = "0.3.10" version = "0.3.10"

View file

@ -9,21 +9,23 @@ rust-version = "1.90"
[workspace.dependencies] [workspace.dependencies]
cosmic-randr = { git = "https://github.com/pop-os/cosmic-randr" } cosmic-randr = { git = "https://github.com/pop-os/cosmic-randr" }
tokio = { version = "1.49.0", features = ["macros"] } tokio = { version = "1.49.0", features = ["macros"] }
iced_winit = { git = "https://github.com/pop-os/libcosmic", default-features = false } # Yoda fork: direct path dep on iced_winit in libcosmic-yoda's submodule.
iced_winit = { path = "/home/lionel/Projets/COSMIC/libcosmic/iced/winit", default-features = false }
[workspace.dependencies.libcosmic] # Yoda fork — libcosmic-yoda by path, replaces upstream git dep.
[workspace.dependencies.libcosmic-yoda]
features = [ features = [
"dbus-config", "dbus-config",
"desktop", "desktop",
"multi-window", "multi-window",
"winit", "wayland",
"tokio", "tokio",
"qr_code", "qr_code",
] ]
git = "https://github.com/pop-os/libcosmic" path = "/home/lionel/Projets/COSMIC/libcosmic"
[workspace.dependencies.cosmic-config] [workspace.dependencies.cosmic-config]
git = "https://github.com/pop-os/libcosmic" path = "/home/lionel/Projets/COSMIC/libcosmic/cosmic-config"
[workspace.dependencies.cosmic-bg-config] [workspace.dependencies.cosmic-bg-config]
git = "https://github.com/pop-os/cosmic-bg" git = "https://github.com/pop-os/cosmic-bg"
@ -69,24 +71,25 @@ cosmic-client-toolkit = { git = "https://github.com/pop-os/cosmic-protocols//",
# [patch.'https://github.com/pop-os/cosmic-settings-daemon'] # [patch.'https://github.com/pop-os/cosmic-settings-daemon']
# cosmic-settings-config = { git = "https://github.com/pop-os/cosmic-settings-daemon//", branch = "input_nobuild" } # cosmic-settings-config = { git = "https://github.com/pop-os/cosmic-settings-daemon//", branch = "input_nobuild" }
# For development and testing purposes # Yoda fork: redirect every transitive dep that asks for pop-os/libcosmic
# [patch.'https://github.com/pop-os/libcosmic'] # (cosmic-bg-config, cosmic-comp-config, cosmic-idle-config, cosmic-panel-config,
# libcosmic = { path = "../libcosmic" } # cosmic-settings-config, cosmic-settings-daemon-config) to our local paths so
# cosmic-config = { path = "../libcosmic/cosmic-config" } # the whole graph resolves against a single cosmic-config / cosmic-theme / iced_*.
# cosmic-theme = { path = "../libcosmic/cosmic-theme" } [patch.'https://github.com/pop-os/libcosmic']
# iced_futures = { path = "../libcosmic/iced/futures" } cosmic-config = { path = "/home/lionel/Projets/COSMIC/libcosmic/cosmic-config" }
# iced_winit = { path = "../libcosmic/iced/winit" } cosmic-theme = { path = "/home/lionel/Projets/COSMIC/libcosmic/cosmic-theme" }
iced_futures = { path = "/home/lionel/Projets/COSMIC/libcosmic/iced/futures" }
iced_winit = { path = "/home/lionel/Projets/COSMIC/libcosmic/iced/winit" }
# libcosmic = { git = "https://github.com/pop-os/libcosmic//" } [patch.'https://github.com/pop-os/cosmic-text.git']
# cosmic-config = { git = "https://github.com/pop-os/libcosmic//" } cosmic-text = { path = "../cosmic-text" }
# cosmic-theme = { git = "https://github.com/pop-os/libcosmic//" }
# iced_futures = { git = "https://github.com/pop-os/libcosmic//" }
# iced_winit = { git = "https://github.com/pop-os/libcosmic//" }
# [patch.'https://github.com/pop-os/dbus-settings-bindings'] # Yoda wayland cut v5: redirect window_clipboard to the local fork
# cosmic-dbus-networkmanager = { path = "../dbus-settings-bindings/networkmanager" } # (x11 gated behind opt-in feature).
# upower_dbus = { path = "../dbus-settings-bindings/upower" } [patch.'https://forge.aditua.com/leyoda/window_clipboard.git']
# nm-secret-agent-manager = { git = "https://github.com/pop-os/dbus-settings-bindings//", branch = "nm-secret-agent" } window_clipboard = { path = "/home/lionel/Projets/COSMIC/window_clipboard" }
dnd = { path = "/home/lionel/Projets/COSMIC/window_clipboard/dnd" }
mime = { path = "/home/lionel/Projets/COSMIC/window_clipboard/mime" }
[patch.crates-io] [patch.crates-io]
atspi = { git = "https://github.com/wash2/atspi" } atspi = { git = "https://github.com/wash2/atspi" }

View file

@ -9,7 +9,7 @@ publish = false
xdgen = "0.1" xdgen = "0.1"
[dependencies] [dependencies]
accounts-zbus = { git = "https://github.com/pop-os/dbus-settings-bindings", optional = true } accounts-zbus = { path = "../../dbus-settings-bindings/accounts-zbus", optional = true }
anyhow = "1.0" anyhow = "1.0"
ashpd = { version = "0.12", default-features = false, features = [ ashpd = { version = "0.12", default-features = false, features = [
"tokio", "tokio",
@ -21,8 +21,8 @@ color-eyre = "0.6.5"
cosmic-bg-config.workspace = true cosmic-bg-config.workspace = true
cosmic-comp-config = { workspace = true, optional = true } cosmic-comp-config = { workspace = true, optional = true }
cosmic-config.workspace = true cosmic-config.workspace = true
cosmic-dbus-networkmanager = { git = "https://github.com/pop-os/dbus-settings-bindings", optional = true } cosmic-dbus-networkmanager = { path = "../../dbus-settings-bindings/networkmanager", optional = true }
nm-secret-agent-manager = { git = "https://github.com/pop-os/dbus-settings-bindings", optional = true } nm-secret-agent-manager = { path = "../../dbus-settings-bindings/nm-secret-agent-manager", optional = true }
cosmic-idle-config.workspace = true cosmic-idle-config.workspace = true
cosmic-panel-config = { workspace = true, optional = true } cosmic-panel-config = { workspace = true, optional = true }
cosmic-protocols = { git = "https://github.com/pop-os/cosmic-protocols", optional = true } cosmic-protocols = { git = "https://github.com/pop-os/cosmic-protocols", optional = true }
@ -47,7 +47,7 @@ eyre = "0.6.12"
freedesktop-desktop-entry = "0.8.1" freedesktop-desktop-entry = "0.8.1"
futures = "0.3.32" futures = "0.3.32"
hostname-validator = "1.1.1" hostname-validator = "1.1.1"
hostname1-zbus = { git = "https://github.com/pop-os/dbus-settings-bindings", optional = true } hostname1-zbus = { path = "../../dbus-settings-bindings/hostname1", optional = true }
i18n-embed-fl = "0.10.0" i18n-embed-fl = "0.10.0"
image = { version = "0.25", default-features = false, features = [ image = { version = "0.25", default-features = false, features = [
"jpeg", "jpeg",
@ -59,9 +59,9 @@ image = { version = "0.25", default-features = false, features = [
indexmap = "2.13.0" indexmap = "2.13.0"
itertools = "0.14.0" itertools = "0.14.0"
itoa = "1.0.17" itoa = "1.0.17"
libcosmic.workspace = true libcosmic-yoda.workspace = true
iced_winit.workspace = true iced_winit.workspace = true
locale1 = { git = "https://github.com/pop-os/dbus-settings-bindings", optional = true } locale1 = { path = "../../dbus-settings-bindings/locale1", optional = true }
sysinfo = { version = "=0.38.0", optional = true } sysinfo = { version = "=0.38.0", optional = true }
mime-apps = { package = "cosmic-mime-apps", git = "https://github.com/pop-os/cosmic-mime-apps", optional = true } mime-apps = { package = "cosmic-mime-apps", git = "https://github.com/pop-os/cosmic-mime-apps", optional = true }
notify = "8.2.0" notify = "8.2.0"
@ -75,13 +75,13 @@ slab = "0.4.12"
slotmap = "1.1.1" slotmap = "1.1.1"
static_init = "1.0.4" static_init = "1.0.4"
sunrise = "3.0.0" sunrise = "3.0.0"
timedate-zbus = { git = "https://github.com/pop-os/dbus-settings-bindings", optional = true } timedate-zbus = { path = "../../dbus-settings-bindings/timedate", optional = true }
tokio = { workspace = true, features = ["fs", "io-util", "process", "sync"] } tokio = { workspace = true, features = ["fs", "io-util", "process", "sync"] }
tracing = "0.1.44" tracing = "0.1.44"
tracing-subscriber = { version = "0.3.22", features = ["env-filter"] } tracing-subscriber = { version = "0.3.22", features = ["env-filter"] }
udev = { version = "0.9.3", optional = true } udev = { version = "0.9.3", optional = true }
upower_dbus = { git = "https://github.com/pop-os/dbus-settings-bindings", optional = true } upower_dbus = { path = "../../dbus-settings-bindings/upower", optional = true }
bluez-zbus = { git = "https://github.com/pop-os/dbus-settings-bindings", optional = true } bluez-zbus = { path = "../../dbus-settings-bindings/bluez", optional = true }
url = "2.5.8" url = "2.5.8"
xkb-data = "0.2.2" xkb-data = "0.2.2"
xkeysym = { version = "0.2.1", optional = true } xkeysym = { version = "0.2.1", optional = true }
@ -187,12 +187,12 @@ page-window-management = ["cosmic-comp-config", "dep:cosmic-settings-config"]
page-workspaces = ["cosmic-comp-config"] page-workspaces = ["cosmic-comp-config"]
# Other features # Other features
a11y = ["libcosmic/a11y"] a11y = ["libcosmic-yoda/a11y"]
ashpd = ["dep:ashpd"] ashpd = ["dep:ashpd"]
cosmic-comp-config = ["dep:cosmic-comp-config"] cosmic-comp-config = ["dep:cosmic-comp-config"]
dbus-config = ["libcosmic/dbus-config", "cosmic-config/dbus"] dbus-config = ["libcosmic-yoda/dbus-config", "cosmic-config/dbus"]
single-instance = ["libcosmic/single-instance"] single-instance = ["libcosmic-yoda/single-instance"]
test = [] test = []
wayland = ["libcosmic/wayland", "dep:cosmic-panel-config", "dep:cosmic-randr", "iced_winit/cctk"] wayland = ["libcosmic-yoda/wayland", "dep:cosmic-panel-config", "dep:cosmic-randr", "iced_winit/cctk"]
wgpu = ["libcosmic/wgpu"] wgpu = ["libcosmic-yoda/wgpu"]
xdg-portal = ["ashpd", "libcosmic/xdg-portal"] xdg-portal = ["ashpd", "libcosmic-yoda/xdg-portal"]

View file

@ -11,7 +11,7 @@ use std::{
use cosmic::{ use cosmic::{
Apply, Element, Task, Apply, Element, Task,
iced::Alignment, iced::{Alignment, Length},
surface, surface,
widget::{self, dropdown, icon, settings}, widget::{self, dropdown, icon, settings},
}; };
@ -281,269 +281,83 @@ impl Page {
} }
} }
fn app_item(meta: &AppMeta, label: String, category: Category) -> widget::FlexRow<'_, Message> {
// Avoid creating popup_dropdown for empty app lists.
// Empty categories are rendered as non-interactive text to prevent Wayland crashes.
settings::flex_item(
label,
if meta.apps.is_empty() {
widget::text(fl!("default-apps", "not-installed")).apply(Element::from)
} else {
dropdown::popup_dropdown(
&meta.apps,
meta.selected,
move |id| Message::SetDefault(category, id),
cosmic::iced::window::Id::RESERVED,
Message::Surface,
|a| crate::app::Message::PageMessage(crate::pages::Message::DefaultApps(a)),
)
.icons(Cow::Borrowed(&meta.icons))
.apply(Element::from)
},
)
.align_items(Alignment::Center)
.width(Length::Shrink)
}
fn apps() -> Section<crate::pages::Message> { fn apps() -> Section<crate::pages::Message> {
Section::default().view::<Page>(move |_binder, page, section| { Section::default().view::<Page>(move |_binder, page, section| {
let Some(mime_apps) = page.mime_apps.as_ref() else { let Some(mime_apps) = page.mime_apps.as_ref() else {
return widget::space().into(); return widget::space().into();
}; };
// Avoid creating popup_dropdown for empty app lists. settings::section::with_capacity(9)
// Empty categories are rendered as non-interactive text to prevent Wayland crashes.
settings::section()
.title(&section.title) .title(&section.title)
.add({ .add(app_item(
let meta = &mime_apps.apps[DROPDOWN_WEB_BROWSER]; &mime_apps.apps[DROPDOWN_WEB_BROWSER],
if meta.apps.is_empty() { fl!("default-apps", "web-browser"),
settings::flex_item( Category::WebBrowser,
fl!("default-apps", "web-browser"), ))
widget::text(fl!("default-apps", "not-installed")), .add(app_item(
) &mime_apps.apps[DROPDOWN_FILE_MANAGER],
.align_items(Alignment::Center) fl!("default-apps", "file-manager"),
} else { Category::FileManager,
settings::flex_item( ))
fl!("default-apps", "web-browser"), .add(app_item(
dropdown::popup_dropdown( &mime_apps.apps[DROPDOWN_MAIL],
&meta.apps, fl!("default-apps", "mail-client"),
meta.selected, Category::Mail,
|id| Message::SetDefault(Category::WebBrowser, id), ))
cosmic::iced::window::Id::RESERVED, .add(app_item(
Message::Surface, &mime_apps.apps[DROPDOWN_MUSIC],
|a| { fl!("default-apps", "music"),
crate::app::Message::PageMessage( Category::Audio,
crate::pages::Message::DefaultApps(a), ))
) .add(app_item(
}, &mime_apps.apps[DROPDOWN_VIDEO],
) fl!("default-apps", "video"),
.icons(Cow::Borrowed(&meta.icons)), Category::Video,
) ))
.align_items(Alignment::Center) .add(app_item(
.min_item_width(300.0) &mime_apps.apps[DROPDOWN_PHOTO],
} fl!("default-apps", "photos"),
}) Category::Image,
.add({ ))
let meta = &mime_apps.apps[DROPDOWN_FILE_MANAGER]; .add(app_item(
if meta.apps.is_empty() { &mime_apps.apps[DROPDOWN_CALENDAR],
settings::flex_item( fl!("default-apps", "calendar"),
fl!("default-apps", "file-manager"), Category::Calendar,
widget::text(fl!("default-apps", "not-installed")), ))
) .add(app_item(
.align_items(Alignment::Center) &mime_apps.apps[DROPDOWN_TERMINAL],
} else { fl!("default-apps", "terminal"),
settings::flex_item( Category::Terminal,
fl!("default-apps", "file-manager"), ))
dropdown::popup_dropdown( .add(app_item(
&meta.apps, &mime_apps.apps[DROPDOWN_TEXT_EDITOR],
meta.selected, fl!("default-apps", "text-editor"),
|id| Message::SetDefault(Category::FileManager, id), Category::TextEditor,
cosmic::iced::window::Id::RESERVED, ))
Message::Surface,
|a| {
crate::app::Message::PageMessage(
crate::pages::Message::DefaultApps(a),
)
},
)
.icons(Cow::Borrowed(&meta.icons)),
)
.align_items(Alignment::Center)
}
})
.add({
let meta = &mime_apps.apps[DROPDOWN_MAIL];
if meta.apps.is_empty() {
settings::flex_item(
fl!("default-apps", "mail-client"),
widget::text(fl!("default-apps", "not-installed")),
)
.align_items(Alignment::Center)
} else {
settings::flex_item(
fl!("default-apps", "mail-client"),
dropdown::popup_dropdown(
&meta.apps,
meta.selected,
|id| Message::SetDefault(Category::Mail, id),
cosmic::iced::window::Id::RESERVED,
Message::Surface,
|a| {
crate::app::Message::PageMessage(
crate::pages::Message::DefaultApps(a),
)
},
)
.icons(Cow::Borrowed(&meta.icons)),
)
.align_items(Alignment::Center)
}
})
.add({
let meta = &mime_apps.apps[DROPDOWN_MUSIC];
if meta.apps.is_empty() {
settings::flex_item(
fl!("default-apps", "music"),
widget::text(fl!("default-apps", "not-installed")),
)
.align_items(Alignment::Center)
} else {
settings::flex_item(
fl!("default-apps", "music"),
dropdown::popup_dropdown(
&meta.apps,
meta.selected,
|id| Message::SetDefault(Category::Audio, id),
cosmic::iced::window::Id::RESERVED,
Message::Surface,
|a| {
crate::app::Message::PageMessage(
crate::pages::Message::DefaultApps(a),
)
},
)
.icons(Cow::Borrowed(&meta.icons)),
)
.align_items(Alignment::Center)
}
})
.add({
let meta = &mime_apps.apps[DROPDOWN_VIDEO];
if meta.apps.is_empty() {
settings::flex_item(
fl!("default-apps", "video"),
widget::text(fl!("default-apps", "not-installed")),
)
.align_items(Alignment::Center)
} else {
settings::flex_item(
fl!("default-apps", "video"),
dropdown::popup_dropdown(
&meta.apps,
meta.selected,
|id| Message::SetDefault(Category::Video, id),
cosmic::iced::window::Id::RESERVED,
Message::Surface,
|a| {
crate::app::Message::PageMessage(
crate::pages::Message::DefaultApps(a),
)
},
)
.icons(Cow::Borrowed(&meta.icons)),
)
.align_items(Alignment::Center)
}
})
.add({
let meta = &mime_apps.apps[DROPDOWN_PHOTO];
if meta.apps.is_empty() {
settings::flex_item(
fl!("default-apps", "photos"),
widget::text(fl!("default-apps", "not-installed")),
)
.align_items(Alignment::Center)
} else {
settings::flex_item(
fl!("default-apps", "photos"),
dropdown::popup_dropdown(
&meta.apps,
meta.selected,
|id| Message::SetDefault(Category::Image, id),
cosmic::iced::window::Id::RESERVED,
Message::Surface,
|a| {
crate::app::Message::PageMessage(
crate::pages::Message::DefaultApps(a),
)
},
)
.icons(Cow::Borrowed(&meta.icons)),
)
.align_items(Alignment::Center)
}
})
.add({
let meta = &mime_apps.apps[DROPDOWN_CALENDAR];
if meta.apps.is_empty() {
settings::flex_item(
fl!("default-apps", "calendar"),
widget::text(fl!("default-apps", "not-installed")),
)
.align_items(Alignment::Center)
} else {
settings::flex_item(
fl!("default-apps", "calendar"),
dropdown::popup_dropdown(
&meta.apps,
meta.selected,
|id| Message::SetDefault(Category::Calendar, id),
cosmic::iced::window::Id::RESERVED,
Message::Surface,
|a| {
crate::app::Message::PageMessage(
crate::pages::Message::DefaultApps(a),
)
},
)
.icons(Cow::Borrowed(&meta.icons)),
)
.align_items(Alignment::Center)
}
})
.add({
let meta = &mime_apps.apps[DROPDOWN_TERMINAL];
if meta.apps.is_empty() {
settings::flex_item(
fl!("default-apps", "terminal"),
widget::text(fl!("default-apps", "not-installed")),
)
.align_items(Alignment::Center)
} else {
settings::flex_item(
fl!("default-apps", "terminal"),
dropdown::popup_dropdown(
&meta.apps,
meta.selected,
|id| Message::SetDefault(Category::Terminal, id),
cosmic::iced::window::Id::RESERVED,
Message::Surface,
|a| {
crate::app::Message::PageMessage(
crate::pages::Message::DefaultApps(a),
)
},
)
.icons(Cow::Borrowed(&meta.icons)),
)
.align_items(Alignment::Center)
}
})
.add({
let meta = &mime_apps.apps[DROPDOWN_TEXT_EDITOR];
if meta.apps.is_empty() {
settings::flex_item(
fl!("default-apps", "text-editor"),
widget::text(fl!("default-apps", "not-installed")),
)
.align_items(Alignment::Center)
} else {
settings::flex_item(
fl!("default-apps", "text-editor"),
dropdown::popup_dropdown(
&meta.apps,
meta.selected,
|id| Message::SetDefault(Category::TextEditor, id),
cosmic::iced::window::Id::RESERVED,
Message::Surface,
|a| {
crate::app::Message::PageMessage(
crate::pages::Message::DefaultApps(a),
)
},
)
.icons(Cow::Borrowed(&meta.icons)),
)
.align_items(Alignment::Center)
}
})
.apply(Element::from) .apply(Element::from)
.map(crate::pages::Message::DefaultApps) .map(crate::pages::Message::DefaultApps)
}) })

View file

@ -22,9 +22,9 @@ use crate::pages::desktop::appearance::Roundness;
pub struct PageInner { pub struct PageInner {
pub(crate) config_helper: Option<cosmic_config::Config>, pub(crate) config_helper: Option<cosmic_config::Config>,
pub(crate) panel_config: Option<CosmicPanelConfig>, pub(crate) panel_config: Option<CosmicPanelConfig>,
pub size: Option<PanelSize>,
pub opacity: f32, pub opacity: f32,
pub opacity_changing: bool, pub opacity_changing: bool,
pub size: PanelSize,
pub outputs: Vec<String>, pub outputs: Vec<String>,
pub anchors: Vec<String>, pub anchors: Vec<String>,
pub backgrounds: Vec<String>, pub backgrounds: Vec<String>,
@ -40,9 +40,9 @@ impl Default for PageInner {
Self { Self {
config_helper: Option::default(), config_helper: Option::default(),
panel_config: Option::default(), panel_config: Option::default(),
size: Option::default(),
opacity: 0.0, opacity: 0.0,
opacity_changing: false, opacity_changing: false,
size: PanelSize::M,
outputs: vec![fl!("all-displays")], outputs: vec![fl!("all-displays")],
anchors: vec![ anchors: vec![
Anchor(PanelAnchor::Left).to_string(), Anchor(PanelAnchor::Left).to_string(),
@ -209,9 +209,7 @@ pub(crate) fn style<
text::body(fl!("small")).into(), text::body(fl!("small")).into(),
slider( slider(
0..=4, 0..=4,
match inner.size.as_ref().expect( match inner.size {
"PageInner.size is None even though PageInner.panel_config is Some",
) {
PanelSize::XS => 0, PanelSize::XS => 0,
PanelSize::S => 1, PanelSize::S => 1,
PanelSize::M => 2, PanelSize::M => 2,
@ -506,7 +504,7 @@ impl PageInner {
if let Err(err) = default.write_entry(config) { if let Err(err) = default.write_entry(config) {
tracing::error!(?err, "Error resetting panel config."); tracing::error!(?err, "Error resetting panel config.");
} }
self.size = Some(default.size.clone()); self.size.clone_from(&default.size);
self.system_default = Some(default.clone()); self.system_default = Some(default.clone());
self.panel_config.clone_from(&self.system_default); self.panel_config.clone_from(&self.system_default);
} else { } else {
@ -605,16 +603,10 @@ impl PageInner {
_ = panel_config.set_border_radius(helper, new_radius).unwrap(); _ = panel_config.set_border_radius(helper, new_radius).unwrap();
} }
Message::PanelSize(size) => { Message::PanelSize(size) => {
self.size = Some(size); self.size = size;
} }
Message::PanelSizeCommit => { Message::PanelSizeCommit => {
_ = panel_config.set_size( _ = panel_config.set_size(helper, self.size.clone());
helper,
self.size
.as_ref()
.expect("PageInner.size is None even though it should be Some, since PageInner.panel_config is Some")
.clone()
);
// Reset any size overrides the user might have set // Reset any size overrides the user might have set
_ = panel_config.set_size_center(helper, None); _ = panel_config.set_size_center(helper, None);
_ = panel_config.set_size_wings(helper, None); _ = panel_config.set_size_wings(helper, None);
@ -677,7 +669,7 @@ impl PageInner {
} }
} }
Message::PanelConfig(c) => { Message::PanelConfig(c) => {
self.size = Some(c.size.clone()); self.size = c.size.clone();
self.panel_config = Some(*c); self.panel_config = Some(*c);
return Task::none(); return Task::none();
} }

View file

@ -79,7 +79,6 @@ impl Default for Page {
// If the config is not present, it will be created with the default values and the name will not match // If the config is not present, it will be created with the default values and the name will not match
(panel_config.name == "Panel").then_some(panel_config) (panel_config.name == "Panel").then_some(panel_config)
}); });
let size = panel_config.as_ref().map(|c| c.size.clone());
let system_default = cosmic::cosmic_config::Config::system( let system_default = cosmic::cosmic_config::Config::system(
&format!("{}.Panel", cosmic_panel_config::NAME), &format!("{}.Panel", cosmic_panel_config::NAME),
CosmicPanelConfig::VERSION, CosmicPanelConfig::VERSION,
@ -99,7 +98,6 @@ impl Default for Page {
inner: PageInner { inner: PageInner {
config_helper, config_helper,
panel_config, panel_config,
size,
container_config, container_config,
outputs_map: HashMap::new(), outputs_map: HashMap::new(),
system_default, system_default,

View file

@ -27,6 +27,7 @@ pub enum Message {
ShowActiveWindowHint(bool), ShowActiveWindowHint(bool),
ShowMaximizeButton(bool), ShowMaximizeButton(bool),
ShowMinimizeButton(bool), ShowMinimizeButton(bool),
WindowControlsPositionStart(bool),
SetEdgeSnapThreshold(u32), SetEdgeSnapThreshold(u32),
Surface(surface::Action), Surface(surface::Action),
} }
@ -177,6 +178,19 @@ impl Page {
.set_show_minimize(&config, value); .set_show_minimize(&config, value);
} }
} }
Message::WindowControlsPositionStart(left) => {
if let Ok(config) = cosmic::config::CosmicTk::config() {
let position = if left {
cosmic::widget::WindowControlsPosition::Start
} else {
cosmic::widget::WindowControlsPosition::End
};
let _res = cosmic::config::COSMIC_TK
.write()
.unwrap()
.set_window_controls_position(&config, position);
}
}
Message::ShowActiveWindowHint(value) => { Message::ShowActiveWindowHint(value) => {
self.show_active_hint = value; self.show_active_hint = value;
if let Err(err) = self.comp_config.set("active_hint", value) { if let Err(err) = self.comp_config.set("active_hint", value) {
@ -274,6 +288,7 @@ pub fn window_controls() -> Section<crate::pages::Message> {
maximize = fl!("window-controls", "maximize"); maximize = fl!("window-controls", "maximize");
minimize = fl!("window-controls", "minimize"); minimize = fl!("window-controls", "minimize");
active_window_hint = fl!("window-controls", "active-window-hint"); active_window_hint = fl!("window-controls", "active-window-hint");
position_start = fl!("window-controls", "position-start");
}); });
Section::default() Section::default()
@ -296,6 +311,13 @@ pub fn window_controls() -> Section<crate::pages::Message> {
settings::item::builder(&descriptions[minimize]) settings::item::builder(&descriptions[minimize])
.toggler(cosmic::config::show_minimize(), Message::ShowMinimizeButton), .toggler(cosmic::config::show_minimize(), Message::ShowMinimizeButton),
) )
.add(settings::item::builder(&descriptions[position_start]).toggler(
matches!(
cosmic::config::window_controls_position(),
cosmic::widget::WindowControlsPosition::Start
),
Message::WindowControlsPositionStart,
))
.apply(Element::from) .apply(Element::from)
.map(crate::pages::Message::WindowManagement) .map(crate::pages::Message::WindowManagement)
}) })

View file

@ -8,7 +8,7 @@ use cosmic::iced::keyboard::{Key, Location, Modifiers};
use cosmic::iced::platform_specific::shell::wayland::commands::keyboard_shortcuts_inhibit; use cosmic::iced::platform_specific::shell::wayland::commands::keyboard_shortcuts_inhibit;
use cosmic::iced::platform_specific::shell::wayland::keymap; use cosmic::iced::platform_specific::shell::wayland::keymap;
use cosmic::iced::{self, Alignment, Length}; use cosmic::iced::{self, Alignment, Length};
use cosmic::widget::{self, button, icon, settings, text}; use cosmic::widget::{self, button, icon, list, settings, text};
use cosmic::{Apply, Element, Task, theme}; use cosmic::{Apply, Element, Task, theme};
use cosmic_config::{ConfigGet, ConfigSet}; use cosmic_config::{ConfigGet, ConfigSet};
use cosmic_settings_config::shortcuts::{self, Action, Binding, Shortcuts}; use cosmic_settings_config::shortcuts::{self, Action, Binding, Shortcuts};
@ -865,13 +865,11 @@ fn context_drawer<'a>(
} }
/// Display a shortcut as a list item /// Display a shortcut as a list item
fn shortcut_item(custom: bool, id: usize, data: &ShortcutModel) -> Element<'_, ShortcutMessage> { fn shortcut_item(
#[derive(Copy, Clone, Debug)] custom: bool,
enum LocalMessage { id: usize,
Remove, data: &ShortcutModel,
Show, ) -> list::ListButton<'_, ShortcutMessage> {
}
let bindings = data let bindings = data
.bindings .bindings
.iter() .iter()
@ -880,7 +878,7 @@ fn shortcut_item(custom: bool, id: usize, data: &ShortcutModel) -> Element<'_, S
.map(|(_, shortcut)| text::body(shortcut.binding.to_string()).into()) .map(|(_, shortcut)| text::body(shortcut.binding.to_string()).into())
.collect::<Vec<_>>(); .collect::<Vec<_>>();
let shortcuts: Element<LocalMessage> = if bindings.is_empty() { let shortcuts: Element<ShortcutMessage> = if bindings.is_empty() {
text::body(fl!("disabled")).into() text::body(fl!("disabled")).into()
} else { } else {
widget::column::with_children(bindings) widget::column::with_children(bindings)
@ -900,7 +898,7 @@ fn shortcut_item(custom: bool, id: usize, data: &ShortcutModel) -> Element<'_, S
.push(icon::from_name("go-next-symbolic").size(16)) .push(icon::from_name("go-next-symbolic").size(16))
.push_maybe(custom.then(|| { .push_maybe(custom.then(|| {
widget::button::icon(icon::from_name("edit-delete-symbolic")) widget::button::icon(icon::from_name("edit-delete-symbolic"))
.on_press(LocalMessage::Remove) .on_press(ShortcutMessage::DeleteShortcut(id))
})) }))
.align_y(Alignment::Center) .align_y(Alignment::Center)
.spacing(8); .spacing(8);
@ -909,14 +907,7 @@ fn shortcut_item(custom: bool, id: usize, data: &ShortcutModel) -> Element<'_, S
.flex_control(control) .flex_control(control)
.align_items(Alignment::Center) .align_items(Alignment::Center)
.spacing(16) .spacing(16)
.apply(widget::container) .width(Length::Shrink)
.class(theme::Container::List) .apply(list::button)
.apply(widget::button::custom) .on_press(ShortcutMessage::ShowShortcut(id, data.description.clone()))
.class(theme::Button::Transparent)
.on_press(LocalMessage::Show)
.apply(Element::from)
.map(move |message| match message {
LocalMessage::Show => ShortcutMessage::ShowShortcut(id, data.description.clone()),
LocalMessage::Remove => ShortcutMessage::DeleteShortcut(id),
})
} }

View file

@ -15,8 +15,8 @@ pub mod tiling;
use cosmic::app::ContextDrawer; use cosmic::app::ContextDrawer;
use cosmic::iced::Length; use cosmic::iced::Length;
use cosmic::widget::{self, icon, settings, text}; use cosmic::widget::{self, list::ListButton, settings, text};
use cosmic::{Apply, Element, Task, theme}; use cosmic::{Apply, Element, Task};
use cosmic_config::ConfigGet; use cosmic_config::ConfigGet;
use cosmic_settings_config::Binding; use cosmic_settings_config::Binding;
use cosmic_settings_config::shortcuts::action::{ use cosmic_settings_config::shortcuts::action::{
@ -222,11 +222,13 @@ impl Page {
self.search.localized = SecondaryMap::new(); self.search.localized = SecondaryMap::new();
self.search.input = String::new(); self.search.input = String::new();
self.search_model.on_clear(); self.search_model.on_clear();
self.modified.custom = 0; self.modified.accessibility = 0;
self.modified.manage_windows = 0; self.modified.manage_windows = 0;
self.modified.move_windows = 0; self.modified.move_windows = 0;
self.modified.nav = 0; self.modified.nav = 0;
self.modified.system = 0; self.modified.system = 0;
self.modified.window_tiling = 0;
self.modified.custom = 0;
} }
fn reload_search(&mut self) { fn reload_search(&mut self) {
@ -497,32 +499,18 @@ fn shortcuts() -> Section<crate::pages::Message> {
} }
/// Display a category as a list item /// Display a category as a list item
fn category_item(category: Category, name: &str, modified: u16) -> Element<'_, Message> { fn category_item(category: Category, name: &str, modified: u16) -> ListButton<'_, Message> {
let icon = icon::from_name("go-next-symbolic").size(16); crate::widget::go_next_with_item(
name,
let control = if modified == 0 { (modified > 0).then(|| text::body(fl!("modified", count = modified)).apply(Element::from)),
Element::from(icon) Message::Category(category),
} else { )
widget::row::with_capacity(2)
.push(text::body(fl!("modified", count = modified)))
.push(icon)
.into()
};
settings::item::builder(name)
.control(control)
.spacing(16)
.apply(widget::container)
.class(theme::Container::List)
.apply(widget::button::custom)
.class(theme::Button::Transparent)
.width(Length::Fill)
.on_press(Message::Category(category))
.into()
} }
fn action_category(action: &Action) -> Option<Category> { fn action_category(action: &Action) -> Option<Category> {
Some(if manage_windows::actions().contains(action) { Some(if accessibility::actions().contains(action) {
Category::Accessibility
} else if manage_windows::actions().contains(action) {
Category::ManageWindow Category::ManageWindow
} else if move_window::actions().contains(action) { } else if move_window::actions().contains(action) {
Category::MoveWindow Category::MoveWindow
@ -530,6 +518,8 @@ fn action_category(action: &Action) -> Option<Category> {
Category::Nav Category::Nav
} else if system::actions().contains(action) { } else if system::actions().contains(action) {
Category::System Category::System
} else if tiling::actions().contains(action) {
Category::WindowTiling
} else { } else {
return None; return None;
}) })

View file

@ -8,7 +8,7 @@ use cosmic::{
cosmic_config::{self, ConfigGet, ConfigSet}, cosmic_config::{self, ConfigGet, ConfigSet},
iced::core::text::Wrapping, iced::core::text::Wrapping,
surface, surface,
widget::{self, dropdown, list, settings}, widget::{self, dropdown, settings},
}; };
use cosmic_settings_page::{self as page, Section, section}; use cosmic_settings_page::{self as page, Section, section};
use icu::{ use icu::{

View file

@ -7,7 +7,7 @@ use std::sync::Arc;
use crate::widget::selection_context_item; use crate::widget::selection_context_item;
use cosmic::app::{ContextDrawer, context_drawer}; use cosmic::app::{ContextDrawer, context_drawer};
use cosmic::iced::{Alignment, Length}; use cosmic::iced::{Alignment, Length};
use cosmic::widget::{self, button, list}; use cosmic::widget::{self, button};
use cosmic::{Apply, Element}; use cosmic::{Apply, Element};
use cosmic_config::{ConfigGet, ConfigSet}; use cosmic_config::{ConfigGet, ConfigSet};
use cosmic_settings_page::Section; use cosmic_settings_page::Section;

View file

@ -206,8 +206,10 @@ pub fn go_next_with_item<'a, Msg: 'static>(
msg_opt: impl Into<Option<Msg>>, msg_opt: impl Into<Option<Msg>>,
) -> list::ListButton<'a, Msg> { ) -> list::ListButton<'a, Msg> {
settings::item_row(vec![ settings::item_row(vec![
text::body(description).wrapping(Wrapping::Word).into(), text::body(description)
horizontal().into(), .width(Length::Fill)
.wrapping(Wrapping::Word)
.into(),
row::with_capacity(2) row::with_capacity(2)
.push(item) .push(item)
.push(icon::from_name("go-next-symbolic").size(16).icon()) .push(icon::from_name("go-next-symbolic").size(16).icon())

View file

@ -484,6 +484,7 @@ window-controls = Window controls
.maximize = Show maximize button .maximize = Show maximize button
.minimize = Show minimize button .minimize = Show minimize button
.active-window-hint = Show active window hint .active-window-hint = Show active window hint
.position-start = Place buttons on the left (macOS style)
focus-navigation = Focus navigation focus-navigation = Focus navigation
.focus-follows-cursor = Focus follows cursor .focus-follows-cursor = Focus follows cursor

View file

@ -322,6 +322,7 @@ window-controls = Contrôles des fenêtres
.maximize = Afficher le bouton maximiser .maximize = Afficher le bouton maximiser
.minimize = Afficher le bouton minimiser .minimize = Afficher le bouton minimiser
.active-window-hint = Afficher l'indice de la fenêtre active .active-window-hint = Afficher l'indice de la fenêtre active
.position-start = Placer les boutons à gauche (style macOS)
focus-navigation = Navigation par le focus focus-navigation = Navigation par le focus
.focus-follows-cursor = Le focus suit le curseur .focus-follows-cursor = Le focus suit le curseur
.focus-follows-cursor-delay = Délai de suivi du focus en ms .focus-follows-cursor-delay = Délai de suivi du focus en ms

View file

@ -7,7 +7,7 @@ edition = "2024"
derive_setters = "0.1.9" derive_setters = "0.1.9"
regex = "1.12.3" regex = "1.12.3"
slotmap = "1.1.1" slotmap = "1.1.1"
libcosmic = { workspace = true } libcosmic-yoda = { workspace = true }
downcast-rs = "2.0.2" downcast-rs = "2.0.2"
url = "2.5.8" url = "2.5.8"
slab = "0.4.12" slab = "0.4.12"

View file

@ -104,6 +104,7 @@ pub async fn load_each_from_path(
) -> Pin<Box<dyn Send + Stream<Item = (PathBuf, RgbaImage, RgbaImage)>>> { ) -> Pin<Box<dyn Send + Stream<Item = (PathBuf, RgbaImage, RgbaImage)>>> {
let candidate_paths: Vec<_> = WalkDir::new(path) let candidate_paths: Vec<_> = WalkDir::new(path)
.max_depth(3) .max_depth(3)
.follow_links(true)
.into_iter() .into_iter()
.filter_map(Result::ok) .filter_map(Result::ok)
.filter(|entry| entry.file_type().is_file()) .filter(|entry| entry.file_type().is_file())

View file

@ -7,8 +7,8 @@ rust-version.workspace = true
publish = true publish = true
[dependencies] [dependencies]
cosmic-protocols = { git = "https://github.com/pop-os/cosmic-protocols" } cosmic-protocols = { path = "../../../cosmic-protocols" }
iced_futures = { git = "https://github.com/pop-os/libcosmic" } iced_futures = { path = "../../../libcosmic/iced/futures" }
num-derive = "0.4.2" num-derive = "0.4.2"
num-traits = "0.2.19" num-traits = "0.2.19"
sctk.workspace = true sctk.workspace = true

View file

@ -7,9 +7,9 @@ rust-version.workspace = true
publish = true publish = true
[dependencies] [dependencies]
cosmic-dbus-a11y = { git = "https://github.com/pop-os/dbus-settings-bindings" } cosmic-dbus-a11y = { path = "../../../dbus-settings-bindings/a11y" }
futures = "0.3.32" futures = "0.3.32"
iced_futures = { git = "https://github.com/pop-os/libcosmic" } iced_futures = { path = "../../../libcosmic/iced/futures" }
tokio = { version = "1.49.0", features = ["sync", "time"] } tokio = { version = "1.49.0", features = ["sync", "time"] }
tracing = "0.1.44" tracing = "0.1.44"
zbus = "5.13" zbus = "5.13"

View file

@ -8,7 +8,7 @@ publish = true
[dependencies] [dependencies]
futures = "0.3.32" futures = "0.3.32"
iced_futures = { git = "https://github.com/pop-os/libcosmic" } iced_futures = { path = "../../../libcosmic/iced/futures" }
log = "0.4.29" log = "0.4.29"
rustix = "1.1.3" rustix = "1.1.3"
tokio = "1.49.0" tokio = "1.49.0"

View file

@ -7,7 +7,7 @@ rust-version.workspace = true
publish = true publish = true
[dependencies] [dependencies]
bluez-zbus = { git = "https://github.com/pop-os/dbus-settings-bindings" } bluez-zbus = { path = "../../../dbus-settings-bindings/bluez" }
futures = "0.3.32" futures = "0.3.32"
iced_futures = { git = "https://github.com/pop-os/libcosmic" } iced_futures = { git = "https://github.com/pop-os/libcosmic" }
tokio = "1.49.0" tokio = "1.49.0"

View file

@ -7,11 +7,11 @@ rust-version.workspace = true
publish = true publish = true
[dependencies] [dependencies]
cosmic-dbus-networkmanager = { git = "https://github.com/pop-os/dbus-settings-bindings" } cosmic-dbus-networkmanager = { path = "../../../dbus-settings-bindings/networkmanager" }
secret-service = { version = "5.1.0", features = ["rt-tokio-crypto-rust"] } secret-service = { version = "5.1.0", features = ["rt-tokio-crypto-rust"] }
nm-secret-agent-manager = { git = "https://github.com/pop-os/dbus-settings-bindings" } nm-secret-agent-manager = { path = "../../../dbus-settings-bindings/nm-secret-agent-manager" }
futures = "0.3.32" futures = "0.3.32"
iced_futures = { git = "https://github.com/pop-os/libcosmic" } iced_futures = { path = "../../../libcosmic/iced/futures" }
itertools = "0.14.0" itertools = "0.14.0"
secure-string = "0.3.0" secure-string = "0.3.0"
thiserror = "2.0.18" thiserror = "2.0.18"

View file

@ -185,7 +185,7 @@ pub fn subscription<I: 'static + Hash + Copy + Send + Sync + Debug>(
conn, conn,
}, },
|Wrapper { |Wrapper {
id, id: _,
has_popup, has_popup,
conn, conn,
}| { }| {

View file

@ -141,7 +141,7 @@ pub fn subscription<I: Copy + Debug + std::hash::Hash + 'static>(
self.id.hash(state); self.id.hash(state);
} }
} }
Subscription::run_with(Wrapper { id, conn }, |Wrapper { id, conn }| { Subscription::run_with(Wrapper { id, conn }, |Wrapper { id: _, conn }| {
let conn = conn.clone(); let conn = conn.clone();
stream::channel( stream::channel(
50, 50,

View file

@ -7,6 +7,6 @@ rust-version.workspace = true
[dependencies] [dependencies]
libpulse-binding = { version = "2.30.1" } libpulse-binding = { version = "2.30.1" }
rustix = { version = "1.1.3", features = ["pipe"] } rustix = { version = "1.1.3", features = ["pipe"] }
iced_futures = { git = "https://github.com/pop-os/libcosmic" } iced_futures = { path = "../../../libcosmic/iced/futures" }
futures = "0.3.32" futures = "0.3.32"
log = "0.4.27" log = "0.4.27"

View file

@ -288,7 +288,7 @@ impl PulseChannels {
/// Set the speaker balance of the active sink. /// Set the speaker balance of the active sink.
pub fn set_balance(&mut self, balance: f32) { pub fn set_balance(&mut self, balance: f32) {
if let Err(err) = self.tx.send(Request::Balance(self.index, balance)) { if let Err(err) = self.tx.send(Request::Balance(self.index, balance)) {
log::error!("Failed to send new balance to channel"); log::error!("Failed to send new balance to channel: {err}");
} else { } else {
self.pipe_tx self.pipe_tx
.write_all(&[1]) .write_all(&[1])
@ -299,7 +299,7 @@ impl PulseChannels {
/// Set the volume of the active sink. /// Set the volume of the active sink.
pub fn set_volume(&mut self, volume: f32) { pub fn set_volume(&mut self, volume: f32) {
if let Err(err) = self.tx.send(Request::Volume(self.index, volume)) { if let Err(err) = self.tx.send(Request::Volume(self.index, volume)) {
log::error!("Failed to send new volume to channel"); log::error!("Failed to send new volume to channel: {err}");
} else { } else {
self.pipe_tx self.pipe_tx
.write_all(&[1]) .write_all(&[1])

View file

@ -7,7 +7,7 @@ publish = true
[dependencies] [dependencies]
futures = "0.3.32" futures = "0.3.32"
iced_futures = { git = "https://github.com/pop-os/libcosmic" } iced_futures = { path = "../../../libcosmic/iced/futures" }
log = "0.4.29" log = "0.4.29"
tokio = "1.49.0" tokio = "1.49.0"
tokio-stream = "0.1.18" tokio-stream = "0.1.18"

View file

@ -10,7 +10,7 @@ publish = true
cosmic-pipewire = { path = "../../crates/cosmic-pipewire" } cosmic-pipewire = { path = "../../crates/cosmic-pipewire" }
futures = "0.3.32" futures = "0.3.32"
intmap = "3.1.3" intmap = "3.1.3"
libcosmic = { git = "https://github.com/pop-os/libcosmic", default-features = false } libcosmic-yoda = { path = "/home/lionel/Projets/COSMIC/libcosmic", default-features = false }
numtoa = "1.0.0-alpha1" numtoa = "1.0.0-alpha1"
rustix = "1.1.3" rustix = "1.1.3"
tokio = { version = "1.49.0", features = ["process", "rt", "time"] } tokio = { version = "1.49.0", features = ["process", "rt", "time"] }

View file

@ -8,9 +8,9 @@ publish = true
[dependencies] [dependencies]
futures = "0.3.32" futures = "0.3.32"
iced_futures = { git = "https://github.com/pop-os/libcosmic" } iced_futures = { path = "../../../libcosmic/iced/futures" }
log = "0.4.29" log = "0.4.29"
tokio = "1.49.0" tokio = "1.49.0"
tokio-stream = "0.1.18" tokio-stream = "0.1.18"
upower_dbus = { git = "https://github.com/pop-os/dbus-settings-bindings" } upower_dbus = { path = "../../../dbus-settings-bindings/upower" }
zbus = "5.13.2" zbus = "5.13.2"