From 5310ffc5a334eca6f5d2828cf4062823645003f9 Mon Sep 17 00:00:00 2001 From: Darthpred Date: Mon, 4 Aug 2014 14:10:36 +0400 Subject: [PATCH] Don't use both at the same time --- ElvUI_SLE/core/core.lua | 3 +++ ElvUI_SLE/core/staticpopups.lua | 11 +++++++++++ 2 files changed, 14 insertions(+) diff --git a/ElvUI_SLE/core/core.lua b/ElvUI_SLE/core/core.lua index 6d6cf95..c71e5c5 100644 --- a/ElvUI_SLE/core/core.lua +++ b/ElvUI_SLE/core/core.lua @@ -59,6 +59,9 @@ local function CheckIncompatible() if IsAddOnLoaded('SquareMinimapButtons') and E.private.sle.minimap.mapicons.enable then IncompatibleAddOn('SquareMinimapButtons', 'SquareMinimapButtons', E.private.sle.minimap.mapicons, "enable") end + if IsAddOnLoaded('LootConfirm') then + E:StaticPopup_Show('LOOTCONFIRM_SLE_INCOMPATIBLE') + end end function SLE:Initialize() diff --git a/ElvUI_SLE/core/staticpopups.lua b/ElvUI_SLE/core/staticpopups.lua index b8686cd..430174c 100644 --- a/ElvUI_SLE/core/staticpopups.lua +++ b/ElvUI_SLE/core/staticpopups.lua @@ -24,6 +24,17 @@ E.PopupDialogs['ENHANCED_SLE_INCOMPATIBLE'] = { hideOnEscape = false, } +E.PopupDialogs['LOOTCONFIRM_SLE_INCOMPATIBLE'] = { + text = L['You have got Loot Confirm and Shadow & Light both enabled at the same time. Select an addon to disable.'], + OnAccept = function() DisableAddOn("LootConfirm"); ReloadUI() end, + OnCancel = function() DisableAddOn("ElvUI_SLE"); ReloadUI() end, + button1 = 'Loot Confirm', + button2 = 'Shadow & Light', + timeout = 0, + whileDead = 1, + hideOnEscape = false, +} + E.PopupDialogs['SLE_INCOMPATIBLE_ADDON'] = { text = gsub(L["INCOMPATIBLE_ADDON"], "ElvUI", "Shadow & Light"), OnAccept = function(self) DisableAddOn(E.PopupDialogs['SLE_INCOMPATIBLE_ADDON'].addon); ReloadUI(); end, -- 1.7.9.5