Panel applets jammy (#41)
This commit is contained in:
parent
162ff02b12
commit
82ac6aac1c
11 changed files with 1845 additions and 62 deletions
224
Cargo.lock
generated
224
Cargo.lock
generated
|
|
@ -75,9 +75,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "aho-corasick"
|
||||
version = "1.0.1"
|
||||
version = "1.0.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "67fc08ce920c31afb70f013dcce1bfc3a3195de6a228474e45e1f145b36f8d04"
|
||||
checksum = "43f6cb1bf222025340178f382c426f13757b2960e89779dfcb319c32542a5a41"
|
||||
dependencies = [
|
||||
"memchr",
|
||||
]
|
||||
|
|
@ -462,10 +462,11 @@ checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be"
|
|||
|
||||
[[package]]
|
||||
name = "calloop"
|
||||
version = "0.10.5"
|
||||
version = "0.10.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "1a59225be45a478d772ce015d9743e49e92798ece9e34eda9a6aa2a6a7f40192"
|
||||
checksum = "52e0d00eb1ea24371a97d2da6201c6747a633dc6dc1988ef503403b4c59504a8"
|
||||
dependencies = [
|
||||
"bitflags 1.3.2",
|
||||
"log",
|
||||
"nix 0.25.1",
|
||||
"slotmap",
|
||||
|
|
@ -730,7 +731,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "cosmic-config"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"atomicwrites",
|
||||
"calloop",
|
||||
|
|
@ -745,7 +746,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "cosmic-config-derive"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"quote",
|
||||
"syn 1.0.109",
|
||||
|
|
@ -769,6 +770,7 @@ dependencies = [
|
|||
name = "cosmic-settings"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"apply",
|
||||
"async-channel",
|
||||
"color-eyre",
|
||||
|
|
@ -780,10 +782,14 @@ dependencies = [
|
|||
"derive_setters",
|
||||
"dirs 5.0.1",
|
||||
"downcast-rs",
|
||||
"env_logger",
|
||||
"freedesktop-desktop-entry",
|
||||
"generator",
|
||||
"i18n-embed",
|
||||
"i18n-embed-fl",
|
||||
"libcosmic",
|
||||
"log",
|
||||
"notify",
|
||||
"once_cell",
|
||||
"regex",
|
||||
"rust-embed",
|
||||
|
|
@ -791,6 +797,7 @@ dependencies = [
|
|||
"tokio",
|
||||
"tracing",
|
||||
"tracing-subscriber",
|
||||
"url",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
|
@ -867,7 +874,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "cosmic-theme"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"cosmic-config",
|
||||
|
|
@ -1143,6 +1150,15 @@ dependencies = [
|
|||
"dirs-sys 0.3.7",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "dirs"
|
||||
version = "3.0.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "30baa043103c9d0c2a57cf537cc2f35623889dc0d405e6c3cccfadbc81c71309"
|
||||
dependencies = [
|
||||
"dirs-sys 0.3.7",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "dirs"
|
||||
version = "4.0.0"
|
||||
|
|
@ -1203,11 +1219,11 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "dlib"
|
||||
version = "0.5.0"
|
||||
version = "0.5.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "ac1b7517328c04c2aa68422fc60a41b92208182142ed04a25879c26c8f878794"
|
||||
checksum = "330c60081dcc4c72131f8eb70510f1ac07223e5d4163db481a04a0befcffa412"
|
||||
dependencies = [
|
||||
"libloading 0.7.4",
|
||||
"libloading 0.8.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
|
@ -1306,6 +1322,19 @@ dependencies = [
|
|||
"syn 2.0.18",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "env_logger"
|
||||
version = "0.10.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "85cdab6a89accf66733ad5a1693a4dcced6aeff64602b634530dd73c1f3ee9f0"
|
||||
dependencies = [
|
||||
"humantime",
|
||||
"is-terminal",
|
||||
"log",
|
||||
"regex",
|
||||
"termcolor",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "errno"
|
||||
version = "0.3.1"
|
||||
|
|
@ -1374,15 +1403,15 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "exr"
|
||||
version = "1.6.3"
|
||||
version = "1.6.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "bdd2162b720141a91a054640662d3edce3d50a944a50ffca5313cd951abb35b4"
|
||||
checksum = "279d3efcc55e19917fff7ab3ddd6c14afb6a90881a0078465196fe2f99d08c56"
|
||||
dependencies = [
|
||||
"bit_field",
|
||||
"flume",
|
||||
"half",
|
||||
"lebe",
|
||||
"miniz_oxide 0.6.2",
|
||||
"miniz_oxide 0.7.1",
|
||||
"rayon-core",
|
||||
"smallvec",
|
||||
"zune-inflate",
|
||||
|
|
@ -1583,6 +1612,15 @@ version = "0.3.1"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b"
|
||||
|
||||
[[package]]
|
||||
name = "form_urlencoded"
|
||||
version = "1.2.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652"
|
||||
dependencies = [
|
||||
"percent-encoding",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "fraction"
|
||||
version = "0.13.1"
|
||||
|
|
@ -1593,6 +1631,19 @@ dependencies = [
|
|||
"num",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "freedesktop-desktop-entry"
|
||||
version = "0.5.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "45157175a725e81f3f594382430b6b78af5f8f72db9bd51b94f0785f80fc6d29"
|
||||
dependencies = [
|
||||
"dirs 3.0.2",
|
||||
"gettext-rs",
|
||||
"memchr",
|
||||
"thiserror",
|
||||
"xdg",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "freedesktop-icons"
|
||||
version = "0.2.3"
|
||||
|
|
@ -1788,6 +1839,26 @@ dependencies = [
|
|||
"wasm-bindgen",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "gettext-rs"
|
||||
version = "0.7.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e49ea8a8fad198aaa1f9655a2524b64b70eb06b2f3ff37da407566c93054f364"
|
||||
dependencies = [
|
||||
"gettext-sys",
|
||||
"locale_config",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "gettext-sys"
|
||||
version = "0.21.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c63ce2e00f56a206778276704bbe38564c8695249fdc8f354b4ef71c57c3839d"
|
||||
dependencies = [
|
||||
"cc",
|
||||
"temp-dir",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "gif"
|
||||
version = "0.12.0"
|
||||
|
|
@ -1812,9 +1883,9 @@ checksum = "518faa5064866338b013ff9b2350dc318e14cc4fcd6cb8206d7e7c9886c98815"
|
|||
|
||||
[[package]]
|
||||
name = "glow"
|
||||
version = "0.12.1"
|
||||
version = "0.12.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4e007a07a24de5ecae94160f141029e9a347282cfe25d1d58d85d845cf3130f1"
|
||||
checksum = "807edf58b70c0b5b2181dd39fe1839dbdb3ba02645630dc5f753e23da307f762"
|
||||
dependencies = [
|
||||
"js-sys",
|
||||
"slotmap",
|
||||
|
|
@ -1973,6 +2044,12 @@ dependencies = [
|
|||
"windows-sys 0.48.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "humantime"
|
||||
version = "2.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4"
|
||||
|
||||
[[package]]
|
||||
name = "i18n-config"
|
||||
version = "0.4.4"
|
||||
|
|
@ -2046,7 +2123,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced"
|
||||
version = "0.9.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"iced_accessibility",
|
||||
"iced_core",
|
||||
|
|
@ -2062,7 +2139,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_accessibility"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"accesskit",
|
||||
"accesskit_unix",
|
||||
|
|
@ -2071,7 +2148,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_core"
|
||||
version = "0.9.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"bitflags 1.3.2",
|
||||
"iced_accessibility",
|
||||
|
|
@ -2086,7 +2163,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_futures"
|
||||
version = "0.6.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"futures",
|
||||
"iced_core",
|
||||
|
|
@ -2099,7 +2176,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_graphics"
|
||||
version = "0.8.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"bitflags 1.3.2",
|
||||
"bytemuck",
|
||||
|
|
@ -2116,7 +2193,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_renderer"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"iced_graphics",
|
||||
"iced_tiny_skia",
|
||||
|
|
@ -2128,7 +2205,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_runtime"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"iced_accessibility",
|
||||
"iced_core",
|
||||
|
|
@ -2140,7 +2217,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_sctk"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"enum-repr",
|
||||
"float-cmp",
|
||||
|
|
@ -2161,7 +2238,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_style"
|
||||
version = "0.8.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"iced_core",
|
||||
"once_cell",
|
||||
|
|
@ -2171,7 +2248,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_tiny_skia"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"bytemuck",
|
||||
"cosmic-text",
|
||||
|
|
@ -2189,7 +2266,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_wgpu"
|
||||
version = "0.10.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"bitflags 1.3.2",
|
||||
"bytemuck",
|
||||
|
|
@ -2211,7 +2288,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_widget"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"iced_renderer",
|
||||
"iced_runtime",
|
||||
|
|
@ -2226,7 +2303,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_winit"
|
||||
version = "0.9.1"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"iced_graphics",
|
||||
"iced_runtime",
|
||||
|
|
@ -2312,6 +2389,16 @@ version = "1.0.1"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39"
|
||||
|
||||
[[package]]
|
||||
name = "idna"
|
||||
version = "0.4.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c"
|
||||
dependencies = [
|
||||
"unicode-bidi",
|
||||
"unicode-normalization",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "image"
|
||||
version = "0.24.6"
|
||||
|
|
@ -2415,6 +2502,18 @@ dependencies = [
|
|||
"windows-sys 0.48.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "is-terminal"
|
||||
version = "0.4.7"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "adcf93614601c8129ddf72e2d5633df827ba6551541c6d8c59520a371475be1f"
|
||||
dependencies = [
|
||||
"hermit-abi 0.3.1",
|
||||
"io-lifetimes",
|
||||
"rustix",
|
||||
"windows-sys 0.48.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "itertools"
|
||||
version = "0.10.5"
|
||||
|
|
@ -2511,14 +2610,14 @@ checksum = "03087c2bad5e1034e8cace5926dec053fb3790248370865f5117a7d0213354c8"
|
|||
|
||||
[[package]]
|
||||
name = "libc"
|
||||
version = "0.2.144"
|
||||
version = "0.2.145"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "2b00cc1c228a6782d0f076e7b232802e0c5689d41bb5df366f2a6b6621cfdfe1"
|
||||
checksum = "fc86cde3ff845662b8f4ef6cb50ea0e20c524eb3d29ae048287e06a1b3fa6a81"
|
||||
|
||||
[[package]]
|
||||
name = "libcosmic"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic#31f7e97d5bf4860be5afd406209eed733f736f04"
|
||||
source = "git+https://github.com/pop-os/libcosmic#cf2818c4a163caaa6a627e7aa6bcd40e455c7a6a"
|
||||
dependencies = [
|
||||
"apply",
|
||||
"cosmic-config",
|
||||
|
|
@ -2528,6 +2627,8 @@ dependencies = [
|
|||
"freedesktop-icons",
|
||||
"iced",
|
||||
"iced_core",
|
||||
"iced_futures",
|
||||
"iced_renderer",
|
||||
"iced_runtime",
|
||||
"iced_sctk",
|
||||
"iced_style",
|
||||
|
|
@ -3075,9 +3176,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "once_cell"
|
||||
version = "1.17.2"
|
||||
version = "1.18.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9670a07f94779e00908f3e686eab508878ebb390ba6e604d3a284c00e8d0487b"
|
||||
checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d"
|
||||
|
||||
[[package]]
|
||||
name = "option-ext"
|
||||
|
|
@ -3245,9 +3346,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "percent-encoding"
|
||||
version = "2.2.0"
|
||||
version = "2.3.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e"
|
||||
checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94"
|
||||
|
||||
[[package]]
|
||||
name = "phf"
|
||||
|
|
@ -3572,9 +3673,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "regex"
|
||||
version = "1.8.3"
|
||||
version = "1.8.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "81ca098a9821bd52d6b24fd8b10bd081f47d39c22778cafaa75a2857a62c6390"
|
||||
checksum = "d0ab3ca65655bb1e41f2a8c8cd662eb4fb035e67c3f78da1d61dffe89d07300f"
|
||||
dependencies = [
|
||||
"aho-corasick",
|
||||
"memchr",
|
||||
|
|
@ -4226,6 +4327,12 @@ dependencies = [
|
|||
"winapi",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "temp-dir"
|
||||
version = "0.1.11"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "af547b166dd1ea4b472165569fc456cfb6818116f854690b0ff205e636523dab"
|
||||
|
||||
[[package]]
|
||||
name = "tempfile"
|
||||
version = "3.5.0"
|
||||
|
|
@ -4359,6 +4466,21 @@ dependencies = [
|
|||
"zerovec",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "tinyvec"
|
||||
version = "1.6.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50"
|
||||
dependencies = [
|
||||
"tinyvec_macros",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "tinyvec_macros"
|
||||
version = "0.1.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20"
|
||||
|
||||
[[package]]
|
||||
name = "tokio"
|
||||
version = "1.28.2"
|
||||
|
|
@ -4593,6 +4715,15 @@ dependencies = [
|
|||
"regex",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "unicode-normalization"
|
||||
version = "0.1.22"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921"
|
||||
dependencies = [
|
||||
"tinyvec",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "unicode-script"
|
||||
version = "0.5.5"
|
||||
|
|
@ -4623,6 +4754,17 @@ version = "0.2.4"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
|
||||
|
||||
[[package]]
|
||||
name = "url"
|
||||
version = "2.4.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "50bff7831e19200a85b17131d085c25d7811bc4e186efdaf54bbd132994a88cb"
|
||||
dependencies = [
|
||||
"form_urlencoded",
|
||||
"idna",
|
||||
"percent-encoding",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "usvg"
|
||||
version = "0.32.0"
|
||||
|
|
@ -5062,9 +5204,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "wgpu-hal"
|
||||
version = "0.16.0"
|
||||
version = "0.16.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "41af2ea7d87bd41ad0a37146252d5f7c26490209f47f544b2ee3b3ff34c7732e"
|
||||
checksum = "74851c2c8e5d97652e74c241d41b0656b31c924a45dcdecde83975717362cfa4"
|
||||
dependencies = [
|
||||
"android_system_properties",
|
||||
"arrayvec 0.7.2",
|
||||
|
|
@ -5534,9 +5676,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "xml-rs"
|
||||
version = "0.8.13"
|
||||
version = "0.8.14"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "2d8f380ae16a37b30e6a2cf67040608071384b1450c189e61bea3ff57cde922d"
|
||||
checksum = "52839dc911083a8ef63efa4d039d1f58b5e409f923e44c80828f206f66e5541c"
|
||||
|
||||
[[package]]
|
||||
name = "xmlparser"
|
||||
|
|
|
|||
|
|
@ -19,4 +19,4 @@ branch = "settings_jammy"
|
|||
|
||||
[workspace.dependencies.cosmic-panel-config]
|
||||
git = "https://github.com/pop-os/cosmic-panel"
|
||||
branch = "settings_jammy"
|
||||
branch = "settings_jammy"
|
||||
|
|
|
|||
|
|
@ -28,6 +28,12 @@ downcast-rs = "1.2.0"
|
|||
cosmic-panel-config = { workspace = true }
|
||||
tracing = "0.1.37"
|
||||
tracing-subscriber = { version = "0.3.17", features = ["env-filter"]}
|
||||
log = "0.4"
|
||||
env_logger = "0.10"
|
||||
url = "2.3.1"
|
||||
freedesktop-desktop-entry = "0.5.0"
|
||||
notify = "6.0.0"
|
||||
anyhow = "1.0"
|
||||
|
||||
[dependencies.i18n-embed]
|
||||
version = "0.13.9"
|
||||
|
|
|
|||
|
|
@ -3,9 +3,11 @@
|
|||
|
||||
use apply::Apply;
|
||||
|
||||
use cosmic_panel_config::CosmicPanelConfig;
|
||||
use cosmic_settings_page::{self as page, section};
|
||||
|
||||
use cosmic::{
|
||||
cosmic_config::config_subscription,
|
||||
iced::{
|
||||
self,
|
||||
event::wayland::{self, WindowEvent, WindowState},
|
||||
|
|
@ -30,13 +32,20 @@ use cosmic::{
|
|||
use crate::{
|
||||
config::Config,
|
||||
pages::{
|
||||
desktop::{self, panel},
|
||||
desktop::{
|
||||
self,
|
||||
panel::{
|
||||
self,
|
||||
applets::{self, APPLET_DND_ICON_ID},
|
||||
},
|
||||
},
|
||||
sound, system, time,
|
||||
},
|
||||
subscription::desktop_files,
|
||||
widget::{page_title, parent_page_button, search_header, sub_page_button},
|
||||
};
|
||||
|
||||
use std::process;
|
||||
use std::{borrow::Cow, process};
|
||||
|
||||
#[allow(clippy::struct_excessive_bools)]
|
||||
#[allow(clippy::module_name_repetitions)]
|
||||
|
|
@ -77,6 +86,8 @@ pub enum Message {
|
|||
ToggleNavBarCondensed,
|
||||
WindowResize(u32, u32),
|
||||
WindowState(WindowState),
|
||||
PanelConfig(CosmicPanelConfig),
|
||||
DesktopInfo,
|
||||
}
|
||||
|
||||
impl Application for SettingsApp {
|
||||
|
|
@ -114,6 +125,8 @@ impl Application for SettingsApp {
|
|||
// app.insert_page::<bluetooth::Page>();
|
||||
|
||||
let desktop_id = app.insert_page::<desktop::Page>().id();
|
||||
// app.insert_page::<panel::Page>();
|
||||
// app.insert_page::<applets::Page>();
|
||||
|
||||
// app.insert_page::<input::Page>();
|
||||
|
||||
|
|
@ -174,9 +187,22 @@ impl Application for SettingsApp {
|
|||
Subscription::batch(vec![
|
||||
window_break,
|
||||
keyboard_nav::subscription().map(Message::KeyboardNav),
|
||||
desktop_files(0).map(|_| Message::DesktopInfo),
|
||||
config_subscription(0, "com.system76.CosmicPanel.panel".into(), 1).map(
|
||||
|(_, e)| match e {
|
||||
Ok(config) => Message::PanelConfig(config),
|
||||
Err((errors, config)) => {
|
||||
for error in errors {
|
||||
log::error!("Error loading panel config: {:?}", error);
|
||||
}
|
||||
Message::PanelConfig(config)
|
||||
}
|
||||
},
|
||||
),
|
||||
])
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_lines)]
|
||||
fn update(&mut self, message: Message) -> iced::Command<Self::Message> {
|
||||
let mut ret = Command::none();
|
||||
match message {
|
||||
|
|
@ -257,17 +283,53 @@ impl Application for SettingsApp {
|
|||
page.update(message);
|
||||
}
|
||||
}
|
||||
crate::pages::Message::Applet(message) => {
|
||||
if let Some(page) = self.pages.page_mut::<applets::Page>() {
|
||||
ret = page.update(message);
|
||||
}
|
||||
}
|
||||
},
|
||||
Message::WindowState(state) => {
|
||||
dbg!(&state);
|
||||
self.sharp_corners = matches!(state, WindowState::Activated);
|
||||
}
|
||||
Message::PanelConfig(config) if config.name.to_lowercase().contains("panel") => {
|
||||
if let Some(page) = self.pages.page_mut::<panel::Page>() {
|
||||
page.update(panel::Message::PanelConfig(config.clone()));
|
||||
}
|
||||
if let Some(page) = self.pages.page_mut::<applets::Page>() {
|
||||
_ = page.update(applets::Message::PanelConfig(config));
|
||||
}
|
||||
}
|
||||
Message::PanelConfig(_) => {} // ignore other config changes for now,
|
||||
Message::DesktopInfo => {
|
||||
if let Some(page) = self.pages.page_mut::<applets::Page>() {
|
||||
// collect the potential applets
|
||||
ret = page.update(applets::Message::Applets(
|
||||
freedesktop_desktop_entry::Iter::new(
|
||||
freedesktop_desktop_entry::default_paths(),
|
||||
)
|
||||
.filter_map(|p| applets::Applet::try_from(Cow::from(p)).ok())
|
||||
.collect(),
|
||||
));
|
||||
}
|
||||
}
|
||||
}
|
||||
ret
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_lines)]
|
||||
fn view(&self, _id: window::Id) -> Element<Message> {
|
||||
fn view(&self, id: window::Id) -> Element<Message> {
|
||||
if let Some(Some(page)) =
|
||||
(id == APPLET_DND_ICON_ID).then(|| self.pages.page::<applets::Page>())
|
||||
{
|
||||
return page.dnd_icon();
|
||||
}
|
||||
if let Some(Some(page)) =
|
||||
(id == applets::ADD_APPLET_DIALOGUE_ID).then(|| self.pages.page::<applets::Page>())
|
||||
{
|
||||
return page.add_applet_view();
|
||||
}
|
||||
|
||||
let (nav_bar_message, nav_bar_toggled) = if self.is_condensed {
|
||||
(
|
||||
Message::ToggleNavBarCondensed,
|
||||
|
|
@ -335,7 +397,7 @@ impl Application for SettingsApp {
|
|||
);
|
||||
}
|
||||
|
||||
let content = container(row(widgets))
|
||||
let content = container(row(widgets).spacing(8))
|
||||
.padding([0, 8, 8, 8])
|
||||
.width(Length::Fill)
|
||||
.height(Length::Fill)
|
||||
|
|
|
|||
|
|
@ -16,6 +16,8 @@ pub mod pages;
|
|||
pub mod theme;
|
||||
pub mod widget;
|
||||
|
||||
pub mod subscription;
|
||||
|
||||
use cosmic::{
|
||||
iced::{wayland::actions::window::SctkWindowSettings, Application, Limits},
|
||||
iced_sctk::settings::InitialSurface,
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
|
|
@ -17,7 +17,7 @@ use cosmic_settings_page::{self as page, section, Section};
|
|||
use slotmap::SlotMap;
|
||||
use std::{borrow::Cow, collections::HashMap};
|
||||
|
||||
mod applets;
|
||||
pub mod applets;
|
||||
|
||||
pub struct Page {
|
||||
config_helper: Option<cosmic_config::Config>,
|
||||
|
|
@ -383,6 +383,7 @@ pub enum Message {
|
|||
Applets,
|
||||
OutputAdded(String, WlOutput),
|
||||
OutputRemoved(WlOutput),
|
||||
PanelConfig(CosmicPanelConfig),
|
||||
}
|
||||
|
||||
impl Page {
|
||||
|
|
@ -390,7 +391,7 @@ impl Page {
|
|||
match message {
|
||||
Message::AutoHidePanel(enabled) => {
|
||||
let helper = self.config_helper.as_ref().unwrap();
|
||||
let panel_config = self.panel_config.as_mut().unwrap();
|
||||
let mut panel_config = self.panel_config.as_mut().unwrap();
|
||||
|
||||
panel_config.autohide = enabled.then_some(AutoHide {
|
||||
wait_time: 1000,
|
||||
|
|
@ -402,7 +403,7 @@ impl Page {
|
|||
}
|
||||
Message::PanelAnchor(anchor) => {
|
||||
let helper = self.config_helper.as_ref().unwrap();
|
||||
let panel_config = self.panel_config.as_mut().unwrap();
|
||||
let mut panel_config = self.panel_config.as_mut().unwrap();
|
||||
|
||||
panel_config.anchor = anchor;
|
||||
|
||||
|
|
@ -410,7 +411,7 @@ impl Page {
|
|||
}
|
||||
Message::Output(name) => {
|
||||
let helper = self.config_helper.as_ref().unwrap();
|
||||
let panel_config = self.panel_config.as_mut().unwrap();
|
||||
let mut panel_config = self.panel_config.as_mut().unwrap();
|
||||
|
||||
panel_config.output = match name {
|
||||
s if s == fl!("all") => CosmicPanelOuput::All,
|
||||
|
|
@ -421,7 +422,7 @@ impl Page {
|
|||
}
|
||||
Message::AnchorGap(enabled) => {
|
||||
let helper = self.config_helper.as_ref().unwrap();
|
||||
let panel_config = self.panel_config.as_mut().unwrap();
|
||||
let mut panel_config = self.panel_config.as_mut().unwrap();
|
||||
|
||||
panel_config.anchor_gap = enabled;
|
||||
|
||||
|
|
@ -429,7 +430,7 @@ impl Page {
|
|||
}
|
||||
Message::PanelSize(size) => {
|
||||
let helper = self.config_helper.as_ref().unwrap();
|
||||
let panel_config = self.panel_config.as_mut().unwrap();
|
||||
let mut panel_config = self.panel_config.as_mut().unwrap();
|
||||
|
||||
panel_config.size = size;
|
||||
|
||||
|
|
@ -437,7 +438,7 @@ impl Page {
|
|||
}
|
||||
Message::Appearance(a) => {
|
||||
let helper = self.config_helper.as_ref().unwrap();
|
||||
let panel_config = self.panel_config.as_mut().unwrap();
|
||||
let mut panel_config = self.panel_config.as_mut().unwrap();
|
||||
|
||||
panel_config.background = a.into();
|
||||
|
||||
|
|
@ -445,7 +446,7 @@ impl Page {
|
|||
}
|
||||
Message::ExtendToEdge(enabled) => {
|
||||
let helper = self.config_helper.as_ref().unwrap();
|
||||
let panel_config = self.panel_config.as_mut().unwrap();
|
||||
let mut panel_config = self.panel_config.as_mut().unwrap();
|
||||
|
||||
panel_config.expand_to_edges = enabled;
|
||||
|
||||
|
|
@ -453,7 +454,7 @@ impl Page {
|
|||
}
|
||||
Message::Opacity(opacity) => {
|
||||
let helper = self.config_helper.as_ref().unwrap();
|
||||
let panel_config = self.panel_config.as_mut().unwrap();
|
||||
let mut panel_config = self.panel_config.as_mut().unwrap();
|
||||
|
||||
panel_config.opacity = opacity;
|
||||
|
||||
|
|
@ -467,6 +468,9 @@ impl Page {
|
|||
Message::OutputRemoved(output) => {
|
||||
self.outputs.remove(&output.id());
|
||||
}
|
||||
Message::PanelConfig(c) => {
|
||||
self.panel_config = Some(c);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@ pub enum Message {
|
|||
Desktop(desktop::Message),
|
||||
Panel(desktop::panel::Message),
|
||||
DesktopWallpaper(desktop::wallpaper::Message),
|
||||
Applet(desktop::panel::applets::Message),
|
||||
External { id: String, message: Vec<u8> },
|
||||
Page(Entity),
|
||||
}
|
||||
|
|
|
|||
95
app/src/subscription/desktop_files.rs
Normal file
95
app/src/subscription/desktop_files.rs
Normal file
|
|
@ -0,0 +1,95 @@
|
|||
use cosmic::iced::subscription;
|
||||
use notify::{Config, Event, RecommendedWatcher, RecursiveMode, Watcher};
|
||||
use std::fmt::Debug;
|
||||
use std::hash::Hash;
|
||||
use tokio::sync::mpsc::{unbounded_channel, UnboundedReceiver};
|
||||
|
||||
#[derive(Debug)]
|
||||
pub enum State {
|
||||
Ready,
|
||||
Waiting {
|
||||
watcher: RecommendedWatcher,
|
||||
rx: UnboundedReceiver<notify::Result<Event>>,
|
||||
},
|
||||
Finished,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Copy)]
|
||||
pub enum DesktopFileEvent {
|
||||
Changed,
|
||||
}
|
||||
|
||||
pub fn desktop_files<I: 'static + Hash + Copy + Send + Sync + Debug>(
|
||||
id: I,
|
||||
) -> cosmic::iced::Subscription<(I, DesktopFileEvent)> {
|
||||
subscription::unfold(id, State::Ready, move |mut state| async move {
|
||||
loop {
|
||||
let (event, new_state) = start_watching(id, state).await;
|
||||
state = new_state;
|
||||
if let Some(event) = event {
|
||||
return (event, state);
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
async fn start_watching<I: Copy>(id: I, state: State) -> (Option<(I, DesktopFileEvent)>, State) {
|
||||
match state {
|
||||
State::Ready => {
|
||||
let paths = freedesktop_desktop_entry::default_paths();
|
||||
// TODO log errors
|
||||
if let Ok((mut watcher, rx)) = async_watcher() {
|
||||
for path in paths {
|
||||
let _ = watcher.watch(path.as_ref(), RecursiveMode::Recursive);
|
||||
}
|
||||
(
|
||||
Some((id, DesktopFileEvent::Changed)),
|
||||
State::Waiting { watcher, rx },
|
||||
)
|
||||
} else {
|
||||
(None, State::Finished)
|
||||
}
|
||||
}
|
||||
State::Waiting { watcher, rx } => {
|
||||
if let Some(rx) = async_watch(rx).await {
|
||||
(
|
||||
Some((id, DesktopFileEvent::Changed)),
|
||||
State::Waiting { watcher, rx },
|
||||
)
|
||||
} else {
|
||||
(None, State::Finished)
|
||||
}
|
||||
}
|
||||
State::Finished => cosmic::iced::futures::future::pending().await,
|
||||
}
|
||||
}
|
||||
|
||||
fn async_watcher() -> notify::Result<(RecommendedWatcher, UnboundedReceiver<notify::Result<Event>>)>
|
||||
{
|
||||
let (tx, rx) = unbounded_channel();
|
||||
|
||||
// Automatically select the best implementation for your platform.
|
||||
// You can also access each implementation directly e.g. INotifyWatcher.
|
||||
let watcher = RecommendedWatcher::new(
|
||||
move |res| {
|
||||
_ = tx.send(res);
|
||||
},
|
||||
Config::default(),
|
||||
)?;
|
||||
|
||||
Ok((watcher, rx))
|
||||
}
|
||||
|
||||
async fn async_watch(
|
||||
mut rx: UnboundedReceiver<notify::Result<Event>>,
|
||||
) -> Option<UnboundedReceiver<notify::Result<Event>>> {
|
||||
// TODO log errors
|
||||
if let Some(res) = rx.recv().await {
|
||||
match res {
|
||||
Ok(_) => return Some(rx),
|
||||
Err(_) => return None,
|
||||
}
|
||||
}
|
||||
|
||||
None
|
||||
}
|
||||
2
app/src/subscription/mod.rs
Normal file
2
app/src/subscription/mod.rs
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
mod desktop_files;
|
||||
pub use desktop_files::*;
|
||||
|
|
@ -83,9 +83,18 @@ panel-missing = Panel Configuration is Missing
|
|||
.fix = Reset to default
|
||||
|
||||
applets = Applets
|
||||
start-segment = Start Segment
|
||||
center-segment = Center Segment
|
||||
end-segment = End Segment
|
||||
|
||||
add = Add
|
||||
add-applet = Add Applet
|
||||
search-applets = Search applets...
|
||||
no-applets-found = No applets found...
|
||||
all = All
|
||||
|
||||
drop-here = Drop applets here
|
||||
|
||||
## Desktop: Wallpaper
|
||||
|
||||
wallpaper = Wallpaper
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue