/* * CHighScoreScreen.h, part of VCMI engine * * Authors: listed in file AUTHORS in main folder * * License: GNU General Public License v2.0 or later * Full text of license available in license.txt file, in main folder * */ #pragma once #include "../windows/CWindowObject.h" class CButton; class CLabel; class CMultiLineLabel; class CAnimImage; class CTextInput; class CHighScoreScreen : public CWindowObject { enum HighScorePage { SCENARIO, CAMPAIGN }; void addButtons(); void addHighScores(); void buttonCampaginClick(); void buttonStandardClick(); void buttonResetClick(); void buttonExitClick(); HighScorePage highscorepage = HighScorePage::SCENARIO; std::shared_ptr background; std::vector> buttons; std::vector> texts; std::vector> images; public: CHighScoreScreen(); }; class CHighScoreInput : public CWindowObject { std::shared_ptr background; std::shared_ptr text; std::shared_ptr buttonOk; std::shared_ptr buttonCancel; std::shared_ptr statusBar; std::shared_ptr textInput; std::function ready; void okay(); void abort(); public: CHighScoreInput(std::function readyCB); }; class CHighScoreInputScreen : public CWindowObject { std::vector> texts; std::shared_ptr input; std::string video; bool won; public: CHighScoreInputScreen(bool won); void addEntry(std::string text); void show(Canvas & to) override; void activate() override; void deactivate() override; void clickPressed(const Point & cursorPosition) override; };