Update Progressbar
This commit is contained in:
@@ -25,6 +25,10 @@ return function(name, basalt)
|
|||||||
return self
|
return self
|
||||||
end,
|
end,
|
||||||
|
|
||||||
|
getDirection = function(self)
|
||||||
|
return direction
|
||||||
|
end,
|
||||||
|
|
||||||
setProgressBar = function(self, color, symbol, symbolcolor)
|
setProgressBar = function(self, color, symbol, symbolcolor)
|
||||||
activeBarColor = color or activeBarColor
|
activeBarColor = color or activeBarColor
|
||||||
activeBarSymbol = symbol or activeBarSymbol
|
activeBarSymbol = symbol or activeBarSymbol
|
||||||
@@ -37,12 +41,40 @@ return function(name, basalt)
|
|||||||
return activeBarColor, activeBarSymbol, activeBarSymbolCol
|
return activeBarColor, activeBarSymbol, activeBarSymbolCol
|
||||||
end,
|
end,
|
||||||
|
|
||||||
|
setActiveBarColor = function(self, color)
|
||||||
|
return self:setProgressBar(color, nil, nil)
|
||||||
|
end,
|
||||||
|
|
||||||
|
getActiveBarColor = function(self)
|
||||||
|
return activeBarColor
|
||||||
|
end,
|
||||||
|
|
||||||
|
setActiveBarSymbol = function(self, symbol)
|
||||||
|
return self:setProgressBar(nil, symbol, nil)
|
||||||
|
end,
|
||||||
|
|
||||||
|
getActiveBarSymbol = function(self)
|
||||||
|
return activeBarSymbol
|
||||||
|
end,
|
||||||
|
|
||||||
|
setActiveBarSymbolColor = function(self, symbolColor)
|
||||||
|
return self:setProgressBar(nil, nil, symbolColor)
|
||||||
|
end,
|
||||||
|
|
||||||
|
getActiveBarSymbolColor = function(self)
|
||||||
|
return activeBarSymbolCol
|
||||||
|
end,
|
||||||
|
|
||||||
setBackgroundSymbol = function(self, symbol)
|
setBackgroundSymbol = function(self, symbol)
|
||||||
bgBarSymbol = symbol:sub(1, 1)
|
bgBarSymbol = symbol:sub(1, 1)
|
||||||
self:updateDraw()
|
self:updateDraw()
|
||||||
return self
|
return self
|
||||||
end,
|
end,
|
||||||
|
|
||||||
|
getBackgroundSymbol = function(self)
|
||||||
|
return bgBarSymbol
|
||||||
|
end,
|
||||||
|
|
||||||
setProgress = function(self, value)
|
setProgress = function(self, value)
|
||||||
if (value >= 0) and (value <= 100) and (progress ~= value) then
|
if (value >= 0) and (value <= 100) and (progress ~= value) then
|
||||||
progress = value
|
progress = value
|
||||||
|
|||||||
Reference in New Issue
Block a user