Fix ScrollBar plasma component incrementValue function
- The function was not bounding the value after incremented inside the flickable content size. Signed-off-by: Daker Fernandes Pinheiro <dakerfp@gmail.com>
This commit is contained in:
parent
db7cd67033
commit
d318641dcf
@ -54,10 +54,13 @@ Item {
|
||||
if (!flickableItem)
|
||||
return;
|
||||
|
||||
if (_isVertical)
|
||||
flickableItem.contentY += increment;
|
||||
else
|
||||
flickableItem.contentX += increment;
|
||||
if (_isVertical) {
|
||||
flickableItem.contentY = Math.min(flickableItem.contentHeight,
|
||||
flickableItem.contentY + increment);
|
||||
} else {
|
||||
flickableItem.contentX = Math.min(flickableItem.contentWidth,
|
||||
flickableItem.contentX + increment);
|
||||
}
|
||||
}
|
||||
|
||||
Keys.onUpPressed: {
|
||||
|
Loading…
Reference in New Issue
Block a user