Skip to content

Commit

Permalink
Qt: put preferences and about in native spots on MacOS (#676)
Browse files Browse the repository at this point in the history
  • Loading branch information
twvd authored Dec 9, 2024
1 parent cbf1e41 commit 6be642a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/panda_qt/main_window.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ MainWindow::MainWindow(QApplication* app, QWidget* parent) : QMainWindow(parent)
auto resumeAction = emulationMenu->addAction(tr("Resume"));
auto resetAction = emulationMenu->addAction(tr("Reset"));
auto configureAction = emulationMenu->addAction(tr("Configure"));
configureAction->setMenuRole(QAction::PreferencesRole);

connect(pauseAction, &QAction::triggered, this, [this]() { sendMessage(EmulatorMessage{.type = MessageType::Pause}); });
connect(resumeAction, &QAction::triggered, this, [this]() { sendMessage(EmulatorMessage{.type = MessageType::Resume}); });
connect(resetAction, &QAction::triggered, this, [this]() { sendMessage(EmulatorMessage{.type = MessageType::Reset}); });
Expand All @@ -75,7 +77,9 @@ MainWindow::MainWindow(QApplication* app, QWidget* parent) : QMainWindow(parent)
connect(dumpDspFirmware, &QAction::triggered, this, &MainWindow::dumpDspFirmware);

auto aboutAction = aboutMenu->addAction(tr("About Panda3DS"));
aboutAction->setMenuRole(QAction::AboutRole);
connect(aboutAction, &QAction::triggered, this, &MainWindow::showAboutMenu);

setMenuBar(menuBar);

emu->setOutputSize(screen->surfaceWidth, screen->surfaceHeight);
Expand Down

0 comments on commit 6be642a

Please sign in to comment.