Made SliderComponent scale properly on high resolution displays.

This commit is contained in:
Leon Styhre 2021-01-15 19:06:53 +01:00
parent 3abbb3c85c
commit db1a97dd85

View file

@ -86,7 +86,7 @@ void SliderComponent::render(const Transform4x4f& parentTrans)
(mValueCache ? mValueCache->metrics.size.x() + 4 : 0);
// Render line.
const float lineWidth = 2;
const float lineWidth = 2 * Renderer::getScreenHeightModifier();;
Renderer::drawRect(mKnob.getSize().x() / 2, mSize.y() / 2 -
lineWidth / 2, width, lineWidth, 0x777777FF, 0x777777FF);