2025-02-09 21:40:31 +01:00
|
|
|
#include <pd/overlays/settings.hpp>
|
|
|
|
|
|
|
|
namespace PD {
|
|
|
|
int SettingsMenu::too = 0;
|
|
|
|
void SettingsMenu::Update(float delta, LI::Renderer::Ref ren, Hid::Ref inp) {
|
|
|
|
if (!ctx) {
|
|
|
|
ctx = UI7::Context::New(ren, inp);
|
|
|
|
ctx->RootLayer(70);
|
|
|
|
}
|
|
|
|
flymgr.Update(delta);
|
|
|
|
if (rem && flymgr.IsFinished()) {
|
|
|
|
this->Kill();
|
|
|
|
}
|
|
|
|
ren->OnScreen(ren->GetScreen(false));
|
|
|
|
if (ctx->BeginMenu("Palladium - Settings", UI7MenuFlags_CenterTitle)) {
|
|
|
|
auto m = ctx->GetCurrentMenu();
|
2025-03-04 10:22:28 +01:00
|
|
|
m->PushAlignment(UI7Align_Center);
|
2025-02-09 21:40:31 +01:00
|
|
|
m->SeparatorText("Library Info");
|
|
|
|
m->Label(LibInfo::CompiledWith());
|
2025-03-04 10:22:28 +01:00
|
|
|
m->Join();
|
2025-02-09 21:40:31 +01:00
|
|
|
m->Label(LibInfo::CxxVersion());
|
2025-03-04 10:22:28 +01:00
|
|
|
m->Join();
|
2025-02-09 21:40:31 +01:00
|
|
|
m->Label("Version: " + LibInfo::Version() + "[" + LibInfo::Commit() + "]");
|
2025-03-04 10:22:28 +01:00
|
|
|
m->Join();
|
2025-02-09 21:40:31 +01:00
|
|
|
m->Label("Build Time: " + LibInfo::BuildTime());
|
2025-03-04 10:22:28 +01:00
|
|
|
m->JoinAlign(UI7Align_Mid);
|
2025-02-09 21:40:31 +01:00
|
|
|
ctx->EndMenu();
|
|
|
|
}
|
|
|
|
ren->OnScreen(ren->GetScreen(true));
|
|
|
|
if (ctx->BeginMenu("pdovlssettings", UI7MenuFlags_NoTitlebar)) {
|
|
|
|
auto m = ctx->GetCurrentMenu();
|
|
|
|
m->SeparatorText("Settings");
|
|
|
|
if (m->Button("Exit")) {
|
|
|
|
this->Rem();
|
|
|
|
}
|
|
|
|
ctx->EndMenu();
|
|
|
|
}
|
|
|
|
ctx->Update(delta);
|
|
|
|
}
|
|
|
|
} // namespace PD
|