Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
Apollyonn committed Sep 18, 2019
1 parent 90d3ac9 commit 6fd4e81
Show file tree
Hide file tree
Showing 48 changed files with 1,167 additions and 1,012 deletions.
2 changes: 1 addition & 1 deletion ElvUI/Core/Core.lua
Original file line number Diff line number Diff line change
Expand Up @@ -880,7 +880,7 @@ function E:UpdateAll(ignoreInstall)

if E.private.nameplates.enable then
NamePlates:ConfigureAll()
NamePlates:StyleFilterInitializeAllFilters()
NamePlates:StyleFilterInitialize()
end

Threat:ToggleEnable()
Expand Down
6 changes: 3 additions & 3 deletions ElvUI/Init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -72,13 +72,13 @@ do
AddOn:AddLib("AceDB", "AceDB-3.0")
AddOn:AddLib("EP", "LibElvUIPlugin-1.0")
AddOn:AddLib("LSM", "LibSharedMedia-3.0")
AddOn:AddLib("ACL", "AceLocale-3.0")
AddOn:AddLib("LAB", "LibActionButton-1.0")
AddOn:AddLib("ACL", "AceLocale-3.0-ElvUI")
AddOn:AddLib("LAB", "LibActionButton-1.0-ElvUI")
AddOn:AddLib("LDB", "LibDataBroker-1.1")
AddOn:AddLib("DualSpec", "LibDualSpec-1.0")
AddOn:AddLib("SimpleSticky", "LibSimpleSticky-1.0")
AddOn:AddLib("SpellRange", "SpellRange-1.0")
AddOn:AddLib("ItemSearch", "LibItemSearch-1.2")
AddOn:AddLib("ItemSearch", "LibItemSearch-1.2-ElvUI")
AddOn:AddLib("Compress", "LibCompress")
AddOn:AddLib("Base64", "LibBase64-1.0-ElvUI")
AddOn:AddLib("Masque", "Masque", true)
Expand Down
2 changes: 1 addition & 1 deletion ElvUI/Libraries/Ace3/AceLocale-3.0/AceLocale-3.0.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
-- @class file
-- @name AceLocale-3.0
-- @release $Id$
local MAJOR,MINOR = "AceLocale-3.0", 7
local MAJOR,MINOR = "AceLocale-3.0-ElvUI", 7

local AceLocale, oldminor = LibStub:NewLibrary(MAJOR, MINOR)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
]]
local MAJOR_VERSION = "LibActionButton-1.0"
local MAJOR_VERSION = "LibActionButton-1.0-ElvUI"
local MINOR_VERSION = 66

if not LibStub then error(MAJOR_VERSION .. " requires LibStub.") end
Expand Down
2 changes: 1 addition & 1 deletion ElvUI/Libraries/LibItemSearch-1.2/LibItemSearch-1.2.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

local Search = LibStub("CustomSearch-1.0")
local Unfit = LibStub("Unfit-1.0")
local Lib = LibStub:NewLibrary("LibItemSearch-1.2", 17)
local Lib = LibStub:NewLibrary("LibItemSearch-1.2-ElvUI", 17)
if Lib then
Lib.Scanner = LibItemSearchTooltipScanner or CreateFrame("GameTooltip", "LibItemSearchTooltipScanner", UIParent, "GameTooltipTemplate")
Lib.Filters = {}
Expand Down
2 changes: 0 additions & 2 deletions ElvUI/Libraries/oUF/elements/castbar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,6 @@ local function Enable(self, unit)
self:RegisterEvent('UNIT_SPELLCAST_CHANNEL_START', CastStart)
self:RegisterEvent('UNIT_SPELLCAST_STOP', CastStop)
self:RegisterEvent('UNIT_SPELLCAST_CHANNEL_STOP', CastStop)
self:RegisterEvent('UNIT_SPELLCAST_FAILED_QUIET', CastStop)
self:RegisterEvent('UNIT_SPELLCAST_DELAYED', CastUpdate)
self:RegisterEvent('UNIT_SPELLCAST_CHANNEL_UPDATE', CastUpdate)
self:RegisterEvent('UNIT_SPELLCAST_FAILED', CastFail)
Expand Down Expand Up @@ -484,7 +483,6 @@ local function Disable(self)
self:UnregisterEvent('UNIT_SPELLCAST_CHANNEL_UPDATE', CastUpdate)
self:UnregisterEvent('UNIT_SPELLCAST_STOP', CastStop)
self:UnregisterEvent('UNIT_SPELLCAST_CHANNEL_STOP', CastStop)
self:UnregisterEvent('UNIT_SPELLCAST_FAILED_QUIET', CastStop)
self:UnregisterEvent('UNIT_SPELLCAST_FAILED', CastFail)
self:UnregisterEvent('UNIT_SPELLCAST_INTERRUPTED', CastFail)
self:UnregisterEvent('UNIT_SPELLCAST_INTERRUPTIBLE', CastInterruptible)
Expand Down
5 changes: 4 additions & 1 deletion ElvUI/Modules/ActionBars/ActionBars.lua
Original file line number Diff line number Diff line change
Expand Up @@ -788,6 +788,7 @@ function AB:DisableBlizzard()
ReputationWatchBar:SetParent(UIHider)

