mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2026-08-29 18:08:08 +00:00
[android] input over(lay)haul 2: Individual scaling of buttons (#2562)
### (Needs testing) This PR makes it possible to adjust the scale of each touch input overlay button independently from the global scale This individual value always goes on top of the global scale. Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/2562 Co-authored-by: nyx <contact@innix.space> Co-committed-by: nyx <contact@innix.space>
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project
|
||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||
// SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project
|
||||
// SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
#include <common/logging/log.h>
|
||||
#include <input_common/main.h>
|
||||
@@ -103,6 +103,7 @@ void AndroidConfig::ReadOverlayValues() {
|
||||
ReadDoubleSetting(std::string("foldable\\x_position"));
|
||||
control_data.foldable_position.second =
|
||||
ReadDoubleSetting(std::string("foldable\\y_position"));
|
||||
control_data.individual_scale = static_cast<float>(ReadDoubleSetting(std::string("individual_scale")));
|
||||
AndroidSettings::values.overlay_control_data.push_back(control_data);
|
||||
}
|
||||
EndArray();
|
||||
@@ -255,6 +256,7 @@ void AndroidConfig::SaveOverlayValues() {
|
||||
control_data.foldable_position.first);
|
||||
WriteDoubleSetting(std::string("foldable\\y_position"),
|
||||
control_data.foldable_position.second);
|
||||
WriteDoubleSetting(std::string("individual_scale"), static_cast<double>(control_data.individual_scale));
|
||||
}
|
||||
EndArray();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user