Convert to library
This commit is contained in:
parent
d6c58991c0
commit
87ad2f7dd9
8 changed files with 1377 additions and 1335 deletions
157
Cargo.lock
generated
157
Cargo.lock
generated
|
|
@ -210,9 +210,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "anstyle"
|
||||
version = "1.0.4"
|
||||
version = "1.0.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "7079075b41f533b8c61d2a4d073c4676e1f8b249ff94a393b0595db304e0dd87"
|
||||
checksum = "2faccea4cc4ab4a667ce676a30e8ec13922a692c99bb8f5b11f1502c72e04220"
|
||||
|
||||
[[package]]
|
||||
name = "anstyle-parse"
|
||||
|
|
@ -413,7 +413,7 @@ dependencies = [
|
|||
"futures-lite 2.2.0",
|
||||
"parking",
|
||||
"polling 3.3.2",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"slab",
|
||||
"tracing",
|
||||
"windows-sys 0.52.0",
|
||||
|
|
@ -452,7 +452,7 @@ dependencies = [
|
|||
"cfg-if 1.0.0",
|
||||
"event-listener 3.1.0",
|
||||
"futures-lite 1.13.0",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"windows-sys 0.48.0",
|
||||
]
|
||||
|
||||
|
|
@ -479,7 +479,7 @@ dependencies = [
|
|||
"cfg-if 1.0.0",
|
||||
"futures-core",
|
||||
"futures-io",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"signal-hook-registry",
|
||||
"slab",
|
||||
"windows-sys 0.48.0",
|
||||
|
|
@ -525,7 +525,7 @@ name = "atomicwrites"
|
|||
version = "0.4.2"
|
||||
source = "git+https://github.com/jackpot51/rust-atomicwrites#043ab4859d53ffd3d55334685303d8df39c9f768"
|
||||
dependencies = [
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"tempfile",
|
||||
"windows-sys 0.48.0",
|
||||
]
|
||||
|
|
@ -751,7 +751,7 @@ dependencies = [
|
|||
"bitflags 2.4.2",
|
||||
"log",
|
||||
"polling 3.3.2",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"slab",
|
||||
"thiserror",
|
||||
]
|
||||
|
|
@ -763,7 +763,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|||
checksum = "0f0ea9b9476c7fad82841a8dbb380e2eae480c21910feba80725b46931ed8f02"
|
||||
dependencies = [
|
||||
"calloop 0.12.4",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"wayland-backend",
|
||||
"wayland-client 0.31.2",
|
||||
]
|
||||
|
|
@ -1062,7 +1062,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "cosmic-config"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"atomicwrites",
|
||||
"cosmic-config-derive",
|
||||
|
|
@ -1079,7 +1079,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "cosmic-config-derive"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"quote",
|
||||
"syn 1.0.109",
|
||||
|
|
@ -1091,7 +1091,7 @@ version = "0.1.0"
|
|||
dependencies = [
|
||||
"chrono",
|
||||
"dirs",
|
||||
"env_logger",
|
||||
"env_logger 0.11.1",
|
||||
"fastrand 2.0.1",
|
||||
"fork",
|
||||
"i18n-embed",
|
||||
|
|
@ -1114,7 +1114,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "cosmic-text"
|
||||
version = "0.10.0"
|
||||
source = "git+https://github.com/pop-os/cosmic-text.git#e0ae465f918cd1cffca3a8239547dcf8166d3f77"
|
||||
source = "git+https://github.com/pop-os/cosmic-text.git#1b025ae56e0122cff5798b9f54fc56d47a182d2b"
|
||||
dependencies = [
|
||||
"bitflags 2.4.2",
|
||||
"fontdb",
|
||||
|
|
@ -1136,7 +1136,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "cosmic-theme"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"almost",
|
||||
"cosmic-config",
|
||||
|
|
@ -1298,12 +1298,12 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "darling"
|
||||
version = "0.20.3"
|
||||
version = "0.20.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "0209d94da627ab5605dcccf08bb18afa5009cfbef48d8a8b7d7bdbc79be25c5e"
|
||||
checksum = "fc5d6b04b3fd0ba9926f945895de7d806260a2d7431ba82e7edaecb043c4c6b8"
|
||||
dependencies = [
|
||||
"darling_core 0.20.3",
|
||||
"darling_macro 0.20.3",
|
||||
"darling_core 0.20.5",
|
||||
"darling_macro 0.20.5",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
|
@ -1322,9 +1322,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "darling_core"
|
||||
version = "0.20.3"
|
||||
version = "0.20.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621"
|
||||
checksum = "04e48a959bcd5c761246f5d090ebc2fbf7b9cd527a492b07a67510c108f1e7e3"
|
||||
dependencies = [
|
||||
"fnv",
|
||||
"ident_case",
|
||||
|
|
@ -1347,11 +1347,11 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "darling_macro"
|
||||
version = "0.20.3"
|
||||
version = "0.20.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5"
|
||||
checksum = "1d1545d67a2149e1d93b7e5c7752dce5a7426eb5d1357ddcfd89336b94444f77"
|
||||
dependencies = [
|
||||
"darling_core 0.20.3",
|
||||
"darling_core 0.20.5",
|
||||
"quote",
|
||||
"syn 2.0.48",
|
||||
]
|
||||
|
|
@ -1402,7 +1402,7 @@ version = "0.1.6"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4e8ef033054e131169b8f0f9a7af8f5533a9436fadf3c500ed547f730f07090d"
|
||||
dependencies = [
|
||||
"darling 0.20.3",
|
||||
"darling 0.20.5",
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn 2.0.48",
|
||||
|
|
@ -1582,6 +1582,15 @@ dependencies = [
|
|||
"regex",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "env_logger"
|
||||
version = "0.10.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4cd405aab171cb85d6735e5c8d9db038c17d3ca007a4d2c25f337935c3d90580"
|
||||
dependencies = [
|
||||
"log",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "env_logger"
|
||||
version = "0.11.1"
|
||||
|
|
@ -1842,6 +1851,12 @@ version = "1.0.7"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"
|
||||
|
||||
[[package]]
|
||||
name = "font-types"
|
||||
version = "0.4.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "0bd7f3ea17572640b606b35df42cfb6ecdf003704b062580e59918692190b73d"
|
||||
|
||||
[[package]]
|
||||
name = "fontconfig-parser"
|
||||
version = "0.5.6"
|
||||
|
|
@ -1909,9 +1924,9 @@ checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b"
|
|||
|
||||
[[package]]
|
||||
name = "fork"
|
||||
version = "0.1.22"
|
||||
version = "0.1.23"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "bf2ca97a59201425e7ee4d197c9c4fea282fe87a97d666a580bda889b95b8e88"
|
||||
checksum = "60e74d3423998a57e9d906e49252fb79eb4a04d5cdfe188fb1b7ff9fc076a8ed"
|
||||
dependencies = [
|
||||
"libc",
|
||||
]
|
||||
|
|
@ -2425,7 +2440,7 @@ dependencies = [
|
|||
"serde",
|
||||
"serde_derive",
|
||||
"thiserror",
|
||||
"toml 0.8.8",
|
||||
"toml 0.8.9",
|
||||
"unic-langid",
|
||||
]
|
||||
|
||||
|
|
@ -2511,7 +2526,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"iced_accessibility",
|
||||
"iced_core",
|
||||
|
|
@ -2526,7 +2541,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_accessibility"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"accesskit",
|
||||
"accesskit_winit",
|
||||
|
|
@ -2535,7 +2550,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_core"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"bitflags 1.3.2",
|
||||
"instant",
|
||||
|
|
@ -2551,7 +2566,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_futures"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"futures",
|
||||
"iced_core",
|
||||
|
|
@ -2564,7 +2579,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_graphics"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"bitflags 1.3.2",
|
||||
"bytemuck",
|
||||
|
|
@ -2587,7 +2602,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_renderer"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"iced_graphics",
|
||||
"iced_tiny_skia",
|
||||
|
|
@ -2600,7 +2615,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_runtime"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"iced_core",
|
||||
"iced_futures",
|
||||
|
|
@ -2610,7 +2625,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_style"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"iced_core",
|
||||
"once_cell",
|
||||
|
|
@ -2620,7 +2635,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_tiny_skia"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"bytemuck",
|
||||
"cosmic-text",
|
||||
|
|
@ -2638,7 +2653,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_wgpu"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"bitflags 1.3.2",
|
||||
"bytemuck",
|
||||
|
|
@ -2658,7 +2673,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_widget"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"iced_renderer",
|
||||
"iced_runtime",
|
||||
|
|
@ -2672,7 +2687,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "iced_winit"
|
||||
version = "0.12.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"iced_graphics",
|
||||
"iced_runtime",
|
||||
|
|
@ -2747,9 +2762,9 @@ checksum = "029d73f573d8e8d63e6d5020011d3255b28c3ba85d6cf870a07184ed23de9284"
|
|||
|
||||
[[package]]
|
||||
name = "indexmap"
|
||||
version = "2.2.1"
|
||||
version = "2.2.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "433de089bd45971eecf4668ee0ee8f4cec17db4f8bd8f7bc3197a6ce37aa7d9b"
|
||||
checksum = "824b2ae422412366ba479e8111fd301f7b5faece8149317bb81925979a53f520"
|
||||
dependencies = [
|
||||
"equivalent",
|
||||
"hashbrown",
|
||||
|
|
@ -2959,14 +2974,14 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "libc"
|
||||
version = "0.2.152"
|
||||
version = "0.2.153"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "13e3bf6590cbc649f4d1a3eefc9d5d6eb746f5200ffb04e5e142700b8faa56e7"
|
||||
checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd"
|
||||
|
||||
[[package]]
|
||||
name = "libcosmic"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#1291a48d4d62f1da5ca178292a3ce0082204d8d4"
|
||||
source = "git+https://github.com/pop-os/libcosmic.git#ca1469a6b26eb7fbdc8e28d6135e86593e6a77fd"
|
||||
dependencies = [
|
||||
"apply",
|
||||
"ashpd",
|
||||
|
|
@ -4090,7 +4105,7 @@ dependencies = [
|
|||
"cfg-if 1.0.0",
|
||||
"concurrent-queue",
|
||||
"pin-project-lite",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"tracing",
|
||||
"windows-sys 0.52.0",
|
||||
]
|
||||
|
|
@ -4161,9 +4176,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "profiling"
|
||||
version = "1.0.13"
|
||||
version = "1.0.14"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d135ede8821cf6376eb7a64148901e1690b788c11ae94dc297ae917dbc91dc0e"
|
||||
checksum = "0f0f7f43585c34e4fdd7497d746bc32e14458cf11c69341cc0587b1d825dde42"
|
||||
|
||||
[[package]]
|
||||
name = "pure-rust-locales"
|
||||
|
|
@ -4291,6 +4306,15 @@ version = "0.5.0"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3b42e27ef78c35d3998403c1d26f3efd9e135d3e5121b0a4845cc5cc27547f4f"
|
||||
|
||||
[[package]]
|
||||
name = "read-fonts"
|
||||
version = "0.15.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "7555e052e772f964a1c99f1434f6a2c3a47a5f8e4292236921f121a7753cb2b5"
|
||||
dependencies = [
|
||||
"font-types",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "redox_syscall"
|
||||
version = "0.2.16"
|
||||
|
|
@ -4504,9 +4528,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "rustix"
|
||||
version = "0.38.30"
|
||||
version = "0.38.31"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "322394588aaf33c24007e8bb3238ee3e4c5c09c084ab32bc73890b99ff326bca"
|
||||
checksum = "6ea3e1a662af26cd7a3ba09c0297a31af215563ecf42817c98df621387f4e949"
|
||||
dependencies = [
|
||||
"bitflags 2.4.2",
|
||||
"errno",
|
||||
|
|
@ -4768,7 +4792,7 @@ dependencies = [
|
|||
"libc",
|
||||
"log",
|
||||
"memmap2 0.9.4",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"thiserror",
|
||||
"wayland-backend",
|
||||
"wayland-client 0.31.2",
|
||||
|
|
@ -4830,7 +4854,7 @@ dependencies = [
|
|||
"objc",
|
||||
"raw-window-handle 0.5.2",
|
||||
"redox_syscall 0.4.1",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"tiny-xlib",
|
||||
"wasm-bindgen",
|
||||
"wayland-backend",
|
||||
|
|
@ -4911,10 +4935,11 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "swash"
|
||||
version = "0.1.8"
|
||||
version = "0.1.12"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3b7c73c813353c347272919aa1af2885068b05e625e5532b43049e4f641ae77f"
|
||||
checksum = "d06ff4664af8923625604261c645f5c4cc610cc83c84bec74b50d76237089de7"
|
||||
dependencies = [
|
||||
"read-fonts",
|
||||
"yazi",
|
||||
"zeno",
|
||||
]
|
||||
|
|
@ -4959,7 +4984,7 @@ dependencies = [
|
|||
"cfg-expr",
|
||||
"heck",
|
||||
"pkg-config",
|
||||
"toml 0.8.8",
|
||||
"toml 0.8.9",
|
||||
"version-compare",
|
||||
]
|
||||
|
||||
|
|
@ -5004,7 +5029,7 @@ dependencies = [
|
|||
"cfg-if 1.0.0",
|
||||
"fastrand 2.0.1",
|
||||
"redox_syscall 0.4.1",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"windows-sys 0.52.0",
|
||||
]
|
||||
|
||||
|
|
@ -5023,7 +5048,7 @@ version = "0.2.14"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "6159ab4116165c99fc88cce31f99fa2c9dbe08d3691cb38da02fc3b45f357d2b"
|
||||
dependencies = [
|
||||
"env_logger",
|
||||
"env_logger 0.10.2",
|
||||
"test-log-macros",
|
||||
]
|
||||
|
||||
|
|
@ -5205,14 +5230,14 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "toml"
|
||||
version = "0.8.8"
|
||||
version = "0.8.9"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a1a195ec8c9da26928f773888e0742ca3ca1040c6cd859c919c9f59c1954ab35"
|
||||
checksum = "c6a4b9e8023eb94392d3dca65d717c53abc5dad49c07cb65bb8fcd87115fa325"
|
||||
dependencies = [
|
||||
"serde",
|
||||
"serde_spanned",
|
||||
"toml_datetime",
|
||||
"toml_edit 0.21.0",
|
||||
"toml_edit 0.21.1",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
|
@ -5237,9 +5262,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "toml_edit"
|
||||
version = "0.21.0"
|
||||
version = "0.21.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d34d383cd00a163b4a5b85053df514d45bc330f6de7737edfe0a93311d1eaa03"
|
||||
checksum = "6a8534fd7f78b5405e860340ad6575217ce99f38d4d5c8f2442cb5ecb50090e1"
|
||||
dependencies = [
|
||||
"indexmap",
|
||||
"serde",
|
||||
|
|
@ -5644,7 +5669,7 @@ checksum = "9d50fa61ce90d76474c87f5fc002828d81b32677340112b4ef08079a9d459a40"
|
|||
dependencies = [
|
||||
"cc",
|
||||
"downcast-rs",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"scoped-tls",
|
||||
"smallvec",
|
||||
"wayland-sys 0.31.1",
|
||||
|
|
@ -5689,7 +5714,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|||
checksum = "82fb96ee935c2cea6668ccb470fb7771f6215d1691746c2d896b447a00ad3f1f"
|
||||
dependencies = [
|
||||
"bitflags 2.4.2",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"wayland-backend",
|
||||
"wayland-scanner 0.31.1",
|
||||
]
|
||||
|
|
@ -5757,7 +5782,7 @@ version = "0.31.1"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "71ce5fa868dd13d11a0d04c5e2e65726d0897be8de247c0c5a65886e283231ba"
|
||||
dependencies = [
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"wayland-client 0.31.2",
|
||||
"xcursor",
|
||||
]
|
||||
|
|
@ -6383,9 +6408,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "winnow"
|
||||
version = "0.5.35"
|
||||
version = "0.5.36"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "1931d78a9c73861da0134f453bb1f790ce49b2e30eba8410b4b79bac72b46a2d"
|
||||
checksum = "818ce546a11a9986bc24f93d0cdf38a8a1a400f1473ea8c82e59f6e0ffab9249"
|
||||
dependencies = [
|
||||
"memchr",
|
||||
]
|
||||
|
|
@ -6425,7 +6450,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|||
checksum = "f8f25ead8c7e4cba123243a6367da5d3990e0d3affa708ea19dce96356bd9f1a"
|
||||
dependencies = [
|
||||
"gethostname 0.4.3",
|
||||
"rustix 0.38.30",
|
||||
"rustix 0.38.31",
|
||||
"x11rb-protocol 0.13.0",
|
||||
]
|
||||
|
||||
|
|
|
|||
1190
src/app.rs
Normal file
1190
src/app.rs
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -2,7 +2,7 @@ use cosmic::iced::keyboard::{KeyCode, Modifiers};
|
|||
use serde::{Deserialize, Serialize};
|
||||
use std::{collections::HashMap, fmt};
|
||||
|
||||
use crate::Action;
|
||||
use crate::app::Action;
|
||||
|
||||
#[derive(Clone, Copy, Debug, Deserialize, Eq, Hash, Ord, PartialEq, PartialOrd, Serialize)]
|
||||
pub enum Modifier {
|
||||
|
|
|
|||
85
src/lib.rs
Normal file
85
src/lib.rs
Normal file
|
|
@ -0,0 +1,85 @@
|
|||
// Copyright 2023 System76 <info@system76.com>
|
||||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
|
||||
use cosmic::{
|
||||
app::{Application, Settings},
|
||||
cosmic_config::{self, CosmicConfigEntry},
|
||||
};
|
||||
use std::{path::PathBuf, process};
|
||||
|
||||
use app::{App, Flags};
|
||||
mod app;
|
||||
use config::{Config, CONFIG_VERSION};
|
||||
mod config;
|
||||
mod key_bind;
|
||||
mod localize;
|
||||
mod menu;
|
||||
mod mime_icon;
|
||||
mod mouse_area;
|
||||
mod operation;
|
||||
mod tab;
|
||||
|
||||
pub fn home_dir() -> PathBuf {
|
||||
match dirs::home_dir() {
|
||||
Some(home) => home,
|
||||
None => {
|
||||
log::warn!("failed to locate home directory");
|
||||
PathBuf::from("/")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Runs application with these settings
|
||||
#[rustfmt::skip]
|
||||
pub fn main() -> Result<(), Box<dyn std::error::Error>> {
|
||||
#[cfg(all(unix, not(target_os = "redox")))]
|
||||
match fork::daemon(true, true) {
|
||||
Ok(fork::Fork::Child) => (),
|
||||
Ok(fork::Fork::Parent(_child_pid)) => process::exit(0),
|
||||
Err(err) => {
|
||||
eprintln!("failed to daemonize: {:?}", err);
|
||||
process::exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
env_logger::Builder::from_env(env_logger::Env::default().default_filter_or("warn")).init();
|
||||
|
||||
localize::localize();
|
||||
|
||||
let (config_handler, config) = match cosmic_config::Config::new(App::APP_ID, CONFIG_VERSION) {
|
||||
Ok(config_handler) => {
|
||||
let config = match Config::get_entry(&config_handler) {
|
||||
Ok(ok) => ok,
|
||||
Err((errs, config)) => {
|
||||
log::info!("errors loading config: {:?}", errs);
|
||||
config
|
||||
}
|
||||
};
|
||||
(Some(config_handler), config)
|
||||
}
|
||||
Err(err) => {
|
||||
log::error!("failed to create config handler: {}", err);
|
||||
(None, Config::default())
|
||||
}
|
||||
};
|
||||
|
||||
let mut settings = Settings::default();
|
||||
settings = settings.theme(config.app_theme.theme());
|
||||
|
||||
#[cfg(target_os = "redox")]
|
||||
{
|
||||
// Redox does not support resize if doing CSDs
|
||||
settings = settings.client_decorations(false);
|
||||
}
|
||||
|
||||
//TODO: allow size limits on iced_winit
|
||||
//settings = settings.size_limits(Limits::NONE.min_width(400.0).min_height(200.0));
|
||||
|
||||
let flags = Flags {
|
||||
config_handler,
|
||||
config,
|
||||
};
|
||||
cosmic::app::run::<App>(settings, flags)?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
1265
src/main.rs
1265
src/main.rs
File diff suppressed because it is too large
Load diff
|
|
@ -13,7 +13,12 @@ use cosmic::{
|
|||
};
|
||||
use std::collections::HashMap;
|
||||
|
||||
use crate::{fl, tab, Action, ContextPage, KeyBind, Location, Message, Tab};
|
||||
use crate::{
|
||||
app::{Action, ContextPage, Message},
|
||||
fl,
|
||||
key_bind::KeyBind,
|
||||
tab::{self, Location, Tab},
|
||||
};
|
||||
|
||||
macro_rules! menu_button {
|
||||
($($x:expr),+ $(,)?) => (
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use cosmic::iced::futures::{channel::mpsc, SinkExt};
|
||||
use std::{error::Error, future::Future, io, path::PathBuf, time};
|
||||
|
||||
use crate::Message;
|
||||
use crate::app::Message;
|
||||
|
||||
fn err_str<T: ToString>(err: T) -> String {
|
||||
err.to_string()
|
||||
|
|
|
|||
|
|
@ -417,7 +417,7 @@ pub struct Item {
|
|||
}
|
||||
|
||||
impl Item {
|
||||
pub fn property_view(&self, core: &Core) -> Element<crate::Message> {
|
||||
pub fn property_view(&self, core: &Core) -> Element<crate::app::Message> {
|
||||
let mut section = widget::settings::view_section("");
|
||||
section = section.add(widget::settings::item::item_row(vec![
|
||||
widget::icon::icon(self.icon_handle_list.clone())
|
||||
|
|
@ -1022,7 +1022,7 @@ mod tests {
|
|||
use test_log::test;
|
||||
|
||||
use super::scan_path;
|
||||
use crate::test_utils::{
|
||||
use crate::app::test_utils::{
|
||||
empty_fs, eq_path_item, simple_fs, sort_files, NAME_LEN, NUM_DIRS, NUM_FILES, NUM_NESTED,
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue