metaforce/Runtime/MP1/CQuitGameScreen.hpp

43 lines
1.0 KiB
C++
Raw Normal View History

2018-10-06 20:42:33 -07:00
#pragma once
2016-12-29 22:37:01 -08:00
#include <optional>
#include "Runtime/CToken.hpp"
#include "Runtime/RetroTypes.hpp"
2021-06-06 18:40:16 -07:00
#include "Runtime/GuiSys/CGuiFrame.hpp"
2016-12-29 22:37:01 -08:00
2021-04-10 01:42:06 -07:00
namespace metaforce {
2018-02-03 22:46:47 -08:00
struct CFinalInput;
2016-12-29 22:37:01 -08:00
class CGuiTableGroup;
class CGuiTextPane;
2019-01-22 23:52:19 -08:00
class CGuiWidget;
2016-12-29 22:37:01 -08:00
2018-12-07 21:30:43 -08:00
namespace MP1 {
2016-12-29 22:37:01 -08:00
2018-12-07 21:30:43 -08:00
enum class EQuitType { QuitGame, ContinueFromLastSave, SaveProgress, QuitNESMetroid, ContinuePlaying };
2016-12-29 22:37:01 -08:00
2018-12-07 21:30:43 -08:00
enum class EQuitAction { None, Yes, No };
class CQuitGameScreen {
EQuitType x0_type;
TLockedToken<CGuiFrame> x4_frame;
CGuiFrame* x10_loadedFrame = nullptr;
CGuiTableGroup* x14_tablegroup_quitgame = nullptr;
EQuitAction x18_action = EQuitAction::None;
2018-12-07 21:30:43 -08:00
void SetColors();
2016-12-29 22:37:01 -08:00
public:
2018-12-07 21:30:43 -08:00
void FinishedLoading();
2019-01-22 23:52:19 -08:00
void OnWidgetMouseUp(CGuiWidget* widget, bool cancel);
2018-12-07 21:30:43 -08:00
void DoSelectionChange(CGuiTableGroup* caller, int oldSel);
void DoAdvance(CGuiTableGroup* caller);
EQuitAction Update(float dt);
void Draw();
void ProcessUserInput(const CFinalInput& input);
explicit CQuitGameScreen(EQuitType type);
2016-12-29 22:37:01 -08:00
};
2018-12-07 21:30:43 -08:00
} // namespace MP1
2021-04-10 01:42:06 -07:00
} // namespace metaforce