daybreak: switch to using hiddbg for home blocking (+1 squashed commits)

Squashed commits:

[4bfc7b0d] daybreak: block the home button during installation
This commit is contained in:
Adubbz 2020-07-07 17:39:44 +10:00
parent 4464b31b40
commit 0f39bc4b26
2 changed files with 10 additions and 1 deletions

View File

@ -41,12 +41,18 @@ extern "C" {
if (R_FAILED(rc = plInitialize(PlServiceType_User))) { if (R_FAILED(rc = plInitialize(PlServiceType_User))) {
fatalThrow(rc); fatalThrow(rc);
} }
if (R_FAILED(rc = hiddbgInitialize())) {
fatalThrow(rc);
}
} }
void userAppExit(void) { void userAppExit(void) {
romfsExit(); hiddbgExit();
plExit(); plExit();
spsmExit(); spsmExit();
romfsExit();
amssuExit(); amssuExit();
} }

View File

@ -783,6 +783,9 @@ namespace dbk {
this->AddButton(RebootButtonId, "Reboot", x + HorizontalGap + ButtonWidth + ButtonHorizontalGap, y + WindowHeight - BottomGap - ButtonHeight, ButtonWidth, ButtonHeight); this->AddButton(RebootButtonId, "Reboot", x + HorizontalGap + ButtonWidth + ButtonHorizontalGap, y + WindowHeight - BottomGap - ButtonHeight, ButtonWidth, ButtonHeight);
this->SetButtonEnabled(ShutdownButtonId, false); this->SetButtonEnabled(ShutdownButtonId, false);
this->SetButtonEnabled(RebootButtonId, false); this->SetButtonEnabled(RebootButtonId, false);
/* Prevent the home button from being pressed during installation. */
hiddbgDeactivateHomeButton();
} }
void InstallUpdateMenu::MarkForReboot() { void InstallUpdateMenu::MarkForReboot() {