Track sorting and listing improvements. (Bug 796305 and bug 841977) #23961
Conversation
Hubert Figuière (hfiguiere) started tests. Results |
b96da07
to
a72dc3b
Compare
Hubert Figuière (hfiguiere) started tests. Results |
a72dc3b
to
294d9df
Compare
Hubert Figuière (hfiguiere) started tests. Results |
294d9df
to
a25f278
Compare
Hubert Figuière (hfiguiere) started tests. Results |
e458adf
to
97b0ec1
Compare
Hubert Figuière (hfiguiere) started tests. Results |
@@ -1147,7 +1180,12 @@ function createListElement(option, data, index, highlight) { | |||
|
|||
var indexSpan = document.createElement('span'); | |||
indexSpan.className = 'list-song-index'; | |||
indexSpan.textContent = index + 1; | |||
var trackNum = data.metadata.tracknum; | |||
if (data.multidisc) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should probably be extra-careful here and only show the disc number if data.metadata.discnum
exists. Otherwise, we'll get something weird like undefined.01
for the index.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good point. I'll update to
if (data.metadata.discnum && data.multidisc)
97b0ec1
to
6d9f90c
Compare
Hubert Figuière (hfiguiere) started tests. Results |
6d9f90c
to
c6df514
Compare
Hubert Figuière (hfiguiere) started tests. Results |
Hubert Figuière (hfiguiere) started tests. Results |
f09a4e5
to
84c8f20
Compare
Hubert Figuière (hfiguiere) started tests. Results |
Hubert Figuière (hfiguiere) started tests. Results |
0d6182e
to
34ab35d
Compare
Hubert Figuière (hfiguiere) started tests. Results |
This pull request has been closed due to tree stability issues. Please rebase and re-open the pull request if you still need to land this. Ensure the gaia-try run is green before landing. Sorry for any inconvenience. |
Hubert Figuière (hfiguiere) started tests. Results |
34ab35d
to
c9b4392
Compare
Hubert Figuière (hfiguiere) started tests. Results |
c9b4392
to
b7fcf89
Compare
Hubert Figuière (hfiguiere) started tests. Results |
b7fcf89
to
95cd0b0
Compare
Hubert Figuière (hfiguiere) started tests. Results |
95cd0b0
to
4a65d29
Compare
Hubert Figuière (hfiguiere) started tests. Results |
|
||
maxDiscNum = Math.max( | ||
dataArray[dataArray.length - 1].metadata.disccount, | ||
dataArray[dataArray.length - 1].metadata.discnum |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that it's possible (but unlikely) that this won't get you the maximum disccount
value, since you're sorting by discnum
and not disccount
.
4a65d29
to
8b18597
Compare
Hubert Figuière (hfiguiere) started tests. Results |
Gij failiure is https://bugzilla.mozilla.org/show_bug.cgi?id=1084453 |
Track sorting and listing improvements. (Bug 796305 and bug 841977) r=squib
Includes dependencies that have to land before this. ie will be rebased when time comes.