mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-12 09:09:29 +01:00
Merge pull request #8495 from unknownbrackets/ui-tweaks
Delete savestates better in the UI
This commit is contained in:
commit
b575596585
2 files changed
+15
-2
No files matched your search
+12
-2
@@ -82,18 +82,28 @@ bool GameInfo::Delete() {
|
||||
return true;
|
||||
}
|
||||
case FILETYPE_PSP_ELF:
|
||||
case FILETYPE_PPSSPP_SAVESTATE:
|
||||
case FILETYPE_UNKNOWN_BIN:
|
||||
case FILETYPE_UNKNOWN_ELF:
|
||||
case FILETYPE_ARCHIVE_RAR:
|
||||
case FILETYPE_ARCHIVE_ZIP:
|
||||
case FILETYPE_ARCHIVE_7Z:
|
||||
{
|
||||
const char *fileToRemove = filePath_.c_str();
|
||||
const std::string &fileToRemove = filePath_;
|
||||
File::Delete(fileToRemove);
|
||||
return true;
|
||||
}
|
||||
|
||||
case FILETYPE_PPSSPP_SAVESTATE:
|
||||
{
|
||||
const std::string &ppstPath = filePath_;
|
||||
File::Delete(ppstPath);
|
||||
const std::string screenshotPath = ReplaceAll(filePath_, ".ppst", ".jpg");
|
||||
if (File::Exists(screenshotPath)) {
|
||||
File::Delete(screenshotPath);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -359,6 +359,9 @@ void GamePauseScreen::dialogFinished(const Screen *dialog, DialogResult dr) {
|
||||
SaveState::LoadSlot(gamePath_, slot, SaveState::Callback(), 0);
|
||||
|
||||
finishNextFrame_ = true;
|
||||
} else {
|
||||
// There may have been changes to our savestates, so let's recreate.
|
||||
RecreateViews();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user