Quantcast

Super Clean Version!!

Steven Jackson [07-09-14 - 03:50]
Super Clean Version!!
Filename
Interface/AddOns/SVUI/packages/actionbar/common/actionbar.lua
Interface/AddOns/SVUI/packages/bag/common/breakstuff.lua
Interface/AddOns/SVUI/packages/dock/SVDock.lua
Interface/AddOns/SVUI/packages/dock/common/toolbar.lua
Interface/AddOns/SVUI/packages/unit/SVUnit.lua
Interface/AddOns/SVUI/packages/unit/class/druid.lua
Interface/AddOns/SVUI/packages/unit/common/media.lua
Interface/AddOns/SVUI/packages/unit/frames/basic/focus.lua
Interface/AddOns/SVUI/packages/unit/frames/basic/ft.lua
Interface/AddOns/SVUI/packages/unit/frames/basic/pet.lua
Interface/AddOns/SVUI/packages/unit/frames/basic/player.lua
Interface/AddOns/SVUI/packages/unit/frames/basic/pt.lua
Interface/AddOns/SVUI/packages/unit/frames/basic/target.lua
Interface/AddOns/SVUI/packages/unit/frames/basic/tot.lua
Interface/AddOns/SVUI/packages/unit/frames/extra/arena.lua
Interface/AddOns/SVUI/packages/unit/frames/extra/boss.lua
Interface/AddOns/SVUI/packages/unit/frames/group/assist.lua
Interface/AddOns/SVUI/packages/unit/frames/group/party.lua
Interface/AddOns/SVUI/packages/unit/frames/group/raid.lua
Interface/AddOns/SVUI/packages/unit/frames/group/rpet.lua
Interface/AddOns/SVUI/packages/unit/frames/group/tank.lua
Interface/AddOns/SVUI/system/alerts.lua
Interface/AddOns/SVUI/system/classes/Database.lua
Interface/AddOns/SVUI/system/installer.lua
Interface/AddOns/SVUI/system/presets.lua
Interface/AddOns/SVUI/system/system.lua
Interface/AddOns/SVUI_ConfigOMatic/modules/units/core.lua
diff --git a/Interface/AddOns/SVUI/packages/actionbar/common/actionbar.lua b/Interface/AddOns/SVUI/packages/actionbar/common/actionbar.lua
index b2fb552..d2a7d77 100644
--- a/Interface/AddOns/SVUI/packages/actionbar/common/actionbar.lua
+++ b/Interface/AddOns/SVUI/packages/actionbar/common/actionbar.lua
@@ -18,11 +18,11 @@ local LibAB = LibStub("LibActionButton-1.0");
 local NUM_ACTIONBAR_BUTTONS = NUM_ACTIONBAR_BUTTONS
 local pointSets = {
   {"BOTTOM","SVUIParent","BOTTOM",0,28},
-  {"BOTTOM","SVUI_ActionBar1","TOP",0,2},
-  {"BOTTOMLEFT","SVUI_ActionBar1","BOTTOMRIGHT",2,0},
-  {"RIGHT","SVUIParent","RIGHT",-2,0},
-  {"BOTTOMRIGHT","SVUI_ActionBar1","BOTTOMLEFT",2,0},
-  {"BOTTOM","SVUI_ActionBar2","TOP",0,2},
+  {"BOTTOM","SVUI_ActionBar1","TOP",0,4},
+  {"BOTTOMLEFT","SVUI_ActionBar1","BOTTOMRIGHT",4,0},
+  {"RIGHT","SVUIParent","RIGHT",-4,0},
+  {"BOTTOMRIGHT","SVUI_ActionBar1","BOTTOMLEFT",-4,0},
+  {"BOTTOM","SVUI_ActionBar2","TOP",0,4},
 };
 --[[
 ##########################################################
diff --git a/Interface/AddOns/SVUI/packages/bag/common/breakstuff.lua b/Interface/AddOns/SVUI/packages/bag/common/breakstuff.lua
index 1ddd237..2f48f1e 100644
--- a/Interface/AddOns/SVUI/packages/bag/common/breakstuff.lua
+++ b/Interface/AddOns/SVUI/packages/bag/common/breakstuff.lua
@@ -40,6 +40,7 @@ local TTIP = SuperVillain.Registry:Expose('SVTip');
 LOCAL VARS
 ##########################################################
 ]]--
+local BreakStuffButton = CreateFrame("Button", "BreakStuffButton", UIParent)
 local BreakStuff_Cache = {}
 local DE, PICK, SMITH, BreakStuffParser;
 local ICONARTFILE = [[Interface\AddOns\SVUI\assets\artwork\Icons\DOCK-BREAKSTUFF]];
@@ -249,7 +250,12 @@ function MOD:BreakStuffLoader()
 		tinsert(spellListing, SMITH)
 	end

-	if not allowed then return end
+	if not allowed then return end
+
+	BreakStuffButton:SetParent(SuperDockMacroBar)
+	local size = SuperDockMacroBar.currentSize
+	BreakStuffButton:Size(size, size)
+	BreakStuffButton:Point("RIGHT", SuperDockMacroBar, "LEFT", -6, 0)
 	BreakStuffButton:Show();
 	BreakStuffButton:SetFramedButtonTemplate()
 	BreakStuffButton.icon=BreakStuffButton:CreateTexture(nil,"OVERLAY")
diff --git a/Interface/AddOns/SVUI/packages/dock/SVDock.lua b/Interface/AddOns/SVUI/packages/dock/SVDock.lua
index 44ce579..8f5955f 100644
--- a/Interface/AddOns/SVUI/packages/dock/SVDock.lua
+++ b/Interface/AddOns/SVUI/packages/dock/SVDock.lua
@@ -255,7 +255,8 @@ function MOD:CreateDockPanels()
 	local spacing = MOD.db.buttonSpacing or 4;
 	local STATS = SuperVillain.Registry:Expose("SVStats");

