mirror of
https://github.com/HamletDuFromage/aio-switch-updater.git
synced 2024-11-09 12:01:44 +00:00
block home button during worker operations https://github.com/HamletDuFromage/aio-switch-updater/issues/125#issuecomment-925296295
This commit is contained in:
parent
ad2dc0bab1
commit
8033b8f199
1 changed files with 3 additions and 2 deletions
|
@ -38,12 +38,13 @@ void WorkerPage::draw(NVGcontext* vg, int x, int y, unsigned width, unsigned hei
|
|||
if (this->draw_page) {
|
||||
if (!this->workStarted) {
|
||||
appletSetMediaPlaybackState(true);
|
||||
this->workStarted = true;
|
||||
appletBeginBlockingHomeButton(0);
|
||||
ProgressEvent::instance().reset();
|
||||
this->workStarted = true;
|
||||
workerThread = new std::thread(&WorkerPage::doWork, this);
|
||||
}
|
||||
else if (ProgressEvent::instance().finished()) {
|
||||
brls::Logger::debug("Worker done");
|
||||
appletEndBlockingHomeButton();
|
||||
appletSetMediaPlaybackState(false);
|
||||
if (ProgressEvent::instance().getStatusCode() > 399) {
|
||||
this->draw_page = false;
|
||||
|
|
Loading…
Reference in a new issue