Fix scrollbar slider move, outfit exact size, charlist focus

This commit is contained in:
Henrique Santiago
2012-08-31 20:33:51 -03:00
parent 18a0d7ab94
commit 23097980a3
12 changed files with 201 additions and 113 deletions

View File

@@ -458,7 +458,7 @@ function processMouseAction(menuPosition, mouseButton, autoWalkPos, lookThing, u
end
function moveStackableItem(item, toPos)
if(countWindow) then
if countWindow then
return
end
if g_keyboard.isCtrlPressed() then
@@ -479,8 +479,17 @@ function moveStackableItem(item, toPos)
scrollbar:setMaximum(count)
scrollbar:setMinimum(1)
scrollbar:setValue(count)
scrollbar.onValueChange = function(self, value) spinbox:setValue(value) end
spinbox.onValueChange = function(self, value) scrollbar:setValue(value) end
local spinBoxValueChange = function(self, value)
scrollbar:setValue(value)
end
spinbox.onValueChange = spinBoxValueChange
scrollbar.onValueChange = function(self, value)
spinbox.onValueChange = nil
spinbox:setValue(math.round(value))
spinbox.onValueChange = spinBoxValueChange
end
local okButton = countWindow:getChildById('buttonOk')
local moveFunc = function()