UI::EventReturn GamePauseScreen::OnScreenshotClicked(UI::EventParams &e) { SaveSlotView *v = (SaveSlotView *)e.v; std::string fn = v->GetScreenshotFilename(); std::string title = v->GetScreenshotTitle(); Screen *screen = new ScreenshotViewScreen(fn, title, v->GetSlot()); screenManager()->push(screen); return UI::EVENT_DONE; }
UI::EventReturn GamePauseScreen::OnScreenshotClicked(UI::EventParams &e) { SaveSlotView *v = static_cast<SaveSlotView *>(e.v); int slot = v->GetSlot(); g_Config.iCurrentStateSlot = v->GetSlot(); if (SaveState::HasSaveInSlot(gamePath_, slot)) { std::string fn = v->GetScreenshotFilename(); std::string title = v->GetScreenshotTitle(); I18NCategory *pa = GetI18NCategory("Pause"); Screen *screen = new ScreenshotViewScreen(fn, title, v->GetSlot(), pa); screenManager()->push(screen); } return UI::EVENT_DONE; }