mirror of
https://github.com/issadarkthing/gomu.git
synced 2025-04-25 13:48:49 +08:00
fix: playing song is saved when queue is empty
This commit is contained in:
parent
ca5051fa13
commit
ae123b4db1
@ -210,6 +210,9 @@ func (p *PlayingBar) setDefault() {
|
||||
"%s ┣%s┫ %s", "00:00", strings.Repeat("━", width/2), "00:00",
|
||||
)
|
||||
p.text.SetText(text)
|
||||
if p.albumPhoto != nil {
|
||||
p.albumPhoto.Clear()
|
||||
}
|
||||
}
|
||||
|
||||
// Skips the current playing song
|
||||
|
3
queue.go
3
queue.go
@ -210,8 +210,7 @@ func (q *Queue) saveQueue() error {
|
||||
currentSongInQueue = true
|
||||
}
|
||||
}
|
||||
if !currentSongInQueue {
|
||||
// if !currentSongInQueue && len(q.items) != 0 {
|
||||
if !currentSongInQueue && len(q.items) != 0 {
|
||||
hashed := sha1Hex(getName(currentSongPath))
|
||||
content.WriteString(hashed + "\n")
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user