mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-25 15:45:38 +00:00
Made the SliderComponent width consistent across different screen aspect ratios.
This commit is contained in:
parent
593cfdbdd7
commit
71b5c50b85
|
@ -8,6 +8,7 @@
|
|||
|
||||
#include "components/SliderComponent.h"
|
||||
|
||||
#include "Window.h"
|
||||
#include "resources/Font.h"
|
||||
|
||||
#define MOVE_REPEAT_DELAY 500
|
||||
|
@ -32,7 +33,7 @@ SliderComponent::SliderComponent(
|
|||
mKnob.setOrigin(0.5f, 0.5f);
|
||||
mKnob.setImage(":/graphics/slider_knob.svg");
|
||||
|
||||
setSize(Renderer::getScreenWidth() * 0.15f, Font::get(FONT_SIZE_MEDIUM)->getLetterHeight());
|
||||
setSize(window->peekGui()->getSize().x * 0.26f, Font::get(FONT_SIZE_MEDIUM)->getLetterHeight());
|
||||
}
|
||||
|
||||
bool SliderComponent::input(InputConfig* config, Input input)
|
||||
|
|
Loading…
Reference in a new issue