SaveTool: improve the settings menu layout.
This commit is contained in:
parent
52f5e8eb0a
commit
d52b381426
1 changed files with 2 additions and 1 deletions
|
@ -66,7 +66,7 @@ void SaveTool::drawMainMenu() {
|
|||
"FPS cap, no V-sync"
|
||||
};
|
||||
|
||||
ImGui::SetNextItemWidth(150.0f);
|
||||
ImGui::SetNextItemWidth(ImGui::GetContentRegionAvailWidth());
|
||||
if(ImGui::BeginCombo("##FrameLimit", framelimit_labels[selection])) {
|
||||
if(ImGui::Selectable(framelimit_labels[0], _framelimit == Framelimit::Vsync)) {
|
||||
selection = 0;
|
||||
|
@ -92,6 +92,7 @@ void SaveTool::drawMainMenu() {
|
|||
static constexpr UnsignedInt min_fps = 15;
|
||||
static constexpr UnsignedInt max_fps = 150;
|
||||
|
||||
ImGui::SetNextItemWidth(ImGui::GetContentRegionAvailWidth());
|
||||
if(ImGui::SliderScalar("##FpsSlider", ImGuiDataType_U32, &_fpsCap, &min_fps, &max_fps, "%u FPS", ImGuiSliderFlags_AlwaysClamp)) {
|
||||
setMinimalLoopPeriod(1000 / _fpsCap);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue