mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-16 00:34:19 +00:00
Slider LinearBarVertical fixes.
This commit is contained in:
parent
2329e63f20
commit
60fe89c1aa
2 changed files with 17 additions and 2 deletions
|
|
@ -1466,7 +1466,13 @@ void LookAndFeel::drawLinearSlider (Graphics& g,
|
|||
isMouseOver || slider.isMouseButtonDown()));
|
||||
|
||||
drawShinyButtonShape (g,
|
||||
(float) x, (float) y, sliderPos - (float) x, (float) height, 0.0f,
|
||||
(float) x,
|
||||
style == Slider::LinearBarVertical ? sliderPos
|
||||
: (float) y,
|
||||
style == Slider::LinearBarVertical ? (float) width
|
||||
: (sliderPos - x),
|
||||
style == Slider::LinearBarVertical ? (height - sliderPos)
|
||||
: (float) height, 0.0f,
|
||||
baseColour,
|
||||
slider.isEnabled() ? 0.9f : 0.3f,
|
||||
true, true, true, true);
|
||||
|
|
|
|||
|
|
@ -1146,7 +1146,7 @@ public:
|
|||
|
||||
const int indent = lf.getSliderThumbRadius (owner);
|
||||
|
||||
if (style == LinearBar || style == LinearBarVertical)
|
||||
if (style == LinearBar)
|
||||
{
|
||||
const int barIndent = 1;
|
||||
sliderRegionStart = barIndent;
|
||||
|
|
@ -1155,6 +1155,15 @@ public:
|
|||
sliderRect.setBounds (sliderRegionStart, barIndent,
|
||||
sliderRegionSize, localBounds.getHeight() - barIndent * 2);
|
||||
}
|
||||
else if (style == LinearBarVertical)
|
||||
{
|
||||
const int barIndent = 1;
|
||||
sliderRegionStart = barIndent;
|
||||
sliderRegionSize = localBounds.getHeight() - barIndent * 2;
|
||||
|
||||
sliderRect.setBounds (barIndent, sliderRegionStart,
|
||||
localBounds.getWidth() - barIndent * 2, sliderRegionSize);
|
||||
}
|
||||
else if (isHorizontal())
|
||||
{
|
||||
sliderRegionStart = sliderRect.getX() + indent;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue