fix #108
This commit is contained in:
parent
4dbaa8f53d
commit
6ba500596d
2 changed files with 14 additions and 10 deletions
|
@ -2367,10 +2367,9 @@ const app = new Vue({
|
|||
}
|
||||
|
||||
let query = app.library.songs.listing.map(item => new MusicKit.MediaItem(item));
|
||||
try {
|
||||
app.mk.stop()
|
||||
} catch (e) {
|
||||
}
|
||||
|
||||
|
||||
app.mk.stop().then(() => {
|
||||
this.mk.clearQueue().then(function (_) {
|
||||
if (app.mk.shuffleMode == 1){ shuffleArray(query)}
|
||||
app.mk.queue.append(query)
|
||||
|
@ -2385,6 +2384,7 @@ const app = new Vue({
|
|||
app.mk.play()
|
||||
}
|
||||
})
|
||||
})
|
||||
} else {
|
||||
app.mk.stop().then(() => {
|
||||
if (truekind == "playlists" && (id.startsWith("p.") || id.startsWith("pl.u"))){
|
||||
|
@ -2392,15 +2392,13 @@ const app = new Vue({
|
|||
app.mk.changeToMediaAtIndex(app.mk.queue._itemIDs.indexOf(item.id) ?? 1).then(function(){
|
||||
if ((app.showingPlaylist && app.showingPlaylist.id == id)) {
|
||||
let query = app.showingPlaylist.relationships.tracks.data.map(item => new MusicKit.MediaItem(item));
|
||||
if (query.length > 100) {
|
||||
let u = query.slice(100); if (app.mk.shuffleMode == 1) { shuffleArray(u) }
|
||||
app.mk.queue.append(u)}
|
||||
let u = query; if (app.mk.shuffleMode == 1) { shuffleArray(u) }
|
||||
app.mk.queue.append(u)
|
||||
} else {
|
||||
app.getPlaylistFromID(id, true).then(function () {
|
||||
let query = app.showingPlaylist.relationships.tracks.data.map(item => new MusicKit.MediaItem(item));
|
||||
if (query.length > 100) {
|
||||
let u = query.slice(100); if (app.mk.shuffleMode == 1) { shuffleArray(u) }
|
||||
app.mk.queue.append(u)}
|
||||
let u = query; if (app.mk.shuffleMode == 1) { shuffleArray(u) }
|
||||
app.mk.queue.append(u)
|
||||
})
|
||||
}
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue