mirror of
https://github.com/wiidev/usbloadergx.git
synced 2024-11-19 17:59:16 +01:00
*Added Quicksort to the MP3 List.
This commit is contained in:
parent
9ee6729e7f
commit
f493f3c2f5
@ -103,6 +103,12 @@ return 0;
|
|||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
s32 filenamescmp(const void *a, const void *b)
|
||||||
|
{
|
||||||
|
/* Compare strings */
|
||||||
|
return stricmp((char *)a, (char *)b);
|
||||||
|
}
|
||||||
|
|
||||||
int GetFiles(char * mp3path)
|
int GetFiles(char * mp3path)
|
||||||
{
|
{
|
||||||
int countmp3 = 0;
|
int countmp3 = 0;
|
||||||
@ -127,5 +133,8 @@ if (dir == NULL) //If empty
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
qsort(mp3files, countmp3, sizeof(char[30]), filenamescmp);
|
||||||
|
|
||||||
return countmp3;
|
return countmp3;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user