Variables renombrades en input.cpp

This commit is contained in:
2024-10-12 11:01:42 +02:00
parent 4ef759772a
commit 101e375fd3
16 changed files with 467 additions and 523 deletions

View File

@@ -293,7 +293,7 @@ void Screen::checkInput()
{
#ifndef ARCADE
// Comprueba el teclado para cambiar entre pantalla completa y ventana
if (Input::get()->checkInput(input_window_fullscreen, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
if (Input::get()->checkInput(InputType::WINDOW_FULLSCREEN, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
{
switchVideoMode();
const std::string mode = options.video.mode == ScreenVideoMode::WINDOW ? "Window" : "Fullscreen";
@@ -302,7 +302,7 @@ void Screen::checkInput()
}
// Comprueba el teclado para decrementar el tamaño de la ventana
if (Input::get()->checkInput(input_window_dec_size, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
if (Input::get()->checkInput(InputType::WINDOW_DEC_SIZE, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
{
decWindowSize();
const std::string size = std::to_string(options.video.window.size);
@@ -311,7 +311,7 @@ void Screen::checkInput()
}
// Comprueba el teclado para incrementar el tamaño de la ventana
if (Input::get()->checkInput(input_window_inc_size, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
if (Input::get()->checkInput(InputType::WINDOW_INC_SIZE, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
{
incWindowSize();
const std::string size = std::to_string(options.video.window.size);
@@ -321,7 +321,7 @@ void Screen::checkInput()
#endif
// Comprueba el teclado para activar o desactivar los shaders
if (Input::get()->checkInput(input_video_shaders, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
if (Input::get()->checkInput(InputType::VIDEO_SHADERS, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
{
switchShaders();
return;
@@ -329,7 +329,7 @@ void Screen::checkInput()
#ifdef DEBUG
// Comprueba el teclado para mostrar la información de debug
if (Input::get()->checkInput(input_showinfo, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
if (Input::get()->checkInput(InputType::SHOWINFO, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_KEYBOARD))
{
show_info_ = !show_info_;
return;
@@ -339,14 +339,14 @@ void Screen::checkInput()
for (int i = 0; i < Input::get()->getNumControllers(); ++i)
{
// Comprueba los mandos para activar o desactivar los shaders
if (Input::get()->checkModInput(input_service, input_video_shaders, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_GAMECONTROLLER, i))
if (Input::get()->checkModInput(InputType::SERVICE, InputType::VIDEO_SHADERS, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_GAMECONTROLLER, i))
{
switchShaders();
return;
}
// Comprueba los mandos para mostrar la información de debug
if (Input::get()->checkModInput(input_service, input_showinfo, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_GAMECONTROLLER, i))
if (Input::get()->checkModInput(InputType::SERVICE, InputType::SHOWINFO, INPUT_DO_NOT_ALLOW_REPEAT, INPUT_USE_GAMECONTROLLER, i))
{
show_info_ = !show_info_;
return;
@@ -489,7 +489,7 @@ void Screen::displayInfo()
// Resolution
dbg_print(0, 0, info_resolution_.c_str(), 255, 255, 0);
dbg_print(0, 8, std::to_string(globalInputs::servicePressedCounter[0]).c_str(), 255, 255, 0);
dbg_print(0, 8, std::to_string(globalInputs::service_pressed_counter[0]).c_str(), 255, 255, 0);
}
}