adventuregamestudio / ags-manual

AGS documentation.
https://adventuregamestudio.github.io/ags-manual/
MIT License
28 stars 9 forks source link

Document ListBox updated APIs #266

Open ericoporto opened 1 day ago

ericoporto commented 1 day ago

https://github.com/adventuregamestudio/ags-manual/wiki/ListBox

From changelog in the forums

  • Added FileSortStyle and SortDirection enum, and optional "fileSortStyle" and "sortDirection" parameters to ListBox.FillDirList(). This lets to sort resulting list by name or time, in ascending or descending order.
  • ListBox.FillSaveGameList(), RestoreGameDialog() and SaveGameDialog() now let define a range of save slots for display.
    /// Fills the list box with all the filenames that match the specified file mask.
    import void FillDirList(const string fileMask, FileSortStyle fileSortStyle = eFileSort_Name, SortDirection sortDirection = eSortAscending);
    /// Fills the list box with the current user's saved games in the given range of slots.
    import int  FillSaveGameList(int min_slot = 1, int max_slot = 100);

Added in PR https://github.com/adventuregamestudio/ags/pull/2541