mirror of
https://github.com/citra-emu/citra.git
synced 2024-11-30 06:00:05 +00:00
Update main.cpp
This commit is contained in:
parent
d56f908e5c
commit
f92d516723
@ -252,6 +252,14 @@ void GMainWindow::InitializeHotkeys() {
|
|||||||
SLOT(OnStartGame()));
|
SLOT(OnStartGame()));
|
||||||
connect(GetHotkey("Main Window", "Swap Screens", render_window), SIGNAL(activated()), this,
|
connect(GetHotkey("Main Window", "Swap Screens", render_window), SIGNAL(activated()), this,
|
||||||
SLOT(OnSwapScreens()));
|
SLOT(OnSwapScreens()));
|
||||||
|
connect(GetHotkey("Main Window", "Play/Pause", this), SIGNAL(activated()), this,
|
||||||
|
SLOT(OnRunningToggle()));
|
||||||
|
}
|
||||||
|
|
||||||
|
void GMainWindow::OnRunningToggle() {
|
||||||
|
if (emulation_running) {
|
||||||
|
OnPauseGame();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void GMainWindow::SetDefaultUIGeometry() {
|
void GMainWindow::SetDefaultUIGeometry() {
|
||||||
@ -824,12 +832,6 @@ void GMainWindow::dragMoveEvent(QDragMoveEvent* event) {
|
|||||||
event->acceptProposedAction();
|
event->acceptProposedAction();
|
||||||
}
|
}
|
||||||
|
|
||||||
void GMainWindow::keyPressEvent(QKeyEvent* event) {
|
|
||||||
if (event->key() == Qt::Key_F4 && emulation_running) {
|
|
||||||
OnPauseGame();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
bool GMainWindow::ConfirmChangeGame() {
|
bool GMainWindow::ConfirmChangeGame() {
|
||||||
if (emu_thread == nullptr)
|
if (emu_thread == nullptr)
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user