diff options
author | Nebuleon Fumika | 2013-06-15 23:40:29 -0400 |
---|---|---|
committer | Nebuleon Fumika | 2013-06-15 23:40:29 -0400 |
commit | a1d1e01e11185d389f9448be0be0a567f1430600 (patch) | |
tree | 324e45c5680fbd14ed7cafe91910d6fc137d6425 /source/nds/message.h | |
parent | 4252250fe77d6bd874ed626314a819340c29b4db (diff) | |
download | snes9x2005-a1d1e01e11185d389f9448be0be0a567f1430600.tar.gz snes9x2005-a1d1e01e11185d389f9448be0be0a567f1430600.tar.bz2 snes9x2005-a1d1e01e11185d389f9448be0be0a567f1430600.zip |
Dynamically allocate memory for the file selector to store the name pointers into. Also dramatically simplify the file selector's name management code. This has many effects:
* It allows the file selector to handle directories of more than 511 files and a parent directory entry. (Fixes GitHub issue #37).
* It allows the file selector to sort directories along with files, which is a more common use case (game folders that contain ROM hacks, plus single game files, are sorted by name as the user expects).
* The file selector now reports progress while loading a large directory.
* The screenshot slideshow function now shows an existing dedicated message, "No screenshots found", instead of crashing when the screenshot directory contains no screenshots.
Add Quicksort code from GameYob. See <https://github.com/Nebuleon/GameYob/commit/afbeeba>.
* Faster sorting in the common case where a directory's natural order is already sorted, using the isSorted function.
* Use the median-of-three algorithm first described by Robert Sedgewick to select the pivot. Causes less recursion in many cases.
* Associates file names with their is-directory flag, keeping both in sync.
Diffstat (limited to 'source/nds/message.h')
-rw-r--r-- | source/nds/message.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/nds/message.h b/source/nds/message.h index 98f64ab..f2977e4 100644 --- a/source/nds/message.h +++ b/source/nds/message.h @@ -31,6 +31,10 @@ enum MSG MSG_MAIN_MENU_TOOLS, MSG_MAIN_MENU_OPTIONS, MSG_MAIN_MENU_EXIT, + + MSG_FILE_MENU_LOADING_LIST, + MSG_FILE_MENU_SORTING_LIST, + FMT_VIDEO_AUDIO_FLUIDITY_PREFERENCE, MSG_VIDEO_AUDIO_FLUIDITY_PREFER_VIDEO, MSG_VIDEO_AUDIO_FLUIDITY_PREFER_AUDIO, |