From 7f1f1fda308620b79ab0db97ed325359d7801f49 Mon Sep 17 00:00:00 2001 From: Darthpred Date: Mon, 14 Jul 2014 04:36:09 +0400 Subject: [PATCH] New module and shit --- ElvUI_SLE/core/core.lua | 32 --------- ElvUI_SLE/core/load_core.xml | 2 +- ElvUI_SLE/core/media.lua | 118 +++++++++++++++++++++++++++++++ ElvUI_SLE/core/modules.lua | 1 + ElvUI_SLE/core/toolkit.lua | 2 + ElvUI_SLE/defaults/private.lua | 25 ------- ElvUI_SLE/defaults/profile.lua | 35 +++++++++ ElvUI_SLE/options/media_c.lua | 153 ++++++++++++++++++++++++++++------------ 8 files changed, 263 insertions(+), 105 deletions(-) create mode 100644 ElvUI_SLE/core/media.lua diff --git a/ElvUI_SLE/core/core.lua b/ElvUI_SLE/core/core.lua index 113cc58..e6ad0db 100644 --- a/ElvUI_SLE/core/core.lua +++ b/ElvUI_SLE/core/core.lua @@ -2,7 +2,6 @@ local SLE = E:GetModule('SLE') local EP = LibStub("LibElvUIPlugin-1.0") local UF = E:GetModule('UnitFrames') -local LSM = LibStub("LibSharedMedia-3.0") local addon = ... --localizing functions-- @@ -63,34 +62,6 @@ local function CheckIncompatible() end end -local subOff - -local function ZoneTextPos() - if ( PVPInfoTextString:GetText() == "" ) then - SubZoneTextString:SetPoint("TOP", "ZoneTextString", "BOTTOM", 0, -subOff); - else - SubZoneTextString:SetPoint("TOP", "PVPInfoTextString", "BOTTOM", 0, -subOff); - end -end - -local function SetFonts() - local db = E.global.sle.fonts - - ZoneTextString:SetFont(LSM:Fetch('font', db.zone.font), db.zone.size, db.zone.outline) - PVPInfoTextString:SetFont(LSM:Fetch('font', db.pvp.font), db.pvp.size, db.pvp.outline) - PVPArenaTextString:SetFont(LSM:Fetch('font', db.pvp.font), db.pvp.size, db.pvp.outline) - SubZoneTextString:SetFont(LSM:Fetch('font', db.subzone.font), db.subzone.size, db.subzone.outline) - - ZoneTextString:SetWidth(db.zone.width) - PVPInfoTextString:SetWidth(db.pvp.width) - PVPArenaTextString:SetWidth(db.pvp.width) - SubZoneTextString:SetWidth(db.subzone.width) - - --Dat is like experiment, don't touch-- - subOff = db.subzone.offset - hooksecurefunc("SetZoneText", ZoneTextPos) -end - function SLE:Initialize() --ElvUI's version check if elvV < elvR then @@ -108,7 +79,4 @@ function SLE:Initialize() ConfigCats() SLE:RegisterCommands() CheckIncompatible() - if E.global.sle.fonts.enable then - hooksecurefunc(E, "UpdateBlizzardFonts", SetFonts) - end end \ No newline at end of file diff --git a/ElvUI_SLE/core/load_core.xml b/ElvUI_SLE/core/load_core.xml index e263927..015cd78 100644 --- a/ElvUI_SLE/core/load_core.xml +++ b/ElvUI_SLE/core/load_core.xml @@ -1 +1 @@ -