mirror of
https://github.com/Mr-X-GTA/YimMenu.git
synced 2025-06-18 07:07:32 +08:00
fix gui scale slider (#3466)
This commit is contained in:
parent
5c20591ecb
commit
64700270bf
@ -6,8 +6,13 @@ namespace big
|
||||
void view::gui_settings()
|
||||
{
|
||||
components::sub_title("SETTINGS_UI_SCALE"_T);
|
||||
if (ImGui::SliderFloat("##gui-scale", &g.window.gui_scale, 0.75f, 1.5f, "%.2f"))
|
||||
static auto gui_scale = g.window.gui_scale;
|
||||
ImGui::SliderFloat("##gui-scale", &gui_scale, 0.75f, 1.5f, "%.2f");
|
||||
if (ImGui::IsItemDeactivatedAfterEdit())
|
||||
{
|
||||
g.window.gui_scale = gui_scale;
|
||||
g_renderer.rescale(g.window.gui_scale);
|
||||
}
|
||||
|
||||
components::sub_title("SETTINGS_UI_COLOR"_T);
|
||||
static ImVec4 col_gui = ImGui::ColorConvertU32ToFloat4(g.window.background_color);
|
||||
|
Loading…
x
Reference in New Issue
Block a user