mirror of
https://github.com/AynaLivePlayer/AynaLivePlayer.git
synced 2026-05-05 06:45:47 +08:00
fyne update. able to choose to display cover or not
This commit is contained in:
@@ -7,8 +7,9 @@ import (
|
||||
)
|
||||
|
||||
type playerConfig struct {
|
||||
Volume float64
|
||||
AudioDevice string
|
||||
Volume float64
|
||||
AudioDevice string
|
||||
DisplayMusicCover bool
|
||||
}
|
||||
|
||||
func (p *playerConfig) Name() string {
|
||||
@@ -24,7 +25,8 @@ func (p *playerConfig) OnSave() {
|
||||
}
|
||||
|
||||
var cfg = &playerConfig{
|
||||
Volume: 100,
|
||||
Volume: 100,
|
||||
DisplayMusicCover: true,
|
||||
}
|
||||
|
||||
func restoreConfig() {
|
||||
|
||||
@@ -212,7 +212,7 @@ func registerCmdHandler() {
|
||||
})
|
||||
log.Debugf("mpv command loadfile %s %s", mediaInfo.Title, mediaUrl.Url)
|
||||
cmd := []string{"loadfile", mediaUrl.Url}
|
||||
if media.Info.Cover.Url != "" {
|
||||
if cfg.DisplayMusicCover && media.Info.Cover.Url != "" {
|
||||
// add media cover to video channel.
|
||||
// https://mpv.io/manual/master/#command-interface-[<options>]]]
|
||||
// api changes after client version 2.3 (0.38.0
|
||||
|
||||
Reference in New Issue
Block a user