-	-- [[ CORNER BUTTONS ]] --
+	-- [[ CORNER BUTTON ]] --
+
 	local leftbutton = CreateFrame("Button", "LeftSuperDockToggleButton", SuperVillain.UIParent)
 	leftbutton:Point("BOTTOMLEFT", SuperVillain.UIParent, "BOTTOMLEFT", 1, 2)
 	leftbutton:Size(buttonsize, buttonsize)
@@ -268,22 +269,8 @@ function MOD:CreateDockPanels()
 	leftbutton:SetScript("OnLeave", Dock_OnLeave)
 	leftbutton:SetScript("OnClick", Dock_OnClick)

-	local rightbutton = CreateFrame("Button", "RightSuperDockToggleButton", SuperVillain.UIParent)
-	rightbutton:Point("BOTTOMRIGHT", SuperVillain.UIParent, "BOTTOMRIGHT", -1, 2)
-	rightbutton:Size(buttonsize, buttonsize)
-	rightbutton:SetFramedButtonTemplate()
-	rightbutton.icon = rightbutton:CreateTexture(nil, "OVERLAY")
-	rightbutton.icon:FillInner(rightbutton,2,2)
-	rightbutton.icon:SetTexture([[Interface\AddOns\SVUI\assets\artwork\Icons\DOCK-HENCHMAN]])
-	rightbutton.icon:SetGradient("VERTICAL", 0.5, 0.53, 0.55, 0.8, 0.8, 1)
-	rightbutton.TText = "Call Henchman!"
-	rightbutton:RegisterForClicks("AnyUp")
-	rightbutton:SetScript("OnEnter", Button_OnEnter)
-	rightbutton:SetScript("OnLeave", Button_OnLeave)
-	rightbutton:SetScript("OnClick", function()SuperVillain:ToggleHenchman()end)
-
-
 	-- [[ TOOLBARS AND OTHER NONSENSE ]] --
+
 	local toolbarLeft = CreateFrame("Button", "SuperDockToolBarLeft", SuperVillain.UIParent)
 	toolbarLeft:Point("LEFT", leftbutton, "RIGHT", spacing, 0)
 	toolbarLeft:Width(1)
@@ -317,6 +304,24 @@ function MOD:CreateDockPanels()

 	LeftSuperDock.fadeFunc = FadeUpdate;

+	-- [[ CORNER BUTTON ]] --
+
+	local rightbutton = CreateFrame("Button", "RightSuperDockToggleButton", SuperVillain.UIParent)
+	rightbutton:Point("BOTTOMRIGHT", SuperVillain.UIParent, "BOTTOMRIGHT", -1, 2)
+	rightbutton:Size(buttonsize, buttonsize)
+	rightbutton:SetFramedButtonTemplate()
+	rightbutton.icon = rightbutton:CreateTexture(nil, "OVERLAY")
+	rightbutton.icon:FillInner(rightbutton,2,2)
+	rightbutton.icon:SetTexture([[Interface\AddOns\SVUI\assets\artwork\Icons\DOCK-HENCHMAN]])
+	rightbutton.icon:SetGradient("VERTICAL", 0.5, 0.53, 0.55, 0.8, 0.8, 1)
+	rightbutton.TText = "Call Henchman!"
+	rightbutton:RegisterForClicks("AnyUp")
+	rightbutton:SetScript("OnEnter", Button_OnEnter)
+	rightbutton:SetScript("OnLeave", Button_OnLeave)
+	rightbutton:SetScript("OnClick", function()SuperVillain:ToggleHenchman()end)
+
+	-- [[ TOOLBARS AND OTHER NONSENSE ]] --
+
 	local toolbarRight = CreateFrame("Button", "SuperDockToolBarRight", SuperVillain.UIParent)
 	toolbarRight:Point("RIGHT", rightbutton, "LEFT", -spacing, 0)
 	toolbarRight:Size(1, buttonsize)
@@ -392,7 +397,6 @@ function MOD:UpdateThisPackage()
 end

 function MOD:ConstructThisPackage()
-	self:Protect("LoadToolBarProfessions")
 	self:CreateSuperBorders()
 	self:CreateDockPanels()
 	self:CreateDockWindow()
diff --git a/Interface/AddOns/SVUI/packages/dock/common/toolbar.lua b/Interface/AddOns/SVUI/packages/dock/common/toolbar.lua
index 4e2db0f..51462fa 100644
--- a/Interface/AddOns/SVUI/packages/dock/common/toolbar.lua
+++ b/Interface/AddOns/SVUI/packages/dock/common/toolbar.lua
@@ -45,34 +45,6 @@ local TOOL_DATA = {
 PRE VARS/FUNCTIONS
 ##########################################################
 ]]--
-local function HearthTime()
-	local start,duration = GetItemCooldown(6948)
-	local expires = duration - (GetTime() - start)
-	if expires > 0.05 then
-		local timeLeft = 0;
-		local calc = 0;
-		if expires < 4 then
-			return format("|cffff0000%.1f|r", expires)
-		elseif expires < 60 then
-			return format("|cffffff00%d|r", floor(expires))
-		elseif expires < 3600 then
-			timeLeft = ceil(expires / 60);
-			calc = floor((expires / 60) + .5);
-			return format("|cffff9900%dm|r", timeLeft)
-		elseif expires < 86400 then
-			timeLeft = ceil(expires / 3600);
-			calc = floor((expires / 3600) + .5);
-			return format("|cff66ffff%dh|r", timeLeft)
-		else
-			timeLeft = ceil(expires / 86400);
-			calc = floor((expires / 86400) + .5);
-			return format("|cff6666ff%dd|r", timeLeft)
-		end
-	else
-		return "|cff6666ffReady|r"
-	end
-end
-
 local function GetDefaultWindow()
 	local window = MOD.DefaultWindow
 	if window and _G[window] and not _G[window]:IsShown() then
