service/apt: Implement soft reset & CloseApplication

This commit is contained in:
zhupengfei 2018-07-18 20:07:00 +08:00
parent ca701e2610
commit ad6b140cb0
No known key found for this signature in database
GPG key ID: 85B82A3E62174206
9 changed files with 160 additions and 12 deletions

View file

@ -1400,7 +1400,6 @@ void GMainWindow::UpdateStatusBar() {
}
void GMainWindow::OnCoreError(Core::System::ResultStatus result, std::string details) {
QMessageBox::StandardButton answer;
QString status_message;
QString title, message;
@ -1435,9 +1434,11 @@ void GMainWindow::OnCoreError(Core::System::ResultStatus result, std::string det
message_box.setIcon(QMessageBox::Icon::Critical);
QPushButton* continue_button = message_box.addButton(tr("Continue"), QMessageBox::RejectRole);
QPushButton* abort_button = message_box.addButton(tr("Abort"), QMessageBox::AcceptRole);
message_box.exec();
if (result != Core::System::ResultStatus::ShutdownRequested)
message_box.exec();
if (message_box.clickedButton() == abort_button) {
if (result == Core::System::ResultStatus::ShutdownRequested ||
message_box.clickedButton() == abort_button) {
if (emu_thread) {
ShutdownGame();
}