mirror of
https://github.com/edubart/otclient.git
synced 2025-10-15 12:04:55 +02:00
Market fix, and a few other things:
* Added 'button' param to g_mouse.bindPress * Added 'lower' param to table.contains * UIComboBox:onOptionChange should signalcall? * Changed the experience bar color * Market buy/sell 'amount' window will now show the cost of the amount you are selecting
This commit is contained in:
@@ -31,7 +31,7 @@ function UIComboBox:setCurrentOption(text)
|
||||
if v.text == text and self.currentIndex ~= i then
|
||||
self.currentIndex = i
|
||||
self:setText(text)
|
||||
self:onOptionChange(text, v.data)
|
||||
signalcall(self.onOptionChange, self, text, v.data)
|
||||
return
|
||||
end
|
||||
end
|
||||
@@ -43,7 +43,7 @@ function UIComboBox:setCurrentOptionByData(data)
|
||||
if v.data == data and self.currentIndex ~= i then
|
||||
self.currentIndex = i
|
||||
self:setText(v.text)
|
||||
self:onOptionChange(v.text, v.data)
|
||||
signalcall(self.onOptionChange, self, v.text, v.data)
|
||||
return
|
||||
end
|
||||
end
|
||||
@@ -54,7 +54,7 @@ function UIComboBox:setCurrentIndex(index)
|
||||
local v = self.options[index]
|
||||
self.currentIndex = index
|
||||
self:setText(v.text)
|
||||
self:onOptionChange(v.text, v.data)
|
||||
signalcall(self.onOptionChange, self, v.text, v.data)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -140,7 +140,3 @@ end
|
||||
function UIComboBox:canMouseScroll()
|
||||
return self.mouseScroll
|
||||
end
|
||||
|
||||
function UIComboBox:onOptionChange(optionText, optionData)
|
||||
-- nothing todo
|
||||
end
|
||||
|
Reference in New Issue
Block a user