Commit becdb7f2 authored by Simpy's avatar Simpy 🐹

12.02

parents f5be340b 93e5c5c0
## Interface: 90001
## Author: Elv, Simpy
## Version: 12.01
## Version: 12.02
## Title: |cff1784d1ElvUI|r
## Notes: User Interface replacement AddOn for World of Warcraft.
## SavedVariables: ElvDB, ElvPrivateDB
......
......@@ -196,7 +196,6 @@ function AB:SetupMicroBar()
microBar.visibility:SetScript('OnShow', function() microBar:Show() end)
microBar.visibility:SetScript('OnHide', function() microBar:Hide() end)
E.FrameLocks.ElvUI_MicroBar = true
for _, x in pairs(_G.MICRO_BUTTONS) do
self:HandleMicroButton(_G[x])
end
......
......@@ -134,6 +134,7 @@ end
function DB:AzeriteBar()
local Azerite = DB:CreateBar('ElvUI_AzeriteBar', 'Azerite', DB.AzeriteBar_Update, DB.AzeriteBar_OnEnter, DB.AzeriteBar_OnClick, {'TOPRIGHT', E.UIParent, 'TOPRIGHT', -3, -245})
DB:CreateBarBubbles(Azerite)
E:CreateMover(Azerite.holder, 'AzeriteBarMover', L["Azerite Bar"], nil, nil, nil, nil, nil, 'databars,azerite')
......
......@@ -52,6 +52,38 @@ function DB:CreateBar(name, key, updateFunc, onEnter, onClick, points)
return bar
end
function DB:CreateBarBubbles(bar)
if bar.bubbles then return end
bar.bubbles = {}
for i = 1, 19 do
bar.bubbles[i] = bar:CreateTexture(nil, 'OVERLAY')
bar.bubbles[i]:SetColorTexture(0, 0, 0)
end
end
function DB:UpdateBarBubbles(bar)
if not bar.bubbles then return end
local width, height = bar.db.width, bar.db.height
local vertical = bar:GetOrientation() ~= 'HORIZONTAL'
local bubbleWidth, bubbleHeight = vertical and (width - 2) or 1, vertical and 1 or (height - 2)
local offset = (vertical and height or width) / 20
for i, bubble in ipairs(bar.bubbles) do
bubble:ClearAllPoints()
bubble:SetSize(bubbleWidth, bubbleHeight)
bubble:SetShown(bar.db.showBubbles)
if vertical then
bubble:Point('TOP', bar, 'BOTTOM', 0, offset * i)
else
bubble:Point('RIGHT', bar, 'LEFT', offset * i, 0)
end
end
end
function DB:UpdateAll()
local texture = DB.db.customTexture and LSM:Fetch('statusbar', DB.db.statusbar) or E.media.normTex
......@@ -95,6 +127,8 @@ function DB:UpdateAll()
child:SetReverseFill(reverseFill)
end
end
DB:UpdateBarBubbles(bar)
end
DB:PvPCheck()
......
......@@ -211,6 +211,7 @@ end
function DB:ExperienceBar()
local Experience = DB:CreateBar('ElvUI_ExperienceBar', 'Experience', DB.ExperienceBar_Update, DB.ExperienceBar_OnEnter, DB.ExperienceBar_OnClick, {'BOTTOM', E.UIParent, 'BOTTOM', 0, 43})
Experience.barTexture:SetDrawLayer('ARTWORK', 4)
DB:CreateBarBubbles(Experience)
local Rested = CreateFrame('StatusBar', 'ElvUI_ExperienceBar_Rested', Experience.holder)
Rested:SetStatusBarTexture(DB.db.customTexture and LSM:Fetch('statusbar', DB.db.statusbar) or E.media.normTex)
......
......@@ -103,6 +103,7 @@ end
function DB:HonorBar()
local Honor = DB:CreateBar('ElvUI_HonorBar', 'Honor', DB.HonorBar_Update, DB.HonorBar_OnEnter, DB.HonorBar_OnClick, {'TOPRIGHT', E.UIParent, 'TOPRIGHT', -3, -255})
DB:CreateBarBubbles(Honor)
E:CreateMover(Honor.holder, 'HonorBarMover', L["Honor Bar"], nil, nil, nil, nil, nil, 'databars,honor')
......
......@@ -150,6 +150,7 @@ end
function DB:ReputationBar()
local Reputation = DB:CreateBar('ElvUI_ReputationBar', 'Reputation', DB.ReputationBar_Update, DB.ReputationBar_OnEnter, DB.ReputationBar_OnClick, {'TOPRIGHT', E.UIParent, 'TOPRIGHT', -3, -264})
DB:CreateBarBubbles(Reputation)
E:CreateMover(Reputation.holder, 'ReputationBarMover', L["Reputation Bar"], nil, nil, nil, nil, nil, 'databars,reputation')
......
......@@ -2,8 +2,8 @@ local E, L, V, P, G = unpack(select(2, ...)); --Import: Engine, Locales, Private
local DT = E:GetModule('DataTexts')
local _G = _G
local format = format
local pairs = pairs
local format = format
local GetDungeonDifficultyID, GetRaidDifficultyID, GetLegacyRaidDifficultyID = GetDungeonDifficultyID, GetRaidDifficultyID, GetLegacyRaidDifficultyID
local SetDungeonDifficultyID, SetRaidDifficultyID, SetLegacyRaidDifficultyID = SetDungeonDifficultyID, SetRaidDifficultyID, SetLegacyRaidDifficultyID
local GetInstanceInfo, GetDifficultyInfo, ResetInstances = GetInstanceInfo, GetDifficultyInfo, ResetInstances
......@@ -120,12 +120,22 @@ local function OnEvent(self)
end
local function OnEnter()
if not (DungeonDifficultyID or RaidDifficultyID or LegacyRaidDifficultyID) then return end
DT.tooltip:ClearLines()
DT.tooltip:SetText(L["Current Difficulties:"])
DT.tooltip:AddLine(' ')
if DungeonDifficultyID then
DT.tooltip:AddLine(format('%s %s', DungeonTexture, DiffLabel[DungeonDifficultyID]), 1, 1, 1)
end
if RaidDifficultyID then
DT.tooltip:AddLine(format('%s %s', RaidTexture, DiffLabel[RaidDifficultyID]), 1, 1, 1)
end
if LegacyRaidDifficultyID then
DT.tooltip:AddLine(format('%s %s', LegacyTexture, DiffLabel[LegacyRaidDifficultyID]), 1, 1, 1)
end
DT.tooltip:Show()
end
......
......@@ -57,8 +57,6 @@ V.chat = {
V.skins = {
ace3Enable = true,
checkBoxSkin = true,
cleanBossButton = false,
cleanZoneButton = false,
parchmentRemoverEnable = false,
blizzard = {
enable = true,
......
......@@ -161,6 +161,7 @@ for _, databar in pairs({'experience', 'reputation', 'honor', 'threat', 'azerite
clickThrough = false,
orientation = 'AUTOMATIC',
reverseFill = false,
showBubbles = false,
}
end
......@@ -2139,7 +2140,7 @@ P.actionbar = {
buttonSize = 20,
buttonSpacing = 2,
alpha = 1,
visibility = 'show',
visibility = '[petbattle] hide; show',
},
globalFadeAlpha = 0,
......
......@@ -10,9 +10,10 @@ local SharedOptions = {
textFormat = ACH:Select(L["Text Format"], nil, 2, { NONE = L["NONE"], CUR = L["Current"], REM = L["Remaining"], PERCENT = L["Percent"], CURMAX = L["Current - Max"], CURPERC = L["Current - Percent"], CURREM = L["Current - Remaining"], CURPERCREM = L["Current - Percent (Remaining)"] }),
mouseover = ACH:Toggle(L["Mouseover"], nil, 3),
clickThrough = ACH:Toggle(L["Click Through"], nil, 4),
sizeGroup = ACH:Group(L["Size"], nil, 5),
conditionGroup = ACH:MultiSelect(L["Conditions"], nil, 6),
fontGroup = ACH:Group(L["Fonts"], nil, 7),
showBubbles = ACH:Toggle(L["Show Bubbles"], nil, 5),
sizeGroup = ACH:Group(L["Size"], nil, -3),
conditionGroup = ACH:MultiSelect(L["Conditions"], nil, -2),
fontGroup = ACH:Group(L["Fonts"], nil, -1),
}
SharedOptions.sizeGroup.inline = true
......@@ -95,6 +96,7 @@ E.Options.args.databars.args.threat.args = CopyTable(SharedOptions)
E.Options.args.databars.args.threat.args.enable.set = function(info, value) DB.db.threat[info[#info]] = value DB:ThreatBar_Toggle() DB:UpdateAll() end
E.Options.args.databars.args.threat.args.textFormat = nil
E.Options.args.databars.args.threat.args.conditionGroup = nil
E.Options.args.databars.args.threat.args.showBubbles = nil
E.Options.args.databars.args.azerite = ACH:Group(L["Azerite"], nil, 5, nil, function(info) return DB.db.azerite[info[#info]] end, function(info, value) DB.db.azerite[info[#info]] = value DB:AzeriteBar_Update() DB:UpdateAll() end)
E.Options.args.databars.args.azerite.args = CopyTable(SharedOptions)
......
......@@ -3,6 +3,8 @@ local C, L = unpack(select(2, ...))
local B = E:GetModule('Blizzard')
local ACH = E.Libs.ACH
local pairs = pairs
E.Options.args.skins = ACH:Group(L["Skins"], nil, 2, 'tab')
E.Options.args.skins.args.intro = ACH:Description(L["SKINS_DESC"], 0)
E.Options.args.skins.args.general = ACH:MultiSelect(L["General"], nil, 1, nil, nil, nil,
......@@ -34,7 +36,17 @@ E.Options.args.skins.args.talkingHead.inline = true
E.Options.args.skins.args.talkingHead.args.talkingHeadFrameScale = ACH:Range(L["Talking Head Scale"], nil, 1, { min = .5, max = 2, step = .01, isPercent = true }, nil, nil, function(_, value) E.db.general.talkingHeadFrameScale = value; B:ScaleTalkingHeadFrame() end)
E.Options.args.skins.args.talkingHead.args.talkingHeadFrameBackdrop = ACH:Toggle(L["Talking Head Backdrop"], nil, 2, nil, nil, nil, nil, function(_, value) E.db.general.talkingHeadFrameBackdrop = value; E:StaticPopup_Show('CONFIG_RL') end)
E.Options.args.skins.args.blizzard = ACH:MultiSelect(L["Blizzard"], nil, 3, nil, nil, nil, function(_, key) return E.private.skins.blizzard[key] end, function(_, key, value) E.private.skins.blizzard[key] = value; E:StaticPopup_Show('PRIVATE_RL') end, function() return not E.private.skins.blizzard.enable end)
local function ToggleSkins(value)
for key in pairs(E.private.skins.blizzard) do
if key ~= 'enable' then
E.private.skins.blizzard[key] = value
end
end
end
E.Options.args.skins.args.disableBlizzardSkins = ACH:Execute(L["Disable Blizzard Skins"], nil, 3, function() ToggleSkins(false) end)
E.Options.args.skins.args.enableBlizzardSkins = ACH:Execute(L["Enable Blizzard Skins"], nil, 4, function() ToggleSkins(true) end)
E.Options.args.skins.args.blizzard = ACH:MultiSelect(L["Blizzard"], nil, -1, nil, nil, nil, function(_, key) return E.private.skins.blizzard[key] end, function(_, key, value) E.private.skins.blizzard[key] = value; E:StaticPopup_Show('PRIVATE_RL') end, function() return not E.private.skins.blizzard.enable end)
E.Options.args.skins.args.blizzard.sortByValue = true
E.Options.args.skins.args.blizzard.values = {
achievement = L["ACHIEVEMENTS"],
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment