treball en curs: correccions de tidy

This commit is contained in:
2026-05-16 17:19:40 +02:00
parent 3421f34a84
commit ee2dd0bc2c
30 changed files with 1220 additions and 1479 deletions
+6 -9
View File
@@ -9,7 +9,7 @@
#include "core/audio/audio.hpp" // for Audio
#include "core/input/global_inputs.hpp" // for GlobalInputs::handle
#include "core/input/input.h" // for Input, INPUT_USE_GAMECONTROLLER, INPUT_...
#include "core/locale/lang.h" // for Lang, ba_BA, en_UK, es_ES
#include "core/locale/lang.h" // for Lang, Lang::Code
#include "core/rendering/animatedsprite.h" // for AnimatedSprite
#include "core/rendering/fade.h" // for Fade
#include "core/rendering/screen.h" // for Screen
@@ -450,10 +450,7 @@ void Title::handleOptionsMenuSelection() {
break;
case 5: // Language
Options::settings.language++;
if (Options::settings.language == 3) {
Options::settings.language = 0;
}
Options::settings.language = Lang::nextLanguage(Options::settings.language);
updateMenuLabels();
break;
@@ -729,15 +726,15 @@ void Title::updateMenuLabels() const {
i++;
// LANGUAGE
switch (Options::settings.language) {
case es_ES:
case Lang::Code::ES_ES:
menu_.options->setItemCaption(i, Lang::get()->getText(8) + ": " + Lang::get()->getText(24)); // SPANISH
break;
case ba_BA:
case Lang::Code::BA_BA:
menu_.options->setItemCaption(i, Lang::get()->getText(8) + ": " + Lang::get()->getText(25)); // VALENCIAN
break;
case en_UK:
case Lang::Code::EN_UK:
default:
// ENGLISH (i fallback per a llengües no reconegudes)
menu_.options->setItemCaption(i, Lang::get()->getText(8) + ": " + Lang::get()->getText(26));
@@ -1010,7 +1007,7 @@ void Title::createTiledBackground() {
// Crea la textura para el mosaico de fondo
background_ = SDL_CreateTexture(renderer_, SDL_PIXELFORMAT_RGBA8888, SDL_TEXTUREACCESS_TARGET, GAMECANVAS_WIDTH * 2, GAMECANVAS_HEIGHT * 2);
if (background_ != nullptr) {
SDL_SetTextureScaleMode(background_, Texture::currentScaleMode);
SDL_SetTextureScaleMode(background_, Texture::current_scale_mode);
}
if (background_ == nullptr) {
if (Options::settings.console) {