mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-07-31 13:40:12 +02:00
Fix sliders accepting clicks from anywhere
Broken by 69e0a8b0aa
where I added an extra MouseDownInside check to the OnMouseDown (used to be OnMouseClick) of every component except that of sliders.
This commit is contained in:
@@ -50,8 +50,11 @@ void Slider::OnMouseMoved(int x, int y)
|
||||
|
||||
void Slider::OnMouseDown(int x, int y, unsigned button)
|
||||
{
|
||||
isMouseDown = true;
|
||||
updatePosition(x - Position.X);
|
||||
if (MouseDownInside)
|
||||
{
|
||||
isMouseDown = true;
|
||||
updatePosition(x - Position.X);
|
||||
}
|
||||
}
|
||||
|
||||
void Slider::OnMouseUp(int x, int y, unsigned button)
|
||||
|
Reference in New Issue
Block a user