MainMenuBarArtFrame:UnregisterAllEvents()
--Prevents taint in combat while using a vehicle.
MainMenuBarArtFrame:RegisterEvent("CURRENCY_DISPLAY_UPDATE")
MainMenuBarArtFrame:Hide()
MainMenuBarArtFrame:SetParent(UIHider)
Expand Down Expand Up @@ -935,7 +936,9 @@ function AB:SetupFlyoutButton()
if Button then
AB:StyleButton(Button, nil, MasqueGroup and E.private.actionbar.masque.actionbars and true or nil)

Button:Size(Button:GetParent():GetParent():GetSize())
if not InCombatLockdown() then -- Taint
Button:Size(Button:GetParent():GetParent():GetSize())
end

Button:HookScript("OnEnter", function(self)
local parent = self:GetParent()
Expand Down
4 changes: 2 additions & 2 deletions ElvUI/Modules/ActionBars/PetBar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function AB:UpdatePet(event, unit)
button.isToken = isToken
button.tooltipSubtext = subtext

if isActive --[[and name ~= "PET_ACTION_FOLLOW"]] then
if isActive then
button:SetChecked(true)

if IsPetAttackAction(i) then
Expand Down Expand Up @@ -85,7 +85,7 @@ function AB:UpdatePet(event, unit)
icon:Hide()
end

if not PetHasActionBar() and texture --[[and name ~= "PET_ACTION_FOLLOW"]] then
if not PetHasActionBar() and texture then
PetActionButton_StopFlash(button)
SetDesaturation(icon, 1)
button:SetChecked(0)
Expand Down
28 changes: 13 additions & 15 deletions ElvUI/Modules/Auras/Auras.lua
Original file line number Diff line number Diff line change
Expand Up @@ -464,11 +464,11 @@ function A:Initialize()

self.BuffFrame = self:CreateAuraHeader("HELPFUL")
self.BuffFrame:Point("TOPRIGHT", MMHolder, "TOPLEFT", -(6 + E.Border), -E.Border - E.Spacing)
E:CreateMover(self.BuffFrame, "BuffsMover", L["Player Buffs"])
E:CreateMover(self.BuffFrame, "BuffsMover", L["Player Buffs"], nil, nil, nil, nil, nil, "auras,buffs")

self.DebuffFrame = self:CreateAuraHeader("HARMFUL")
self.DebuffFrame:Point("BOTTOMRIGHT", MMHolder, "BOTTOMLEFT", -(6 + E.Border), E.Border + E.Spacing)
E:CreateMover(self.DebuffFrame, "DebuffsMover", L["Player Debuffs"])
E:CreateMover(self.DebuffFrame, "DebuffsMover", L["Player Debuffs"], nil, nil, nil, nil, nil, "auras,debuffs")

self.EnchantHeader = CreateFrame("Frame", "ElvUITemporaryEnchantFrame", E.UIParent, "SecureHandlerStateTemplate")
self.EnchantHeader:Point("TOPRIGHT", MMHolder, "BOTTOMRIGHT", 0, -E.Border - E.Spacing)
Expand Down Expand Up @@ -503,35 +503,33 @@ function A:Initialize()
self:SecureHook("AuraButton_UpdateDuration", "UpdateWeaponText")

self.EnchantHeader.GetUpdateWeaponEnchant = function(self)
local hasMainHandEnchant, _, _, hasOffHandEnchant, _, _, hasThrownEnchant = GetWeaponEnchantInfo()
local mainHand = GetInventoryItemQuality("player", 16)
local offHand = GetInventoryItemQuality("player", 17)
local thrown = GetInventoryItemQuality("player", 18)
local mainEnchant, _, _, offEnchant, _, _, thrownEnchant = GetWeaponEnchantInfo()
local mainHand, offHand, thrown = GetInventoryItemQuality("player", 16), GetInventoryItemQuality("player", 17), GetInventoryItemQuality("player", 18)

if hasMainHandEnchant and hasOffHandEnchant and hasThrownEnchant then
if mainEnchant and offEnchant and thrownEnchant then
TempEnchant1:SetBackdropBorderColor(GetItemQualityColor(thrown))
TempEnchant2:SetBackdropBorderColor(GetItemQualityColor(offHand))
TempEnchant3:SetBackdropBorderColor(GetItemQualityColor(mainHand))
return true
elseif hasMainHandEnchant and hasOffHandEnchant and not hasThrownEnchant then
elseif mainEnchant and offEnchant and not thrownEnchant then
TempEnchant1:SetBackdropBorderColor(GetItemQualityColor(offHand))
TempEnchant2:SetBackdropBorderColor(GetItemQualityColor(mainHand))
return true
elseif hasMainHandEnchant and not hasOffHandEnchant and hasThrownEnchant then
elseif mainEnchant and not offEnchant and thrownEnchant then
TempEnchant1:SetBackdropBorderColor(GetItemQualityColor(thrown))
TempEnchant2:SetBackdropBorderColor(GetItemQualityColor(mainHand))
return true
elseif not hasMainHandEnchant and hasOffHandEnchant and hasThrownEnchant then
elseif not mainEnchant and offEnchant and thrownEnchant then
TempEnchant1:SetBackdropBorderColor(GetItemQualityColor(thrown))
TempEnchant2:SetBackdropBorderColor(GetItemQualityColor(offHand))
return true
elseif hasMainHandEnchant and not hasOffHandEnchant and not hasThrownEnchant then
elseif mainEnchant and not offEnchant and not thrownEnchant then
TempEnchant1:SetBackdropBorderColor(GetItemQualityColor(mainHand))
return true
elseif not hasMainHandEnchant and hasOffHandEnchant and not hasThrownEnchant then
elseif not mainEnchant and offEnchant and not thrownEnchant then
TempEnchant1:SetBackdropBorderColor(GetItemQualityColor(offHand))
return true
elseif not hasMainHandEnchant and not hasOffHandEnchant and hasThrownEnchant then
elseif not mainEnchant and not offEnchant and thrownEnchant then
TempEnchant1:SetBackdropBorderColor(GetItemQualityColor(thrown))
return true
end
Expand All @@ -541,7 +539,7 @@ function A:Initialize()
if self:GetUpdateWeaponEnchant() then A:UpdateTempEnchant() end
end)

