diff --git a/Cargo.lock b/Cargo.lock index b8a7d1a7..74b821f9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -697,6 +697,31 @@ dependencies = [ "cfg-if", ] +[[package]] +name = "crossterm" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e64e6c0fbe2c17357405f7c758c1ef960fce08bdfb2c03d88d2a18d7e09c4b67" +dependencies = [ + "bitflags 1.3.2", + "crossterm_winapi", + "libc", + "mio", + "parking_lot 0.12.1", + "signal-hook", + "signal-hook-mio", + "winapi", +] + +[[package]] +name = "crossterm_winapi" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "acdd7c62a3665c7f6830a51635d9ac9b23ed385797f70a83bb8bafe9c572ab2b" +dependencies = [ + "winapi", +] + [[package]] name = "crypto-common" version = "0.1.6" @@ -735,6 +760,7 @@ dependencies = [ "ahash", "cfg-if", "crossbeam-channel", + "crossterm", "cursive_core", "lazy_static", "libc", @@ -1905,6 +1931,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "927a765cd3fc26206e66b296465fa9d3e5ab003e651c1b3c060e7956d96b19d2" dependencies = [ "libc", + "log", "wasi", "windows-sys", ] @@ -3219,6 +3246,17 @@ dependencies = [ "signal-hook-registry", ] +[[package]] +name = "signal-hook-mio" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29ad2e15f37ec9a6cc544097b78a1ec90001e9f71b81338ca39f430adaca99af" +dependencies = [ + "libc", + "mio", + "signal-hook", +] + [[package]] name = "signal-hook-registry" version = "1.4.1" diff --git a/Cargo.toml b/Cargo.toml index b7aa3959..6db9698e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -87,10 +87,11 @@ optional = true [features] alsa_backend = ["librespot-playback/alsa-backend"] cover = ["ioctl-rs"] # Support displaying the album cover -default = ["share_clipboard", "pulseaudio_backend", "mpris", "notify", "termion_backend"] +default = ["share_clipboard", "pulseaudio_backend", "mpris", "notify", "crossterm_backend"] mpris = ["zbus"] # Allow ncspot to be controlled via MPRIS API ncurses_backend = ["cursive/ncurses-backend"] notify = ["notify-rust"] # Show what's playing via a notification +crossterm_backend = ["cursive/crossterm-backend"] pancurses_backend = ["cursive/pancurses-backend", "pancurses/win32"] portaudio_backend = ["librespot-playback/portaudio-backend"] pulseaudio_backend = ["librespot-playback/pulseaudio-backend"]