1
Fork 0
mirror of https://github.com/redstrate/Astra.git synced 2025-04-20 19:57:45 +00:00

Make auto-login cancel button actually functional

This commit is contained in:
Joshua Goins 2022-08-31 21:31:03 -04:00
parent 5ee036dd09
commit 33f68c5586
2 changed files with 8 additions and 4 deletions

View file

@ -53,11 +53,12 @@ DesktopInterface::DesktopInterface(LauncherCore& core) {
if(defaultProfile.autoLogin) {
autoLoginWindow = new AutoLoginWindow(defaultProfile, core);
QObject::connect(autoLoginWindow, &AutoLoginWindow::loginCanceled, [this] {
autoLoginWindow->show();
QObject::connect(autoLoginWindow, &AutoLoginWindow::loginCanceled,[=] {
autoLoginWindow->hide();
window->show();
});
autoLoginWindow->show();
} else {
window->show();
}

View file

@ -62,13 +62,16 @@ int main(int argc, char* argv[]) {
}
LauncherCore c;
std::unique_ptr<DesktopInterface> desktopInterface;
std::unique_ptr<TabletInterface> tabletInterface;
if (parser.isSet(tabletOption)) {
std::make_unique<TabletInterface>(c);
tabletInterface = std::make_unique<TabletInterface>(c);
} else if (parser.isSet(cliOption)) {
if (!cmd->parse(parser, c))
return -1;
} else {
std::make_unique<DesktopInterface>(c);
desktopInterface = std::make_unique<DesktopInterface>(c);
}
return app.exec();