When clicking a track in the file browser, play it
Includes adding a `playback.is_playable` for working out whether or not a particular file is able to be played
This commit is contained in:
@@ -65,11 +65,15 @@ return screen:new {
|
||||
iterator = filesystem.iterator(item:filepath()),
|
||||
breadcrumb = item:filepath()
|
||||
})
|
||||
end
|
||||
if item:filepath():match("%.playlist$") then
|
||||
elseif item:filepath():match("%.playlist$") then
|
||||
queue.open_playlist(item:filepath())
|
||||
playback.playing:set(true)
|
||||
backstack.push(playing:new())
|
||||
elseif playback.is_playable(item:filepath()) then
|
||||
queue.clear()
|
||||
queue.add(item:filepath())
|
||||
playback.playing:set(true)
|
||||
backstack.push(playing:new())
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user