mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-09-03 08:06:22 +00:00
More nits
Co-Authored-By: Paris Oplopoios <parisoplop@gmail.com>
This commit is contained in:
parent
6b3e91f9e7
commit
2aa8f96e9c
1 changed files with 3 additions and 3 deletions
|
@ -779,12 +779,12 @@ void MainWindow::setupControllerSensors(SDL_GameController* controller) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::loadKeybindings() {
|
void MainWindow::loadKeybindings() {
|
||||||
auto keyMappings = InputMappings::deserialize(emu->getAppDataRoot() / "controls_qt.toml", "Qt", [](const std::string& name) {
|
auto mappings = InputMappings::deserialize(emu->getAppDataRoot() / "controls_qt.toml", "Qt", [](const std::string& name) {
|
||||||
return InputMappings::Scancode(QKeySequence(QString::fromStdString(name))[0].key());
|
return InputMappings::Scancode(QKeySequence(QString::fromStdString(name))[0].key());
|
||||||
});
|
});
|
||||||
|
|
||||||
if (keyMappings) {
|
if (mappings.has_value()) {
|
||||||
keyboardMappings = *keyMappings;
|
keyboardMappings = *mappings;
|
||||||
} else {
|
} else {
|
||||||
keyboardMappings = InputMappings::defaultKeyboardMappings();
|
keyboardMappings = InputMappings::defaultKeyboardMappings();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue