Fixes to scrollbar
This commit is contained in:
parent
23097980a3
commit
c9688551f3
|
@ -244,7 +244,7 @@ function CharacterList.hide()
|
||||||
end
|
end
|
||||||
|
|
||||||
function CharacterList.showAgain()
|
function CharacterList.showAgain()
|
||||||
if characterList:hasChildren() then
|
if characterList and characterList:hasChildren() then
|
||||||
CharacterList.show()
|
CharacterList.show()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -168,7 +168,7 @@ function UIScrollBar:setValue(value)
|
||||||
self.value = value
|
self.value = value
|
||||||
updateSlider(self)
|
updateSlider(self)
|
||||||
if self.setupDone then
|
if self.setupDone then
|
||||||
signalcall(self.onValueChange, self, value, delta)
|
signalcall(self.onValueChange, self, math.round(value), delta)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -203,6 +203,6 @@ end
|
||||||
|
|
||||||
function UIScrollBar:getMaximum() return self.maximum end
|
function UIScrollBar:getMaximum() return self.maximum end
|
||||||
function UIScrollBar:getMinimum() return self.minimum end
|
function UIScrollBar:getMinimum() return self.minimum end
|
||||||
function UIScrollBar:getValue() return self.value end
|
function UIScrollBar:getValue() return math.round(self.value) end
|
||||||
function UIScrollBar:getStep() return self.step end
|
function UIScrollBar:getStep() return self.step end
|
||||||
function UIScrollBar:getOrientation() return self.orientation end
|
function UIScrollBar:getOrientation() return self.orientation end
|
||||||
|
|
|
@ -487,7 +487,7 @@ function moveStackableItem(item, toPos)
|
||||||
|
|
||||||
scrollbar.onValueChange = function(self, value)
|
scrollbar.onValueChange = function(self, value)
|
||||||
spinbox.onValueChange = nil
|
spinbox.onValueChange = nil
|
||||||
spinbox:setValue(math.round(value))
|
spinbox:setValue(value)
|
||||||
spinbox.onValueChange = spinBoxValueChange
|
spinbox.onValueChange = spinBoxValueChange
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue