DevMenu: Hide the option to record a framedump if one is being played back

This commit is contained in:
Henrik Rydgård 2025-02-25 14:12:10 -06:00
parent 2b9d8b2c18
commit 6dbfa85bce

View file

@ -154,17 +154,19 @@ void DevMenuScreen::CreatePopupContents(UI::ViewGroup *parent) {
return UI::EVENT_DONE;
});
items->Add(new Choice(dev->T("Create frame dump")))->OnClick.Add([](UI::EventParams &e) {
gpuDebug->GetRecorder()->RecordNextFrame([](const Path &dumpPath) {
NOTICE_LOG(Log::System, "Frame dump created at '%s'", dumpPath.c_str());
if (System_GetPropertyBool(SYSPROP_CAN_SHOW_FILE)) {
System_ShowFileInFolder(dumpPath);
} else {
g_OSD.Show(OSDType::MESSAGE_SUCCESS, dumpPath.ToVisualString(), 7.0f);
}
if (PSP_CoreParameter().fileType != IdentifiedFileType::PPSSPP_GE_DUMP) {
items->Add(new Choice(dev->T("Create frame dump")))->OnClick.Add([](UI::EventParams &e) {
gpuDebug->GetRecorder()->RecordNextFrame([](const Path &dumpPath) {
NOTICE_LOG(Log::System, "Frame dump created at '%s'", dumpPath.c_str());
if (System_GetPropertyBool(SYSPROP_CAN_SHOW_FILE)) {
System_ShowFileInFolder(dumpPath);
} else {
g_OSD.Show(OSDType::MESSAGE_SUCCESS, dumpPath.ToVisualString(), 7.0f);
}
});
return UI::EVENT_DONE;
});
return UI::EVENT_DONE;
});
}
// This one is not very useful these days, and only really on desktop. Hide it on other platforms.
if (System_GetPropertyInt(SYSPROP_DEVICE_TYPE) == DEVICE_TYPE_DESKTOP) {