mirror of
https://github.com/Team-Neptune/NSAInstaller.git
synced 2024-11-23 12:49:52 +00:00
Warn about applet mode
This commit is contained in:
parent
787e6f4ed9
commit
b5e4b0f75b
@ -17,6 +17,7 @@ namespace inst::ui {
|
||||
void onInput(u64 Down, u64 Up, u64 Held, pu::ui::Touch Pos);
|
||||
Image::Ref awooImage;
|
||||
private:
|
||||
bool dialogAck;
|
||||
TextBlock::Ref butText;
|
||||
Rectangle::Ref topRect;
|
||||
Rectangle::Ref botRect;
|
||||
|
@ -1,4 +1,5 @@
|
||||
#include <filesystem>
|
||||
#include <switch.h>
|
||||
#include "ui/MainApplication.hpp"
|
||||
#include "ui/mainPage.hpp"
|
||||
#include "util/util.hpp"
|
||||
@ -9,6 +10,14 @@
|
||||
|
||||
namespace inst::ui {
|
||||
extern MainApplication *mainApp;
|
||||
bool dialogAck = false;
|
||||
|
||||
void warnAboutAppletMode() {
|
||||
if (!dialogAck && mainApp->IsShown() && appletGetAppletType() == AppletType_LibraryApplet) {
|
||||
inst::ui::dialogAck = true;
|
||||
mainApp->CreateShowDialog("Applet Mode not supported", "You may experience issues using Awoo Installer in Applet Mode. If you do\nhave problems, please switch to running Awoo Installer over an installed\ntitle or forwarder!", {"OK"}, true);
|
||||
}
|
||||
}
|
||||
|
||||
MainPage::MainPage() : Layout::Layout() {
|
||||
this->SetBackgroundColor(COLOR("#670000FF"));
|
||||
@ -61,6 +70,7 @@ namespace inst::ui {
|
||||
this->Add(this->eggImage);
|
||||
this->awooImage->SetVisible(!inst::config::gayMode);
|
||||
this->eggImage->SetVisible(false);
|
||||
this->AddThread(warnAboutAppletMode);
|
||||
}
|
||||
|
||||
void MainPage::installMenuItem_Click() {
|
||||
|
Loading…
Reference in New Issue
Block a user