X-Git-Url: https://git.distorted.org.uk/~mdw/disorder/blobdiff_plain/132a5a4a47f9dbc7c52ee15234d70258c59ccf8e..b0116b5c04b64e9352d1c63f0f667a1d9a5d5c11:/lib/tracksort.c?ds=sidebyside diff --git a/lib/tracksort.c b/lib/tracksort.c index 2f81739..b1fcc3a 100644 --- a/lib/tracksort.c +++ b/lib/tracksort.c @@ -32,6 +32,16 @@ static int tracksort_compare(const void *a, const void *b) { ea->track, eb->track); } +/** @brief Sort tracks + * @param ntracks Number of tracks to sort + * @param tracks List of tracks + * @param type Comparison type + * @return Sorted track data + * + * Tracks are compared using compare_tracks(), with the sort key and display + * string set according to @p type, which should be "track" if the tracks are + * really tracks and "dir" if they are directories. + */ struct tracksort_data *tracksort_init(int ntracks, char **tracks, const char *type) {