mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2025-07-03 08:17:54 -05:00
Improvements for MRU
avoid duplicates always put the last file loaded to top of the list
This commit is contained in:
@ -60,6 +60,24 @@ private:
|
||||
void BootGame(const std::string& filename);
|
||||
void ShutdownGame();
|
||||
|
||||
/**
|
||||
* Stores the filename in the recently loaded files list.
|
||||
* The new filename is stored at the beginning of the recently loaded files list.
|
||||
* After inserting the new entry, duplicates are removed meaning that if
|
||||
* this was inserted from \a OnMenuRecentFile(), the entry will be put on top
|
||||
* and remove from its previous position.
|
||||
*
|
||||
* Finally, this function calls \a UpdateRecentFiles() to update the UI.
|
||||
*
|
||||
* @param filename the filename to store
|
||||
*/
|
||||
void StoreRecentFile(const QString& filename);
|
||||
|
||||
/**
|
||||
* Updates the recent files menu.
|
||||
* Menu entries are rebuilt from the configuration file.
|
||||
* If there is no entry in the menu, the menu is greyed out.
|
||||
*/
|
||||
void UpdateRecentFiles();
|
||||
|
||||
void closeEvent(QCloseEvent* event) override;
|
||||
|
Reference in New Issue
Block a user