E:CreateMover(self.EnchantHeader, "TempEnchantMover", L["Weapons"])
E:CreateMover(self.EnchantHeader, "TempEnchantMover", L["Weapons"], nil, nil, nil, nil, nil, "auras,weapons")

if Masque then
if MasqueGroupBuffs then A.BuffsMasqueGroup = MasqueGroupBuffs end
Expand All @@ -553,4 +551,4 @@ local function InitializeCallback()
A:Initialize()
end

E:RegisterModule(A:GetName(), InitializeCallback)
E:RegisterModule(A:GetName(), InitializeCallback)
6 changes: 2 additions & 4 deletions ElvUI/Modules/Bags/Bags.lua
Original file line number Diff line number Diff line change
Expand Up @@ -348,10 +348,8 @@ function B:UpdateSlot(frame, bagID, slotID)
slot.junkDesaturate = slot.isJunk and E.db.bags.junkDesaturate

-- Junk Icon
if slot.JunkIcon then
if E.db.bags.junkIcon and slot.isJunk then
slot.JunkIcon:Show()
end
if E.db.bags.junkIcon and slot.isJunk then
slot.JunkIcon:Show()
end

-- Quest Icon
Expand Down
11 changes: 5 additions & 6 deletions ElvUI/Modules/Blizzard/Blizzard.lua
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ function B:Initialize()
self:SkinAltPowerBar()
end

