mirror of
https://github.com/librespot-org/librespot.git
synced 2024-12-28 17:21:52 +00:00
add persist-volume to ConnectConfig
This commit is contained in:
parent
e23c2336c9
commit
fa66dd312b
3 changed files with 4 additions and 0 deletions
|
@ -25,6 +25,7 @@ pub struct SpircTask {
|
||||||
player: Player,
|
player: Player,
|
||||||
mixer: Box<Mixer>,
|
mixer: Box<Mixer>,
|
||||||
linear_volume: bool,
|
linear_volume: bool,
|
||||||
|
persist_volume: Option<String>,
|
||||||
|
|
||||||
sequence: SeqGenerator<u32>,
|
sequence: SeqGenerator<u32>,
|
||||||
|
|
||||||
|
@ -243,6 +244,7 @@ impl Spirc {
|
||||||
player: player,
|
player: player,
|
||||||
mixer: mixer,
|
mixer: mixer,
|
||||||
linear_volume: linear_volume,
|
linear_volume: linear_volume,
|
||||||
|
persist_volume: persist_volume,
|
||||||
|
|
||||||
sequence: SeqGenerator::new(1),
|
sequence: SeqGenerator::new(1),
|
||||||
|
|
||||||
|
|
|
@ -83,4 +83,5 @@ pub struct ConnectConfig {
|
||||||
pub device_type: DeviceType,
|
pub device_type: DeviceType,
|
||||||
pub volume: i32,
|
pub volume: i32,
|
||||||
pub linear_volume: bool,
|
pub linear_volume: bool,
|
||||||
|
pub persist_volume: Option<String>,
|
||||||
}
|
}
|
||||||
|
|
|
@ -305,6 +305,7 @@ fn setup(args: &[String]) -> Setup {
|
||||||
device_type: device_type,
|
device_type: device_type,
|
||||||
volume: initial_volume,
|
volume: initial_volume,
|
||||||
linear_volume: matches.opt_present("linear-volume"),
|
linear_volume: matches.opt_present("linear-volume"),
|
||||||
|
persist_volume: persist_volume,
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue