treball en curs: correccions de tidy

This commit is contained in:
2026-05-16 15:49:21 +02:00
parent 18cd287808
commit 3421f34a84
18 changed files with 658 additions and 651 deletions
+5 -5
View File
@@ -161,9 +161,9 @@ namespace Options {
size_t i = 0;
for (const auto &entry : ins) {
if (i >= inputs.size()) { break; }
int device_type_int = inputs[i].deviceType;
int device_type_int = inputs[i].device_type;
if (tryGet<int>(entry, "device_type", device_type_int)) {
inputs[i].deviceType = static_cast<Uint8>(device_type_int);
inputs[i].device_type = static_cast<Uint8>(device_type_int);
}
++i;
}
@@ -200,13 +200,13 @@ namespace Options {
InputDevice kb;
kb.id = 0;
kb.name = "KEYBOARD";
kb.deviceType = INPUT_USE_KEYBOARD;
kb.device_type = INPUT_USE_KEYBOARD;
inputs.push_back(kb);
InputDevice gc;
gc.id = 0;
gc.name = "GAME CONTROLLER";
gc.deviceType = INPUT_USE_GAMECONTROLLER;
gc.device_type = INPUT_USE_GAMECONTROLLER;
inputs.push_back(gc);
}
@@ -328,7 +328,7 @@ namespace Options {
file << "input:\n";
for (size_t i = 0; i < inputs.size(); ++i) {
file << " - slot: " << i << "\n";
file << " device_type: " << static_cast<int>(inputs[i].deviceType) << "\n";
file << " device_type: " << static_cast<int>(inputs[i].device_type) << "\n";
}
file.close();