@@ -153,29 +125,6 @@ local Macro_OnLeave = function(self)
 	GameTooltip:Hide()
 end

-local Hearth_OnEnter = function(self)
-	if InCombatLockdown() then return end
-	self.glow:Show()
-	self:SetPanelColor("highlight")
-	GameTooltip:SetOwner(self, "ANCHOR_TOPLEFT", 0, 4)
-	GameTooltip:ClearLines()
-	local remaining = HearthTime()
-	GameTooltip:AddLine(L["Hearthstone"], 1, 1, 1)
-	GameTooltip:AddDoubleLine(L["Time Remaining"], remaining, 1, 1, 1, 0, 1, 1)
-	if(self.ExtraSpell) then
-		GameTooltip:AddLine(" ", 1, 1, 1)
-		GameTooltip:AddDoubleLine(self.ExtraSpell, "[Right Click]", 1, 1, 1, 0, 1, 0)
-	end
-	GameTooltip:Show()
-end
-
-local Hearth_OnLeave = function(self)
-	if InCombatLockdown() then return end
-	self.glow:Hide()
-	self:SetPanelColor("special")
-	GameTooltip:Hide()
-end
-
 MOD.ToolsList = {};
 MOD.ToolsSafty = {};
 MOD.LastAddedTool = false;