self:RegisterEvent("ZONE_CHANGED_NEW_AREA", SetMapToCurrentZone)

if GetLocale() == "deDE" then
DAY_ONELETTER_ABBR = "%d d"
end
Expand Down Expand Up @@ -55,12 +57,9 @@ function B:Initialize()
TalentMicroButtonAlert.button = CreateFrame("Button", nil, TalentMicroButtonAlert, nil)
TalentMicroButtonAlert.button:SetAllPoints(TalentMicroButtonAlert)
TalentMicroButtonAlert.button:HookScript("OnClick", function()
if not PlayerTalentFrame then
TalentFrame_LoadUI()
end
if not GlyphFrame then
GlyphFrame_LoadUI()
end
if not PlayerTalentFrame then TalentFrame_LoadUI() end
if not GlyphFrame then GlyphFrame_LoadUI() end

if not PlayerTalentFrame:IsShown() then
ShowUIPanel(PlayerTalentFrame)
else
Expand Down
28 changes: 19 additions & 9 deletions ElvUI/Modules/Blizzard/WatchFrame.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,35 +6,45 @@ local min = math.min
local hooksecurefunc = hooksecurefunc
local GetScreenHeight = GetScreenHeight

local hideRule = "[@arena1,exists][@arena2,exists][@arena3,exists][@arena4,exists][@arena5,exists][@boss1,exists][@boss2,exists][@boss3,exists][@boss4,exists]"

function B:SetObjectiveFrameAutoHide()
if E.db.general.watchFrameAutoHide then
RegisterStateDriver(WatchFrame, "visibility", hideRule)
else
UnregisterStateDriver(WatchFrame, "visibility")
end
end

function B:SetWatchFrameHeight()
local top = _G.WatchFrame:GetTop() or 0
local top = WatchFrame:GetTop() or 0
local screenHeight = GetScreenHeight()
local gapFromTop = screenHeight - top
local maxHeight = screenHeight - gapFromTop
local watchFrameHeight = min(maxHeight, E.db.general.watchFrameHeight)

_G.WatchFrame:Height(watchFrameHeight)
WatchFrame:Height(watchFrameHeight)
end

function B:MoveWatchFrame()
local WatchFrameHolder = CreateFrame("Frame", "WatchFrameHolder", E.UIParent)
WatchFrameHolder:Width(207)
WatchFrameHolder:Height(22)
WatchFrameHolder:Point('TOPRIGHT', E.UIParent, 'TOPRIGHT', -135, -300)
WatchFrameHolder:Size(207, 22)
WatchFrameHolder:Point("TOPRIGHT", E.UIParent, "TOPRIGHT", -135, -300)

E:CreateMover(WatchFrameHolder, "WatchFrameMover", L["Objective Frame"])
E:CreateMover(WatchFrameHolder, "WatchFrameMover", L["Objective Frame"], nil, nil, nil, nil, nil, "general,objectiveFrameGroup")
WatchFrameHolder:SetAllPoints(WatchFrameMover)

WatchFrame:ClearAllPoints()
WatchFrame:SetPoint("TOP", WatchFrameHolder, "TOP")
B:SetWatchFrameHeight()
WatchFrame:SetClampedToScreen(false)

local function WatchFrame_SetPosition(_, _, parent)
hooksecurefunc(WatchFrame, "SetPoint", function(_, _, parent)
if parent ~= WatchFrameHolder then
WatchFrame:ClearAllPoints()
WatchFrame:SetPoint("TOP", WatchFrameHolder, "TOP")
end
end
hooksecurefunc(WatchFrame, "SetPoint", WatchFrame_SetPosition)
end)

self:SetObjectiveFrameAutoHide()
end
8 changes: 4 additions & 4 deletions ElvUI/Modules/Maps/Minimap.lua
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ function M:UpdateSettings()
if not E.private.general.minimap.enable then return end

if GameTimeFrame then
if E.private.general.minimap.hideCalendar then
if E.db.general.minimap.icons.calendar.hide then
GameTimeFrame:Hide()
else
local pos = E.db.general.minimap.icons.calendar.position or "TOPRIGHT"
Expand Down Expand Up @@ -396,7 +396,7 @@ function M:UpdateSettings()
end

if MiniMapWorldMapButton then
if E.private.general.minimap.hideWorldMap then
if E.db.general.minimap.icons.worldMap.hide then
MiniMapWorldMapButton:Hide()
else
local pos = E.db.general.minimap.icons.worldMap.position or "TOPRIGHT"
Expand Down Expand Up @@ -510,7 +510,7 @@ function M:Initialize()
TimeManagerClockButton:Kill()
end

E:CreateMover(MMHolder, "MinimapMover", L["Minimap"], nil, nil, MinimapPostDrag)
E:CreateMover(MMHolder, "MinimapMover", L["Minimap"], nil, nil, MinimapPostDrag, nil, nil, "maps,minimap")

Minimap:EnableMouseWheel(true)
Minimap:SetScript("OnMouseWheel", M.Minimap_OnMouseWheel)
Expand Down Expand Up @@ -592,4 +592,4 @@ local function InitializeCallback()
M:Initialize()
end

E:RegisterInitialModule(M:GetName(), InitializeCallback)
E:RegisterInitialModule(M:GetName(), InitializeCallback)
10 changes: 4 additions & 6 deletions ElvUI/Modules/Misc/RaidBuffReminder.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
local RB = E:GetModule("ReminderBuffs")
local LSM = E.Libs.LSM

local pairs, unpack = pairs, unpack
local ipairs, unpack = ipairs, unpack
local format = string.format

local Masque = E.Libs.Masque
Expand Down Expand Up @@ -142,7 +142,7 @@ RB.MeleeSpell6Buffs = {
function RB:CheckFilterForActiveBuff(filter)
local spellName, name, texture, duration, expirationTime

for _, spell in pairs(filter) do
for _, spell in ipairs(filter) do
spellName = GetSpellInfo(spell)
name, _, texture, _, _, duration, expirationTime = UnitAura("player", spellName)

Expand Down Expand Up @@ -286,14 +286,12 @@ function RB:UpdateSettings(isCallback)

if i == 1 then
button:Point("TOP", ElvUI_ReminderBuffs, "TOP", 0, 0)
elseif i == 6 then
button:Point("BOTTOM", ElvUI_ReminderBuffs, "BOTTOM", 0, 0)
else
button:Point("TOP", frame[i - 1], "BOTTOM", 0, E.Border - E.Spacing*3)
end

if i == 6 then
button:Point("BOTTOM", ElvUI_ReminderBuffs, "BOTTOM", 0, 0)
end

if E.db.general.reminder.durations then
button.cd:SetAlpha(1)
else
Expand Down
3 changes: 1 addition & 2 deletions ElvUI/Modules/Misc/TotemBar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ function TOTEMS:Update()
local displayedTotems = 0

for i = 1, MAX_TOTEMS do
local color
local haveTotem, _, startTime, duration, icon = GetTotemInfo(i)

if haveTotem and icon and icon ~= "" then
Expand All @@ -30,7 +29,7 @@ function TOTEMS:Update()
CooldownFrame_SetTimer(self.bar[i].cooldown, startTime, duration, 1)

if E.myclass == "SHAMAN" then
color = SLOT_BORDER_COLORS[self.bar[i]:GetID()]
local color = SLOT_BORDER_COLORS[self.bar[i]:GetID()]
self.bar[i]:SetBackdropBorderColor(color.r, color.g, color.b)
self.bar[i].ignoreBorderColors = true
end
Expand Down
Loading

0 comments on commit 6fd4e81

Please sign in to comment.