Expose gapless playback config option

This commit is contained in:
Qluxzz
2021-01-07 17:55:43 +01:00
committed by Henrik Friedrichsen
parent 9de8498e47
commit 9bc98f70fd
3 changed files with 3 additions and 1 deletions

View File

@@ -171,6 +171,7 @@ Possible configuration values are:
* `notify`: Enable or disable desktop notifications, off by default <true/false>
* `bitrate`: The audio bitrate to use for streaming, can be 96, 160, or 320 (default is 320)
* `album_column`: Show album column for tracks, on by default <true/false>
* `gapless`: Allows gapless playback <true/false> (default is false)
Keybindings can be configured in `[keybindings]` section in `config.toml`, e.g. as such:

View File

@@ -23,6 +23,7 @@ pub struct ConfigValues {
pub notify: Option<bool>,
pub bitrate: Option<u32>,
pub album_column: Option<bool>,
pub gapless: Option<bool>,
}
#[derive(Serialize, Deserialize, Debug, Default, Clone)]

View File

@@ -421,7 +421,7 @@ impl Spotify {
}
let player_config = PlayerConfig {
gapless: false,
gapless: cfg.values().gapless.unwrap_or(false),
bitrate: bitrate.unwrap_or(Bitrate::Bitrate320),
normalisation: cfg.values().volnorm.unwrap_or(false),
normalisation_pregain: cfg.values().volnorm_pregain.unwrap_or(0.0),