Rework hotkeys manager, fix many issues on it

This commit is contained in:
Eduardo Bart
2013-01-30 18:23:26 -02:00
parent 377c013dfe
commit 5bf03c50d6
15 changed files with 379 additions and 350 deletions

View File

@@ -8,6 +8,7 @@ g_settings.getNode = g_configs.getNode
g_settings.remove = g_configs.remove
g_settings.setList = g_configs.setList
g_settings.getList = g_configs.getList
g_settings.save = g_configs.save
local function convertSettingValue(value)
if type(value) == 'table' then

View File

@@ -18,6 +18,11 @@ function UIPopupMenu:display(pos)
return
end
if g_ui.isMouseGrabbed() then
self:destroy()
return
end
if currentMenu then
currentMenu:destroy()
end

View File

@@ -14,11 +14,17 @@ function UIScrollArea:onStyleApply(styleName, styleNode)
for name,value in pairs(styleNode) do
if name == 'vertical-scrollbar' then
addEvent(function()
self:setVerticalScrollBar(self:getParent():getChildById(value))
local parent = self:getParent()
if parent then
self:setVerticalScrollBar(parent:getChildById(value))
end
end)
elseif name == 'horizontal-scrollbar' then
addEvent(function()
self:setHorizontalScrollBar(self:getParent():getChildById(value))
local parent = self:getParent()
if parent then
self:setHorizontalScrollBar(self:getParent():getChildById(value))
end
end)
elseif name == 'inverted-scroll' then
self:setInverted(value)