@@ -195,11 +144,7 @@ function MOD:RemoveTool(frame)
 	local height = SuperDockToolBarRight.currentSize;
 	MOD.LastAddedTool = MOD.ToolsList[#MOD.ToolsList]
 	width = #MOD.ToolsList * (height + 6)
-	SuperDockToolBarRight:ClearAllPoints()
-	SuperDockToolBarRight:Point("RIGHT", RightSuperDockHearthButton, "LEFT", -6, 0)
 	SuperDockToolBarRight:Size(width, height)
-	SuperDockMacroBar:ClearAllPoints()
-	SuperDockMacroBar:Point("RIGHT", SuperDockToolBarRight, "LEFT", -6, 0)
 end

 function MOD:AddTool(frame)
@@ -217,11 +162,7 @@ function MOD:AddTool(frame)
  	frame.listIndex = #MOD.ToolsList;
 	MOD.LastAddedTool = frame;
 	width = #MOD.ToolsList * (height + 6)
-	SuperDockToolBarRight:ClearAllPoints()
-	SuperDockToolBarRight:Point("RIGHT", RightSuperDockHearthButton, "LEFT", -6, 0)
 	SuperDockToolBarRight:Size(width, height)
-	SuperDockMacroBar:ClearAllPoints()
-	SuperDockMacroBar:Point("RIGHT", SuperDockToolBarRight, "LEFT", -6, 0)
 end

 function MOD:CreateBasicToolButton(name,texture,onclick,frameName,isdefault)
@@ -258,6 +199,57 @@ do
 	local LastAddedMacro;
 	local MacroCount = 0;

+	local function HearthTime()
+		local start,duration = GetItemCooldown(6948)
+		local expires = duration - (GetTime() - start)
+		if expires > 0.05 then
+			local timeLeft = 0;
+			local calc = 0;
+			if expires < 4 then
+				return format("|cffff0000%.1f|r", expires)
+			elseif expires < 60 then
+				return format("|cffffff00%d|r", floor(expires))
+			elseif expires < 3600 then
+				timeLeft = ceil(expires / 60);
+				calc = floor((expires / 60) + .5);
+				return format("|cffff9900%dm|r", timeLeft)
+			elseif expires < 86400 then
+				timeLeft = ceil(expires / 3600);
+				calc = floor((expires / 3600) + .5);
+				return format("|cff66ffff%dh|r", timeLeft)
+			else
+				timeLeft = ceil(expires / 86400);
+				calc = floor((expires / 86400) + .5);
+				return format("|cff6666ff%dd|r", timeLeft)
+			end
+		else
+			return "|cff6666ffReady|r"
+		end
+	end
+
+	local Hearth_OnEnter = function(self)
+		if InCombatLockdown() then return end
+		self.glow:Show()
+		self:SetPanelColor("highlight")
+		GameTooltip:SetOwner(self, "ANCHOR_TOPLEFT", 0, 4)
+		GameTooltip:ClearLines()
+		GameTooltip:AddLine(L["Hearthstone"], 1, 1, 1)
+		local remaining = HearthTime()
+		GameTooltip:AddDoubleLine(L["Time Remaining"], remaining, 1, 1, 1, 0, 1, 1)
+		if(self.ExtraSpell) then
+			GameTooltip:AddLine(" ", 1, 1, 1)
+			GameTooltip:AddDoubleLine(self.ExtraSpell, "[Right Click]", 1, 1, 1, 0, 1, 0)
+		end
+		GameTooltip:Show()
+	end
+
+	local Hearth_OnLeave = function(self)
+		if InCombatLockdown() then return end
+		self.glow:Hide()
+		self:SetPanelColor("special")
+		GameTooltip:Hide()
+	end
+
 	local function AddMacroTool(frame)
 		local width;
 		local height = SuperDockToolBarRight.currentSize;
@@ -269,9 +261,7 @@ do
 		LastAddedMacro = frame;
 		MacroCount = MacroCount + 1;
 		width = MacroCount * (height + 6)
-		SuperDockMacroBar:ClearAllPoints()
 		SuperDockMacroBar:Size(width, height)
-		SuperDockMacroBar:Point("RIGHT", SuperDockToolBarRight, "LEFT", -6, 0)
 	end

 	local function CreateMacroToolButton(proName, itemID, size)
@@ -304,10 +294,10 @@ do
 	function MOD:LoadToolBarProfessions()
 		if(MOD.ToolBarLoaded) then return end
 		local size = SuperDockMacroBar.currentSize
-		local hearth = CreateFrame("Button", "RightSuperDockHearthButton", SuperVillain.UIParent, "SecureActionButtonTemplate")
+		local hearth = CreateFrame("Button", "RightSuperDockHearthButton", SuperDockMacroBar, "SecureActionButtonTemplate")
 		hearth:Size(size, size)
-		hearth:SetFramedButtonTemplate()
 		AddMacroTool(hearth)
+		hearth:SetFramedButtonTemplate()
 		hearth.icon = hearth:CreateTexture(nil, "OVERLAY", nil, 0)
 		hearth.icon:FillInner(hearth,2,2)
 		hearth.icon:SetTexture("Interface\\AddOns\\SVUI\\assets\\artwork\\Icons\\DOCK-HEARTH")
@@ -318,6 +308,10 @@ do
 		hearth.glow:SetTexture("Interface\\AddOns\\SVUI\\assets\\artwork\\Icons\\DOCK-HEARTH")
 		hearth.glow:SetTexCoord(0.5,1,0,1)
 		hearth.glow:Hide()
+		hearth:SetScript("OnEnter", Hearth_OnEnter)
+		hearth:SetScript("OnLeave", Hearth_OnLeave)
+
+		hearth:RegisterForClicks("AnyUp")
 		hearth:SetAttribute("type","item")
 		hearth:SetAttribute("item","Hearthstone")

@@ -339,9 +333,6 @@ do
 			hearth.ExtraSpell = "Zen Pilgrimage"
 		end

-		hearth:SetScript("OnEnter", Hearth_OnEnter)
-		hearth:SetScript("OnLeave", Hearth_OnLeave)
-
 		local proName
 		local prof1, prof2, archaeology, _, cooking, firstAid = GetProfessions();

@@ -376,11 +367,6 @@ do
 			end
 		end

-		local breakStuffButton = CreateFrame("Button", "BreakStuffButton", SuperVillain.UIParent)
-		breakStuffButton:Size(size, size)
-		AddMacroTool(breakStuffButton)
-		breakStuffButton:Hide()
-
 		MOD.ToolBarLoaded = true
 	end
 end
\ No newline at end of file
diff --git a/Interface/AddOns/SVUI/packages/unit/SVUnit.lua b/Interface/AddOns/SVUI/packages/unit/SVUnit.lua
index b748f9b..c05363c 100644
--- a/Interface/AddOns/SVUI/packages/unit/SVUnit.lua
+++ b/Interface/AddOns/SVUI/packages/unit/SVUnit.lua
@@ -264,7 +264,30 @@ function MOD:RefreshUnitFrames()
 		oUF_SuperVillain:DisableBlizzard('party')
 	end

-	-- self:SetFadeManager()
+	collectgarbage("collect")
+end
+
+function MOD:RefreshAllUnitMedia()
+	if(not self.db or (self.db and self.db.enable ~= true)) then return end
+	self:RefreshUnitColors()
+	-- [[ FRAMES ]] --
+	for unit in pairs(BasicFrames)do
+		if self.db[unit].enable then
+			self:RefreshUnitMedia(self[unit], false)
+		end
+	end
+
+	for unit,group in pairs(ExtraFrames)do
+		if self.db[group].enable then
+			self:RefreshUnitMedia(self[unit], false)
+		end
+	end
+
+	for group,_ in pairs(GroupFrames) do
+		MOD:SetGroupFrame(group)
+	end
+
+	collectgarbage("collect")
 end

 do
@@ -644,7 +667,7 @@ do

 			if db.gCount then
 				self[group] = CreateFrame("Frame", "SVUI_"..realName, SVUI_UnitFrameParent, "SecureHandlerStateTemplate")
-				self[group].subunits = {} --<<
+				self[group].subunits = {}
 				self[group].NameKey = group;
 				self[group].SetConfigEnvironment = GroupSetConfigEnvironment
 				self[group].Update = GroupUpdate
@@ -661,7 +684,7 @@ do
 		if db.gCount then
 			local xname = self[group].NameKey
 			realName = xname:gsub("(.)", upper, 1)
-			if(db.enable  ~= true and group  ~= "raidpet") then
+			if(db.enable ~= true and group ~= "raidpet") then
 				UnregisterStateDriver(self[group], "visibility")
 				self[group]:Hide()
 				return
diff --git a/Interface/AddOns/SVUI/packages/unit/class/druid.lua b/Interface/AddOns/SVUI/packages/unit/class/druid.lua
index 8f1b4ad..44c2cdb 100644
--- a/Interface/AddOns/SVUI/packages/unit/class/druid.lua
+++ b/Interface/AddOns/SVUI/packages/unit/class/druid.lua
@@ -42,6 +42,7 @@ local oUF_SuperVillain = ns.oUF
 --[[ MUNGLUNCH's FASTER ASSERT FUNCTION ]]--
 local assert = enforce;
 assert(oUF_SuperVillain, "SVUI was unable to locate oUF.")
+local LSM = LibStub("LibSharedMedia-3.0")
 --[[
 ##########################################################
 DRUID ALT MANA
@@ -234,10 +235,10 @@ function MOD:CreateDruidResourceBar(playerFrame)

 	bar.SolarBar = solar;

-	bar.Text = lunar:CreateFontString(nil, 'OVERLAY', nil, 2)
+	bar.Text = lunar:CreateFontString(nil, 'OVERLAY')
 	bar.Text:SetPoint("TOPLEFT", bar, "TOPLEFT", 10, 0)
 	bar.Text:SetPoint("BOTTOMRIGHT", bar, "BOTTOMRIGHT", -10, 0)
-	bar.Text:SetFontTemplate(SuperVillain.Media.font.roboto, 16, "NONE")
+	bar.Text:SetFont(SuperVillain.Media.font.roboto, 16, "NONE")
 	bar.Text:SetShadowOffset(0,0)

 	local hyper = CreateFrame("Frame",nil,playerFrame)
@@ -251,7 +252,7 @@ function MOD:CreateDruidResourceBar(playerFrame)

 	points.Text = points:CreateFontString(nil,'OVERLAY')
 	points.Text:SetAllPoints(points)
-	points.Text:SetFontTemplate([[Interface\AddOns\SVUI\assets\fonts\Combo.ttf]],26,'OUTLINE')
+	points.Text:SetFont([[Interface\AddOns\SVUI\assets\fonts\Combo.ttf]], 26, 'OUTLINE')
 	points.Text:SetTextColor(1,1,1)

 	playerFrame.HyperCombo = hyper;
diff --git a/Interface/AddOns/SVUI/packages/unit/common/media.lua b/Interface/AddOns/SVUI/packages/unit/common/media.lua
index abcf609..3d2f9c3 100644
--- a/Interface/AddOns/SVUI/packages/unit/common/media.lua
+++ b/Interface/AddOns/SVUI/packages/unit/common/media.lua
@@ -101,15 +101,12 @@ function MOD:RefreshUnitColors()
 	oUF_SuperVillain.colors.smooth = {1, 0, 0, 1, 1, 0, r, g, b}
 end

-local unitRoster = {"player", "target", "targettarget", "pet", "pettarget", "focus", "focustarget", "party", "raidpet", "assist", "tank", "raid10", "raid25", "raid40", "boss", "arena"};
-
-function MOD:RefreshUnitMedia(unitName, updateUpvalues)
-	if(not self.db or (self.db and self.db.enable ~= true)) then return end
+function MOD:RefreshUnitMedia(frame, updateUpvalues)
+	if(not frame or not self.db or (self.db and self.db.enable ~= true)) then return end
 	if((not INIT_UPDATE) or updateUpvalues == true) then UpdateUnitMediaLocals() end
 	local db = self.db
-	local unitDB = db[unitName]
-	if(self[unitName] and unitDB and unitDB.enable) then
-		local frame = self[unitName]
+	local unitDB = frame.db
+	if(unitDB and unitDB.enable) then
 		local panel = frame.InfoPanel
 		if(panel) then
 			if(panel.Name and unitDB.name) then
@@ -148,15 +145,4 @@ function MOD:RefreshUnitMedia(unitName, updateUpvalues)
 			debuffs.textOutline = CURRENT_AURABAR_FONTOUTLINE
 		end
 	end
-end
-
-function MOD:RefreshAllUnitMedia()
-	if(not self.db or (self.db and self.db.enable ~= true)) then return end
-	UpdateUnitMediaLocals()
-	-- [[ COLORS ]] --
-	self:RefreshUnitColors()
-	-- [[ FRAMES ]] --
-	for i = 1, 16 do
-		self:RefreshUnitMedia(unitRoster[i], false)
-	end
 end
\ No newline at end of file
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/basic/focus.lua b/Interface/AddOns/SVUI/packages/unit/frames/basic/focus.lua
index 3a9d2ca..4438cb0 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/basic/focus.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/basic/focus.lua
@@ -61,7 +61,7 @@ function MOD.FrameUpdate:focus(unit, frame, db)
 	frame.db = db;
 	local UNIT_WIDTH = db.width;
 	local UNIT_HEIGHT = db.height;
-	MOD:RefreshUnitMedia("focus")
+	MOD:RefreshUnitMedia(frame)
 	frame.unit = unit;
 	frame:RegisterForClicks(MOD.db.fastClickTarget and "AnyDown" or "AnyUp")
 	frame.colors = oUF_SuperVillain.colors;
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/basic/ft.lua b/Interface/AddOns/SVUI/packages/unit/frames/basic/ft.lua
index 6a18eeb..afec53c 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/basic/ft.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/basic/ft.lua
@@ -46,7 +46,7 @@ function MOD.FrameUpdate:focustarget(unit, frame, db)
 	frame.db = db;
 	local UNIT_WIDTH = db.width;
 	local UNIT_HEIGHT = db.height;
-	MOD:RefreshUnitMedia("focustarget")
+	MOD:RefreshUnitMedia(frame)
 	frame.unit = unit;
 	frame:RegisterForClicks(MOD.db.fastClickTarget and "AnyDown" or "AnyUp")
 	frame.colors = oUF_SuperVillain.colors;
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/basic/pet.lua b/Interface/AddOns/SVUI/packages/unit/frames/basic/pet.lua
index 1cd5bca..0d8ef7b 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/basic/pet.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/basic/pet.lua
@@ -52,7 +52,7 @@ function MOD.FrameUpdate:pet(unit, frame, db)
 	frame.db = db;
 	local UNIT_WIDTH = db.width;
 	local UNIT_HEIGHT = db.height;
-	MOD:RefreshUnitMedia("pet")
+	MOD:RefreshUnitMedia(frame)
 	frame.unit = unit;
 	frame:RegisterForClicks(MOD.db.fastClickTarget and "AnyDown" or "AnyUp")
 	frame.colors = oUF_SuperVillain.colors;
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/basic/player.lua b/Interface/AddOns/SVUI/packages/unit/frames/basic/player.lua
index 28cff0b..9f63383 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/basic/player.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/basic/player.lua
@@ -65,7 +65,7 @@ function MOD.FrameUpdate:player(unit, frame, db)
 	local classBarWidth = db.width * 0.4;
 	local healthPanel = frame.HealthPanel
 	local iconDB = db.icons
-	MOD:RefreshUnitMedia("player")
+	MOD:RefreshUnitMedia(frame)
 	frame.unit = unit
 	frame:RegisterForClicks(MOD.db.fastClickTarget and "AnyDown" or "AnyUp")
 	frame.colors = oUF_SuperVillain.colors;
@@ -117,7 +117,7 @@ function MOD.FrameUpdate:player(unit, frame, db)
 	end
 	do
 		local power = frame.Power;
-		if frame.DruidAltMana then
+		if SuperVillain.class == "DRUID" and frame.DruidAltMana then
 			if db.power.druidMana then
 				frame:EnableElement("DruidAltMana")
 			else
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/basic/pt.lua b/Interface/AddOns/SVUI/packages/unit/frames/basic/pt.lua
index 2ad61e5..9d2197c 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/basic/pt.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/basic/pt.lua
@@ -45,7 +45,7 @@ function MOD.FrameUpdate:pettarget(unit, frame, db)
 	frame.db = db;
 	local UNIT_WIDTH = db.width;
 	local UNIT_HEIGHT = db.height;
-	MOD:RefreshUnitMedia("pettarget")
+	MOD:RefreshUnitMedia(frame)
 	frame.unit = unit;
 	frame:RegisterForClicks(MOD.db.fastClickTarget and "AnyDown" or "AnyUp")
 	frame.colors = oUF_SuperVillain.colors;
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/basic/target.lua b/Interface/AddOns/SVUI/packages/unit/frames/basic/target.lua
index 35d1682..0c2bfcd 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/basic/target.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/basic/target.lua
@@ -73,7 +73,7 @@ function MOD.FrameUpdate:target(unit, frame, db)
 	local UNIT_HEIGHT = db.height;
 	local USE_COMBOBAR = db.combobar.enable;
 	local comboBarHeight = db.combobar.height;
-	MOD:RefreshUnitMedia("target")
+	MOD:RefreshUnitMedia(frame)
 	frame.unit = unit;
 	frame:RegisterForClicks(MOD.db.fastClickTarget and "AnyDown" or "AnyUp")
 	frame.colors = oUF_SuperVillain.colors;
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/basic/tot.lua b/Interface/AddOns/SVUI/packages/unit/frames/basic/tot.lua
index 7c6bb92..c15183d 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/basic/tot.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/basic/tot.lua
@@ -47,7 +47,7 @@ function MOD.FrameUpdate:targettarget(unit, frame, db)
 	frame.db = db;
 	local UNIT_WIDTH = db.width;
 	local UNIT_HEIGHT = db.height;
-	MOD:RefreshUnitMedia("targettarget")
+	MOD:RefreshUnitMedia(frame)
 	frame.unit = unit;
 	frame:RegisterForClicks(MOD.db.fastClickTarget and "AnyDown" or "AnyUp")
 	frame.colors = oUF_SuperVillain.colors;
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/extra/arena.lua b/Interface/AddOns/SVUI/packages/unit/frames/extra/arena.lua
index 405e995..9a8108f 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/extra/arena.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/extra/arena.lua
@@ -114,7 +114,7 @@ function MOD.FrameUpdate:arena(unit, frame, db)
 	local holder = _G["SVUI_Arena_MOVE"]
 	local UNIT_WIDTH = db.width;
 	local UNIT_HEIGHT = db.height;
-	MOD:RefreshUnitMedia("arena")
+	MOD:RefreshUnitMedia(frame)
 	frame.unit = unit
 	frame.colors = oUF_SuperVillain.colors;
 	frame:Size(UNIT_WIDTH, UNIT_HEIGHT)
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/extra/boss.lua b/Interface/AddOns/SVUI/packages/unit/frames/extra/boss.lua
index 1238d06..a77f346 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/extra/boss.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/extra/boss.lua
@@ -61,7 +61,7 @@ function MOD.FrameUpdate:boss(unit, frame, db)
 	local holder = _G["SVUI_Boss_MOVE"]
 	local UNIT_WIDTH = db.width;
 	local UNIT_HEIGHT = db.height;
-	MOD:RefreshUnitMedia("boss")
+	MOD:RefreshUnitMedia(frame)
 	frame.unit = unit;
 	frame.colors = oUF_SuperVillain.colors;
 	frame:Size(UNIT_WIDTH, UNIT_HEIGHT)
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/group/assist.lua b/Interface/AddOns/SVUI/packages/unit/frames/group/assist.lua
index 2db3cfd..f8bd478 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/group/assist.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/group/assist.lua
@@ -70,7 +70,7 @@ function MOD.HeaderUpdate:assist(frame, db)
 end

 function MOD.FrameUpdate:assist(frame, db)
-	MOD:RefreshUnitMedia("assist")
+	MOD:RefreshUnitMedia(frame)
 	frame.colors = oUF_SuperVillain.colors;
 	frame:RegisterForClicks(MOD.db.fastClickTarget and "AnyDown" or "AnyUp")
 	if frame.isChild and frame.originalParent then
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/group/party.lua b/Interface/AddOns/SVUI/packages/unit/frames/group/party.lua
index 4ca6c76..ffb7156 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/group/party.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/group/party.lua
@@ -152,7 +152,7 @@ end

 function MOD.FrameUpdate:party(frame,db)
 	frame.db = db;
-	MOD:RefreshUnitMedia("party")
+	MOD:RefreshUnitMedia(frame)
 	frame.colors = oUF_SuperVillain.colors;
 	frame:RegisterForClicks(MOD.db.fastClickTarget and 'AnyDown' or 'AnyUp')
 	if frame.isChild then
@@ -191,7 +191,9 @@ function MOD.FrameUpdate:party(frame,db)
 			frame:Tag(nametext, altDB.tags)
 		end
 	else
-		if not InCombatLockdown()then frame:Size(db.width,db.height) end
+		if not InCombatLockdown() then
+			frame:Size(db.width,db.height)
+		end
 		MOD:RefreshUnitLayout(frame,"party")
 		MOD:UpdateAuraWatch(frame)
 	end
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/group/raid.lua b/Interface/AddOns/SVUI/packages/unit/frames/group/raid.lua
index a6aab8d..7bdc0c0 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/group/raid.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/group/raid.lua
@@ -139,7 +139,7 @@ for i = 10, 40, 15 do

     MOD.FrameUpdate[raidGroupName] = function(_, frame, db)
         frame.db = db;
-        MOD:RefreshUnitMedia(raidGroupName)
+        MOD:RefreshUnitMedia(frame)
         local rdSize = MOD.db.auraFontSize;
         local rdFont = LSM:Fetch("font", MOD.db.auraFont)
         frame.colors = oUF_SuperVillain.colors;
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/group/rpet.lua b/Interface/AddOns/SVUI/packages/unit/frames/group/rpet.lua
index 7e88807..9f6e9da 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/group/rpet.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/group/rpet.lua
@@ -147,7 +147,7 @@ end

 function MOD.FrameUpdate:raidpet(frame, db)
 	frame.db = db;
-	MOD:RefreshUnitMedia("raidpet")
+	MOD:RefreshUnitMedia(frame)
     frame.colors = oUF_SuperVillain.colors;
     frame:RegisterForClicks(MOD.db.fastClickTarget and"AnyDown"or"AnyUp")
     if not InCombatLockdown()then frame:Size(db.width, db.height)end
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/group/tank.lua b/Interface/AddOns/SVUI/packages/unit/frames/group/tank.lua
index eafc40e..9118746 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/group/tank.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/group/tank.lua
@@ -70,7 +70,7 @@ function MOD.HeaderUpdate:tank(frame, db)
 end

 function MOD.FrameUpdate:tank(frame, db)
-	MOD:RefreshUnitMedia("tank")
+	MOD:RefreshUnitMedia(frame)
 	frame.colors = oUF_SuperVillain.colors;
 	frame:RegisterForClicks(MOD.db.fastClickTarget and"AnyDown"or"AnyUp")
 	if frame.isChild and frame.originalParent then
diff --git a/Interface/AddOns/SVUI/system/alerts.lua b/Interface/AddOns/SVUI/system/alerts.lua
index a01ce5f..aaccb57 100644
--- a/Interface/AddOns/SVUI/system/alerts.lua
+++ b/Interface/AddOns/SVUI/system/alerts.lua
@@ -182,6 +182,14 @@ SuperVillain.SystemAlert["RESET_PROFILE_PROMPT"] = {
 		SuperVillain.db:Reset()
 	end
 };
+SuperVillain.SystemAlert["COPY_PROFILE_PROMPT"] = {
+	text = L["Are you sure you want to copy all settings from this profile?"],
+	button1 = YES,
+	button2 = NO,
+	timeout = 0,
+	hideOnEscape = 1,
+	OnAccept = function() end
+};
 SuperVillain.SystemAlert["BAR6_CONFIRMATION"] = {
 	text = L["Enabling / Disabling Bar #6 will toggle a paging option from your main actionbar to prevent duplicating bars, are you sure you want to do this?"],
 	button1 = YES,
diff --git a/Interface/AddOns/SVUI/system/classes/Database.lua b/Interface/AddOns/SVUI/system/classes/Database.lua
index 04a583c..8a59bc7 100644
--- a/Interface/AddOns/SVUI/system/classes/Database.lua
+++ b/Interface/AddOns/SVUI/system/classes/Database.lua
@@ -3396,7 +3396,6 @@ local function resetprofile(t)
 			sv[k] = nil
 		end
 	end
-	tablecopy(sv, src)
 	ReloadUI()
 end

@@ -3411,9 +3410,15 @@ local function importprofile(t, key)
 			sv[k] = nil
 		end
 	end
-	importdata(src, sv)
+	tablecopy(sv, src)
 	sv.copyKey = key
-	SuperVillain:RefreshEverything()
+	ReloadUI()
+end
+
+local function importprompt(t, key)
+	SuperVillain.SystemAlert["COPY_PROFILE_PROMPT"].text = L["Are you sure you want to copy the profile '" .. key .. "'?"]
+	SuperVillain.SystemAlert["COPY_PROFILE_PROMPT"].OnAccept = function() importprofile(t, key) end
+	SuperVillain:StaticPopup_Show("COPY_PROFILE_PROMPT")
 end

 local function exportprofile(t, key)
@@ -3485,7 +3490,7 @@ local METAPROFILE = function(sv)
 	db.Reset 		= resetprofile
 	db.SetDefault 	= setdefaults
 	db.GetDefault 	= getdefaults
-	db.Import 		= importprofile
+	db.Import 		= importprompt
 	db.Export 		= exportprofile
 	db.Remove 		= removeprofile

diff --git a/Interface/AddOns/SVUI/system/installer.lua b/Interface/AddOns/SVUI/system/installer.lua
index 6f2ee88..40c86b6 100644
--- a/Interface/AddOns/SVUI/system/installer.lua
+++ b/Interface/AddOns/SVUI/system/installer.lua
@@ -88,15 +88,15 @@ local function BarShuffle()
 	local sph = (400 - b2h);
 	if not SuperVillain.db.framelocations then SuperVillain.db.framelocations = {} end
 	SuperVillain.db.framelocations.SVUI_SpecialAbility_MOVE = "BOTTOMSVUIParentBOTTOM0"..sph;
-	SuperVillain.db.framelocations.SVUI_ActionBar2_MOVE = "BOTTOMSVUI_ActionBar1TOP0-1";
-	SuperVillain.db.framelocations.SVUI_ActionBar3_MOVE = "BOTTOMRIGHTSVUI_ActionBar1BOTTOMLEFT-40";
-	SuperVillain.db.framelocations.SVUI_ActionBar5_MOVE = "BOTTOMLEFTSVUI_ActionBar1BOTTOMRIGHT40";
+	SuperVillain.db.framelocations.SVUI_ActionBar2_MOVE = "BOTTOMSVUI_ActionBar1TOP04";
+	SuperVillain.db.framelocations.SVUI_ActionBar3_MOVE = "BOTTOMLEFTSVUI_ActionBar1BOTTOMRIGHT40";
+	SuperVillain.db.framelocations.SVUI_ActionBar5_MOVE = "BOTTOMRIGHTSVUI_ActionBar1BOTTOMLEFT-40";
 	if bar2 then
-		SuperVillain.db.framelocations.SVUI_PetActionBar_MOVE = "BOTTOMLEFTSVUI_ActionBar2TOPLEFT02"
-		SuperVillain.db.framelocations.SVUI_StanceBar_MOVE = "BOTTOMRIGHTSVUI_ActionBar2TOPRIGHT02";
+		SuperVillain.db.framelocations.SVUI_PetActionBar_MOVE = "BOTTOMLEFTSVUI_ActionBar2TOPLEFT04"
+		SuperVillain.db.framelocations.SVUI_StanceBar_MOVE = "BOTTOMRIGHTSVUI_ActionBar2TOPRIGHT04";
 	else
-		SuperVillain.db.framelocations.SVUI_PetActionBar_MOVE = "BOTTOMLEFTSVUI_ActionBar1TOPLEFT02"
-		SuperVillain.db.framelocations.SVUI_StanceBar_MOVE = "BOTTOMRIGHTSVUI_ActionBar1TOPRIGHT02";
+		SuperVillain.db.framelocations.SVUI_PetActionBar_MOVE = "BOTTOMLEFTSVUI_ActionBar1TOPLEFT04"
+		SuperVillain.db.framelocations.SVUI_StanceBar_MOVE = "BOTTOMRIGHTSVUI_ActionBar1TOPRIGHT04";
 	end
 end;

diff --git a/Interface/AddOns/SVUI/system/presets.lua b/Interface/AddOns/SVUI/system/presets.lua
index 190b696..9defbdf 100644
--- a/Interface/AddOns/SVUI/system/presets.lua
+++ b/Interface/AddOns/SVUI/system/presets.lua
@@ -440,8 +440,8 @@ local presets = {
 		["link"] = "SVUnit",
 		["default"] = {
 			["player"] = {
-				width = 235,
-				height = 70,
+				width = 215,
+				height = 60,
 				portrait = {
 					enable = true,
 					overlay = true,
@@ -449,8 +449,8 @@ local presets = {
 				}
 			},
 			["target"] = {
-				width = 235,
-				height = 70,
+				width = 215,
+				height = 60,
 				portrait = {
 					enable = true,
 					overlay = true,
@@ -529,7 +529,7 @@ local presets = {
 		},
 		["super"] = {
 			["player"] = {
-				width = 235,
+				width = 215,
 				height = 70,
 				portrait = {
 					enable = true,
@@ -538,7 +538,7 @@ local presets = {
 				}
 			},
 			["target"] = {
-				width = 235,
+				width = 215,
 				height = 70,
 				portrait = {
 					enable = true,
@@ -618,21 +618,23 @@ local presets = {
 		},
 		["simple"] = {
 			["player"] = {
-				width = 235,
-				height = 70,
+				width = 215,
+				height = 60,
 				portrait = {
 					enable = true,
 					overlay = false,
 					style = "2D",
+					width = 60,
 				}
 			},
 			["target"] = {
-				width = 235,
-				height = 70,
+				width = 215,
+				height = 60,
 				portrait = {
 					enable = true,
 					overlay = false,
 					style = "2D",
+					width = 60,
 				}
 			},
 			["pet"] = {
@@ -642,6 +644,7 @@ local presets = {
 					enable = true,
 					overlay = false,
 					style = "2D",
+					width = 30,
 				},
 				name = {
 					position = "INNERLEFT"
@@ -654,6 +657,7 @@ local presets = {
 					enable = true,
 					overlay = false,
 					style = "2D",
+					width = 30,
 				},
 				name = {
 					position = "INNERLEFT"
@@ -666,6 +670,7 @@ local presets = {
 					enable = true,
 					overlay = false,
 					style = "2D",
+					width = 45,
 				}
 			},
 			["party"] = {
@@ -678,6 +683,7 @@ local presets = {
 					enable = true,
 					overlay = false,
 					style = "2D",
+					width = 35,
 				},
 				name = {
 					position = "INNERRIGHT"
@@ -707,14 +713,14 @@ local presets = {
 		},
 		["compact"] = {
 			["player"] = {
-				width = 235,
+				width = 215,
 				height = 50,
 				portrait = {
 					enable = false
 				}
 			},
 			["target"] = {
-				width = 235,
+				width = 215,
 				height = 50,
 				portrait = {
 					enable = false
diff --git a/Interface/AddOns/SVUI/system/system.lua b/Interface/AddOns/SVUI/system/system.lua
index 75b3223..c72ebab 100644
--- a/Interface/AddOns/SVUI/system/system.lua
+++ b/Interface/AddOns/SVUI/system/system.lua
@@ -385,9 +385,9 @@ local function FullLoad(self)
 	self:SetSVMovablesPositions();
 	self.CoreEnabled = true;

-	if (SVUI_Profile.SAFEDATA.install_complete == nil or not SVUI_Profile.install_version or tonumber(SVUI_Profile.install_version) < 4.04) then
+	if (SVUI_Profile.SAFEDATA.install_complete == nil or not SVUI_Profile.SAFEDATA.install_version or tonumber(SVUI_Profile.SAFEDATA.install_version) < 4.04) then
 		self:Install()
-		SVUI_Profile.install_version = self.version
+		SVUI_Profile.SAFEDATA.install_version = self.version
 	end

 	self:RefreshAllSystemMedia();
diff --git a/Interface/AddOns/SVUI_ConfigOMatic/modules/units/core.lua b/Interface/AddOns/SVUI_ConfigOMatic/modules/units/core.lua
index 84ef4fb..90f0d6d 100644
--- a/Interface/AddOns/SVUI_ConfigOMatic/modules/units/core.lua
+++ b/Interface/AddOns/SVUI_ConfigOMatic/modules/units/core.lua
@@ -808,7 +808,7 @@ function ns:SetNameConfigGroup(updateFunction, unitName, count)
 				name = L["Fonts"],
 				set = function(key, value)
 					MOD:ChangeDBVar(value, key[#key], unitName, "name");
-					MOD:RefreshUnitMedia(unitName, true)
+					MOD:RefreshAllUnitMedia()
 				end,
 				args = {
 					font = {