Media Item HD Attribute Source (#1165)

* Clear todo by using the stream to indicate having HD

* Use only media stream
This commit is contained in:
Daniel Chick 2024-08-06 12:49:22 -05:00 committed by GitHub
parent 64b22d4e36
commit c0f8897a5f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -22,14 +22,13 @@ extension ItemView {
.asAttributeStyle(.outline)
}
// TODO: Have stream indicate this instead?
if viewModel.item.isHD ?? false {
Text("HD")
.asAttributeStyle(.fill)
}
if let mediaStreams = viewModel.selectedMediaSource?.mediaStreams {
if mediaStreams.hasHDVideo {
Text("HD")
.asAttributeStyle(.fill)
}
if mediaStreams.has4KVideo {
Text("4K")
.asAttributeStyle(.fill)