Music player reads mpris:length instead of xesam:length
This commit is contained in:
parent
2144a2ab3d
commit
452cb9c708
|
@ -41,7 +41,7 @@ impl<'a> From<MetadataMap<'a>> for Metadata {
|
|||
.get("xesam:trackNumber")
|
||||
.and_then(|v| TryFrom::try_from(v).ok()),
|
||||
length: map
|
||||
.get("xesam:length")
|
||||
.get("mpris:length")
|
||||
.and_then(|v| i64::try_from(v).ok())
|
||||
.map(|us| us as f32 / 1_000_000.0), // 1,000,000 microseconds in a second
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue