Background label hide function, Skins fix and combobox hide, messagebox changes, show entergame when reload

This commit is contained in:
Henrique Santiago
2012-08-06 16:15:20 -03:00
parent 9cb4cb9a58
commit e6bd3907e1
8 changed files with 34 additions and 27 deletions

View File

@@ -89,24 +89,22 @@ function Skins.setSkin(name)
g_fonts.clearFonts()
g_ui.clearStyles()
if name ~= defaultSkinName then
local defaultSkin = installedSkins[defaultSkinName]
if not defaultSkin then
error("Default skin is not installed.")
return false
end
Skins.loadSkin(defaultSkin)
end
if currentSkin and currentSkin.name ~= defaultSkinName then
g_resources.removeSearchPath(getSkinPath(currentSkin.name))
end
if skin.name ~= defaultSkinName then
g_resources.addSearchPath(getSkinPath(skin.name), true)
Skins.loadSkin(skin)
end
Skins.loadSkin(skin)
local defaultSkin = installedSkins[defaultSkinName]
if not defaultSkin then
error("Default skin is not installed.")
return false
end
Skins.loadSkin(defaultSkin)
currentSkin = skin
return true
end
@@ -136,3 +134,12 @@ function Skins.loadSkin(skin)
end
end
end
function Skins.hideComboBox()
if not skinComboBox then
addEvent(Skins.hideComboBox)
else
skinComboBox:hide()
skinComboBox:setWidth(0)
end
end