Module:Protection banner: Difference between revisions
m
fix a few mistakes
(don't use Module:Middleclass) |
m (fix a few mistakes) |
||
Line 153: | Line 153: | ||
end | end | ||
configTables[#configTables + 1] = cfg.masterBanner | configTables[#configTables + 1] = cfg.masterBanner | ||
for i, field in ipairs( | for i, field in ipairs(Protection.bannerConfigFields) do | ||
for j, t in ipairs(configTables) do | for j, t in ipairs(configTables) do | ||
if t[field] then | if t[field] then | ||
Line 754: | Line 754: | ||
function Banner.new(protectionObj, blurbObj, cfg) | function Banner.new(protectionObj, blurbObj, cfg) | ||
local obj = | local obj = BannerTemplate.new(protectionObj, cfg) -- This doesn't need the blurb. | ||
obj:setImageWidth(40) | obj:setImageWidth(40) | ||
obj:setImageTooltip(blurbObj:makeBannerText('alt')) -- Large banners use the alt text for the tooltip. | obj:setImageTooltip(blurbObj:makeBannerText('alt')) -- Large banners use the alt text for the tooltip. |