mirror of
https://github.com/OTCv8/otclientv8.git
synced 2025-10-19 06:03:27 +02:00
Version 0.999 BETA - a lot of bug fixes, improvments and more advanced bot
This commit is contained in:
@@ -317,6 +317,12 @@ function UIMoveableTabBar:onStyleApply(styleName, styleNode)
|
||||
end
|
||||
end
|
||||
|
||||
function UIMoveableTabBar:clearTabs()
|
||||
while #self.tabs > 0 do
|
||||
self:removeTab(self.tabs[#self.tabs])
|
||||
end
|
||||
end
|
||||
|
||||
function UIMoveableTabBar:removeTab(tab)
|
||||
local tabTables = {self.tabs, self.preTabs, self.postTabs}
|
||||
local index = nil
|
||||
|
@@ -80,8 +80,10 @@ end
|
||||
function UISpinBox:onStyleApply(styleName, styleNode)
|
||||
for name, value in pairs(styleNode) do
|
||||
if name == 'maximum' then
|
||||
self.maximum = value
|
||||
addEvent(function() self:setMaximum(value) end)
|
||||
elseif name == 'minimum' then
|
||||
self.minimum = value
|
||||
addEvent(function() self:setMinimum(value) end)
|
||||
elseif name == 'mouse-scroll' then
|
||||
addEvent(function() self:setMouseScroll(value) end)
|
||||
@@ -118,6 +120,9 @@ function UISpinBox:down()
|
||||
end
|
||||
|
||||
function UISpinBox:setValue(value, dontSignal)
|
||||
if type(value) == "string" then
|
||||
value = tonumber(value)
|
||||
end
|
||||
value = value or 0
|
||||
value = math.max(math.min(self.maximum, value), self.minimum)
|
||||
|
||||
|
Reference in New Issue
Block a user