Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

When sorting by episode number, perform 2nd level sorting on label ra…

…ther than filename.

At tv show level, the episode number is the amount of total or unwatched episodes, and filename is empty. Therefore, shows with equal episode numbers didn't always sort in the same order.
  • Loading branch information...
commit f6d5bb5ae222cf7df3b4b7b7dc8139365f2aeaa7 1 parent ce49e91
@Voyager1 Voyager1 authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  xbmc/utils/SortUtils.cpp
View
2  xbmc/utils/SortUtils.cpp
@@ -285,7 +285,7 @@ string ByEpisodeNumber(SortAttribute attributes, const SortItem &values)
num = ((uint64_t)values.at(FieldSeason).asInteger() << 32) + (values.at(FieldEpisodeNumber).asInteger() << 16);
CStdString label;
- label.Format("%"PRIu64" %s", num, values.at(FieldFilename).asString().c_str());
+ label.Format("%"PRIu64" %s", num, ByLabel(attributes, values).c_str());
return label;
}
Please sign in to comment.
Something went wrong with that request. Please try again.