Game systems are now sorted by their full names.

This commit is contained in:
Leon Styhre 2020-09-27 12:49:14 +02:00
parent 926d730bd2
commit 54ea153d93
6 changed files with 35 additions and 8 deletions

View file

@ -19,6 +19,7 @@ Many bugs have been fixed, and numerous features that were only partially implem
* Initial version, fork from RetroPie EmulationStation 2.10.0rp-dev (master) * Initial version, fork from RetroPie EmulationStation 2.10.0rp-dev (master)
* Reorganization and general overhaul of the menu system, hopefully making it more intuitive and easy to understand * Reorganization and general overhaul of the menu system, hopefully making it more intuitive and easy to understand
* Many quality of life improvements and removal of GUI inconsistencies * Many quality of life improvements and removal of GUI inconsistencies
* Game systems are now sorted by full names which makes much more sense from a user perspective
* New game media file logic using a media directory with files matching the ROM names instead of pointing to the media files in gamelist.xml * New game media file logic using a media directory with files matching the ROM names instead of pointing to the media files in gamelist.xml
* Updated scraper to support additional media files, detailed configuration of what to scrape, semi-automatic mode etc. * Updated scraper to support additional media files, detailed configuration of what to scrape, semi-automatic mode etc.
* In the metadata editor, any values updated by the single-game scraper or by the user are now highlighted using a different font color * In the metadata editor, any values updated by the single-game scraper or by the user are now highlighted using a different font color

View file

@ -827,7 +827,9 @@ This is only shown if the system is a collection. This will also be described in
## Metadata editor ## Metadata editor
In the metadata editor, you can modify the metadata for a game, scrape for game info and media files and delete media files or the entire game. In the metadata editor, you can modify the metadata for a game, scrape for game info and media files and delete media files and gamelist entries, or the entire game.
### Metadata entries
The following entries can be modified: The following entries can be modified:
@ -907,6 +909,30 @@ Here you can override the launch command for the game, for example to use a diff
A statistics counter that counts how many times you're played the game. You normally don't need to touch this, but if you want to, the possibility is there. A statistics counter that counts how many times you're played the game. You normally don't need to touch this, but if you want to, the possibility is there.
### Buttons
For game files, there will be four buttons displayed on the bottom of the metadata editor window, and for folders there will be three buttons. These are their functions:
**Scrape**
Opens the single-game scraper, which is explained earlier in this guide.
**Save**
Saves any changes and closes the window. If no changes have been done, it simply closes the window.
**Cancel**
Cancels any changes and closes the window. If no changes have been done, it simply closes the window.
**Clear**
This will remove any media files for the game file and also remove its entry from gamelist.xml. The actual game file will however _not_ be deleted. A prompt will be shown asking for confirmation.
**Delete** _(Files only)_
This will remove the actual game file and its gamelist.xml entry, as well as any media files. A prompt will be shown asking for confirmation. Note that deletion of folders is not supported as that would potentially be a bit dangerous, instead use the valid operating system tools to handle deletion of folders.
## Screensaver ## Screensaver

View file

@ -354,6 +354,12 @@ bool SystemData::loadConfig()
sSystemVector.push_back(newSys); sSystemVector.push_back(newSys);
} }
} }
// Sort systems by their full names.
std::sort(std::begin(sSystemVector), std::end(sSystemVector),
[](SystemData* a, SystemData* b) {
return a->getFullName() < b->getFullName(); });
// Don't load any collections if there are no systems available. // Don't load any collections if there are no systems available.
if (sSystemVector.size() > 0) if (sSystemVector.size() > 0)
CollectionSystemManager::get()->loadCollectionSystems(); CollectionSystemManager::get()->loadCollectionSystems();

View file

@ -68,8 +68,6 @@ GuiScraperMenu::GuiScraperMenu(Window* window) : GuiComponent(window),
mSystems->selectEntry(i) : mSystems->unselectEntry(i); mSystems->selectEntry(i) : mSystems->unselectEntry(i);
} }
} }
// Sort the systems by their full names.
mSystems->sortEntriesByName();
mMenu.addWithLabel("Systems", mSystems); mMenu.addWithLabel("Systems", mSystems);
addEntry("CONTENT SETTINGS", 0x777777FF, true, [this] { addEntry("CONTENT SETTINGS", 0x777777FF, true, [this] {

View file

@ -149,10 +149,6 @@ void SystemView::populate()
"OK", nullptr)); "OK", nullptr));
} }
} }
// Sort the systems by their full names.
std::sort(std::begin(mEntries), std::end(mEntries),
[](Entry a, Entry b) { return a.object->getFullName() < b.object->getFullName(); });
} }
void SystemView::goToSystem(SystemData* system, bool animate) void SystemView::goToSystem(SystemData* system, bool animate)

View file

@ -101,7 +101,7 @@ void ViewController::goToStart()
// Requested system doesn't exist. // Requested system doesn't exist.
Settings::getInstance()->setString("StartupSystem", ""); Settings::getInstance()->setString("StartupSystem", "");
} }
// Get the first system entry as sorted by full system names in SystemView. // Get the first system entry.
goToSystemView(getSystemListView()->getFirst()); goToSystemView(getSystemListView()->getFirst());
} }