1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-04-24 15:02:27 +00:00

45 lines
1.1 KiB
Lua

local ui = require('openmw.ui')
local util = require('openmw.util')
local whiteTexture = ui.texture{ path = 'white' }
local menuTransparency = ui._getMenuTransparency()
return function(templates)
templates.backgroundTransparent = {
props = {
resource = whiteTexture,
color = util.color.rgb(0, 0, 0),
alpha = menuTransparency,
},
}
templates.backgroundSolid = {
props = {
resource = whiteTexture,
color = util.color.rgb(0, 0, 0),
},
}
templates.box = {
props = {
inheritAlpha = false,
},
content = ui.content {
{
type = ui.TYPE.Image,
template = templates.backgroundTransparent,
props = {
relativeSize = util.vector2(1, 1),
},
},
{
template = templates.borders,
props = {
relativeSize = util.vector2(1, 1),
},
external = {
slot = true,
},
},
},
}
end