Clean up the OSD click callback code

This commit is contained in:
Henrik Rydgård
2026-02-09 13:08:44 +01:00
parent 4ccd41110b
commit a92ff89d5f
9 changed files with 43 additions and 95 deletions
+4 -3
View File
@@ -1574,9 +1574,10 @@ void EmuScreen::HandleFlip() {
auto sy = GetI18NCategory(I18NCat::SYSTEM);
avi.Stop();
g_OSD.Show(OSDType::MESSAGE_INFO, sy->T("AVI Dump stopped."), 3.0f, "avi_dump");
g_OSD.SetClickCallback("avi_dump", [](bool, void *) {
System_ShowFileInFolder(avi.LastFilename());
}, nullptr);
Path lastFilename = avi.LastFilename();
g_OSD.SetClickCallback("avi_dump", [lastFilename]() {
System_ShowFileInFolder(lastFilename);
});
startDumping_ = false;
}
#endif