Quantcast

fixed texture and color customization options

Steven Jackson [07-28-15 - 01:04]
fixed texture and color customization options
Filename
SVUI_!Core/system/media.lua
SVUI_!Core/xml/styles.xml
SVUI_Skins/components/blizzard/garrison.lua
SVUI_Skins/components/blizzard/worldmap.lua
SVUI_UnitFrames/SVUI_UnitFrames.lua
SVUI_UnitFrames/assets/UNIT-DEAD.blp
SVUI_UnitFrames/assets/UNIT-TAPPED.blp
SVUI_UnitFrames/elements/essentials.lua
SVUI_UnitFrames/libs/Plugins/oUF_ActionPanel/oUF_ActionPanel.lua
diff --git a/SVUI_!Core/system/media.lua b/SVUI_!Core/system/media.lua
index 2cdb9ab..f437e57 100644
--- a/SVUI_!Core/system/media.lua
+++ b/SVUI_!Core/system/media.lua
@@ -203,39 +203,6 @@ do
 				["unitlarge"]   = {file = "SVUI Border 2",  		size = 0},
 				["unitsmall"]   = {file = "SVUI Border 2",  		size = 0},
 			},
-			-- ["color"] = {
-			-- 	["default"]     = {r = 0.2,  g = 0.2,  b = 0.2,  a = 1},
-			-- 	["button"]      = {r = 0.2,  g = 0.2,  b = 0.2,  a = 1},
-			-- 	["special"]     = {r = 0.37, g = 0.32, b = 0.29, a = 1},
-			-- 	["specialdark"] = {r = 0.23, g = 0.22, b = 0.21, a = 1},
-			-- 	["unique"]      = {r = 0.32, g = 0.26, b = 0.21, a = 1},
-			-- 	["container"]   = {r = 0.28, g = 0.27, b = 0.26, a = 1},
-			-- 	["class"]       = {r = r1,   g = g1,   b = b1,   a = 1},
-			-- 	["bizzaro"]     = {r = ir1,  g = ig1,  b = ib1,  a = 1},
-			-- 	["medium"]      = {r = 0.47, g = 0.47, b = 0.47, a = 1},
-			-- 	["dark"]        = {r = 0.1,  g = 0.1,  b = 0.1,  a = 1},
-			-- 	["darkest"]     = {r = 0,    g = 0, 0, b = 1,    a = 1},
-			-- 	["light"]       = {r = 0.95, g = 0.95, b = 0.95, a = 1},
-			-- 	["light2"]      = {r = 0.65, g = 0.65, b = 0.65, a = 1},
-			-- 	["lightgrey"]   = {r = 0.32, g = 0.35, b = 0.38, a = 1},
-			-- 	["highlight"]   = {r = 0.28, g = 0.75, b = 1,    a = 1},
-			-- 	["checked"]     = {r = 0.25, g = 0.9,  b = 0.08, a = 1},
-			-- 	["green"]       = {r = 0.25, g = 0.9,  b = 0.08, a = 1},
-			-- 	["blue"]        = {r = 0.08, g = 0.25, b = 0.82, a = 1},
-			-- 	["tan"]         = {r = 0.4,  g = 0.32, b = 0.23, a = 1},
-			-- 	["red"]         = {r = 0.9,  g = 0.08, b = 0.08, a = 1},
-			-- 	["yellow"]      = {r = 1,    g = 1,    b = 0,    a = 1},
-			-- 	["gold"]        = {r = 1,    g = 0.68, b = 0.1,  a = 1},
-			-- 	["transparent"] = {r = 0,    g = 0,    b = 0,    a = 0.5},
-			-- 	["hinted"]      = {r = 0,    g = 0,    b = 0,    a = 0.35},
-			-- 	["invisible"]   = {r = 0,    g = 0,    b = 0,    a = 0},
-			-- 	["white"]       = {r = 1,    g = 1,    b = 1,    a = 1},
-			-- },
-			-- ["bordercolor"] = {
-			-- 	["default"]     = {r = 0,    g = 0,    b = 0,    a = 1},
-			-- 	["class"]       = {r = r1,   g = g1,   b = b1,   a = 1},
-			-- 	["checkbox"]    = {r = 0.1,  g = 0.1,  b = 0.1,  a = 1},
-			-- },
 		},
 		["font"] = {
 			["default"]   	= [[Interface\AddOns\SVUI_!Core\assets\fonts\Default.ttf]],
@@ -290,7 +257,8 @@ do
 			["special"]     = {0.37, 0.32, 0.29, 1},
 			["specialdark"] = {.23, .22, .21, 1},
 			["unique"]      = {0.32, 0.258, 0.21, 1},
-			["dusty"]   		= {.28, .27, .26, 1},
+			["paper"]     	= {0.37, 0.32, 0.29, 1},
+			["dusty"]   	= {.28, .27, .26, 1},
 			["class"]       = {r1, g1, b1, 1},
 			["bizzaro"]     = {ir1, ig1, ib1, 1},
 			["medium"]      = {0.47, 0.47, 0.47},
@@ -322,6 +290,7 @@ do
 			["secondary"]  	= {"VERTICAL", 0.08, 0.08, 0.08, 0.22, 0.22, 0.22},
 			["special"]   	= {"VERTICAL", 0.33, 0.25, 0.13, 0.47, 0.39, 0.27},
 			["specialdark"] = {"VERTICAL", 0.23, 0.15, 0.03, 0.33, 0.25, 0.13},
+			["paper"]   	= {"VERTICAL", 0.33, 0.25, 0.13, 0.47, 0.39, 0.27},
 			["dusty"] 		= {"VERTICAL", 0.12, 0.11, 0.1, 0.22, 0.21, 0.2},
 			["class"]     	= {"VERTICAL", r2, g2, b2, r1, g1, b1},
 			["bizzaro"]   	= {"VERTICAL", ir2, ig2, ib2, ir1, ig1, ib1},
@@ -1143,6 +1112,7 @@ function SV:UpdateSharedMedia()

 	local special = self.media.color.special
 	self.media.gradient.special = {"VERTICAL", special[1], special[2], special[3], r1, g1, b1}
+	self.media.color.special = {r1*.5, g1*.5, b1*.5, 1}
 	-- self.media.gradient.special = {"VERTICAL", special[1]*.25, special[2]*.25, special[3]*.25, special[1], special[2], special[3]}
 	-- self.media.gradient.special = {"VERTICAL",special[1], special[2], special[3], default[1], default[2], default[3]}

diff --git a/SVUI_!Core/xml/styles.xml b/SVUI_!Core/xml/styles.xml
index 3d2b1eb..2ba52b3 100644
--- a/SVUI_!Core/xml/styles.xml
+++ b/SVUI_!Core/xml/styles.xml
@@ -300,9 +300,9 @@
         <Attributes>
             <Attribute name="panelID" type="string" value="paper" />
             <Attribute name="panelPadding" type="number" value="3" />
-            <Attribute name="panelColor" type="string" value="white" />
-            <Attribute name="panelGradient" type="string" value="white" />
-            <Attribute name="panelTexUpdate" type="boolean" value="true" />
+            <Attribute name="panelColor" type="string" value="paper" />
+            <Attribute name="panelGradient" type="string" value="paper" />
+            <Attribute name="panelTexUpdate" type="boolean" value="false" />
             <Attribute name="panelSkipUpdate" type="boolean" value="true" />
         </Attributes>
         <Backdrop bgFile="Interface\AddOns\SVUI_!Core\assets\backgrounds\pattern\PATTERN6" edgeFile="Interface\BUTTONS\WHITE8X8" tile="false">
diff --git a/SVUI_Skins/components/blizzard/garrison.lua b/SVUI_Skins/components/blizzard/garrison.lua
index b619599..129c483 100644
--- a/SVUI_Skins/components/blizzard/garrison.lua
+++ b/SVUI_Skins/components/blizzard/garrison.lua
@@ -403,7 +403,6 @@ local function LoadGarrisonStyle()
 	bgFrameTop:SetPoint("TOPLEFT", GarrisonLandingPage.Report, "TOPLEFT", 38, -91)
 	bgFrameTop:SetPoint("BOTTOMRIGHT", GarrisonLandingPage.Report.List, "BOTTOMLEFT", -4, 0)
 	bgFrameTop:SetStyle("Frame", "Paper")
-	bgFrameTop:SetPanelColor("special")

 	GarrisonLandingPageReportList:RemoveTextures()
 	GarrisonLandingPageReportList:SetStyle("Frame", 'Inset', false, 4, 0, 0)
diff --git a/SVUI_Skins/components/blizzard/worldmap.lua b/SVUI_Skins/components/blizzard/worldmap.lua
index 21944fc..65ee78b 100644
--- a/SVUI_Skins/components/blizzard/worldmap.lua
+++ b/SVUI_Skins/components/blizzard/worldmap.lua
@@ -86,8 +86,7 @@ local function StripQuestMapFrame()
   SV.API:Set("ScrollBar", QuestMapDetailsScrollFrameScrollBar)
   SV.API:Set("Skin", QuestMapFrame.DetailsFrame.RewardsFrame, 0, -10, 0, 0)

-  QuestScrollFrame:SetStyle("!_Frame", "Paper")
-  QuestScrollFrame:SetPanelColor("special")
+  QuestScrollFrame:SetStyle("Frame", "Paper")

   QuestScrollFrame.ViewAll:SetStyle("Button")

diff --git a/SVUI_UnitFrames/SVUI_UnitFrames.lua b/SVUI_UnitFrames/SVUI_UnitFrames.lua
index 06417ce..a99a1f3 100644
--- a/SVUI_UnitFrames/SVUI_UnitFrames.lua
+++ b/SVUI_UnitFrames/SVUI_UnitFrames.lua
@@ -469,15 +469,7 @@ function MOD:RefreshUnitLayout(frame, template)
 	MASTER_GRIP:ClearAllPoints();
 	MASTER_GRIP:SetPoint(TOP_ANCHOR2, frame, TOP_ANCHOR2, ((MASTER_X1_OFFSET + PORTRAIT_WIDTH) * TOP_MODIFIER), MASTER_TOP_OFFSET);
 	MASTER_GRIP:SetPoint(BOTTOM_ANCHOR2, frame, BOTTOM_ANCHOR2, (MASTER_X2_OFFSET * BOTTOM_MODIFIER), MASTER_BOTTOM_OFFSET);
-
-	if(frame.StatusPanel) then
-		if(template ~= "player" and template ~= "pet" and template ~= "target" and template ~= "targettarget" and template ~= "focus" and template ~= "focustarget") then
-			local size = MASTER_GRIP:GetHeight()
-			frame.StatusPanel:SetSize(size, size)
-			frame.StatusPanel:SetPoint("CENTER", MASTER_GRIP, "CENTER", 0, 0)
-		end
-		self:UpdateStatusMedia(frame)
-	end
+	self:UpdateStatusMedia(frame)

 	if(frame.InfoPanelBG) then
 		if(SV.db.UnitFrames.infoBackgrounds) then
diff --git a/SVUI_UnitFrames/assets/UNIT-DEAD.blp b/SVUI_UnitFrames/assets/UNIT-DEAD.blp
index 58db1a5..fb712a6 100644
Binary files a/SVUI_UnitFrames/assets/UNIT-DEAD.blp and b/SVUI_UnitFrames/assets/UNIT-DEAD.blp differ
diff --git a/SVUI_UnitFrames/assets/UNIT-TAPPED.blp b/SVUI_UnitFrames/assets/UNIT-TAPPED.blp
index c250880..d2654b0 100644
Binary files a/SVUI_UnitFrames/assets/UNIT-TAPPED.blp and b/SVUI_UnitFrames/assets/UNIT-TAPPED.blp differ
diff --git a/SVUI_UnitFrames/elements/essentials.lua b/SVUI_UnitFrames/elements/essentials.lua
index ff9dde1..2697a66 100644
--- a/SVUI_UnitFrames/elements/essentials.lua
+++ b/SVUI_UnitFrames/elements/essentials.lua
@@ -429,30 +429,37 @@ function MOD:SetActionPanel(frame, unit, noHealthText, noPowerText, noMiscText)
 		}
 	end

+	frame.StatusPanel:SetFrameStrata("LOW")
+	frame.StatusPanel:SetFrameLevel(32)
 	frame.StatusPanel.texture = frame.StatusPanel:CreateTexture(nil, "OVERLAY")
 	frame.StatusPanel.texture:SetAllPoints()
-	frame.StatusPanel:SetFrameStrata("LOW")
-	frame.StatusPanel:SetFrameLevel(28)
 	if(ThreatMapping[unit]) then
 		frame.Threat = CreateThreat(frame, unit)
 	end
 end

 function MOD:UpdateStatusMedia(frame)
-	local width,height = frame:GetSize()
+	if(not frame.StatusPanel) then return end
+	local width,height = frame.ActionPanel:GetSize()
+	frame.StatusPanel:ClearAllPoints()
 	if((height > (width * 0.5)) or (width < 75)) then
+		frame.StatusPanel:SetSize(height * 1.25, height * 1.25)
+		frame.StatusPanel:SetPoint("CENTER", frame.ActionPanel, "CENTER", 0, 0)
 		frame.StatusPanel.media = {
 			[[Interface\Addons\SVUI_UnitFrames\assets\UNIT-DC]],
 			[[Interface\Addons\SVUI_UnitFrames\assets\UNIT-DEAD]],
 			[[Interface\Addons\SVUI_UnitFrames\assets\UNIT-TAPPED]]
 		}
 	else
+		frame.StatusPanel:SetAllPoints(frame)
 		frame.StatusPanel.media = {
 			[[Interface\Addons\SVUI_UnitFrames\assets\TARGET-DC]],
 			[[Interface\Addons\SVUI_UnitFrames\assets\TARGET-DEAD]],
 			[[Interface\Addons\SVUI_UnitFrames\assets\TARGET-TAPPED]]
 		}
 	end
+	frame.StatusPanel.texture:ClearAllPoints()
+	frame.StatusPanel.texture:SetAllPoints()
 end
 --[[
 ##########################################################
diff --git a/SVUI_UnitFrames/libs/Plugins/oUF_ActionPanel/oUF_ActionPanel.lua b/SVUI_UnitFrames/libs/Plugins/oUF_ActionPanel/oUF_ActionPanel.lua
index f9af7fe..2817a87 100644
--- a/SVUI_UnitFrames/libs/Plugins/oUF_ActionPanel/oUF_ActionPanel.lua
+++ b/SVUI_UnitFrames/libs/Plugins/oUF_ActionPanel/oUF_ActionPanel.lua
@@ -80,15 +80,15 @@ local Update = function(self, event, unit)
 		if(not UnitIsConnected(unit)) then
 			texture:SetAlpha(1)
 			texture:SetTexture(media[1])
-			texture:SetGradient("VERTICAL",0,1,1,1,1,0)
+			--texture:SetGradient("VERTICAL",0,1,1,1,1,0)
 		elseif(UnitIsDeadOrGhost(unit)) then
 			texture:SetAlpha(1)
 			texture:SetTexture(media[2])
-			texture:SetGradient("VERTICAL",0,0,1,0,1,0)
+			--texture:SetGradient("VERTICAL",0,0,1,0,1,0)
 		elseif(unit ~= "player" and (unit ~= "vehicle" and (not UnitIsFriend(unit, "player")) and (not UnitIsPlayer(unit)) and UnitIsTapped(unit) and (not UnitIsTappedByPlayer(unit)))) then
 			texture:SetAlpha(1)
 			texture:SetTexture(media[3])
-			texture:SetGradient("VERTICAL",1,1,0,1,0,0)
+			--texture:SetGradient("VERTICAL",1,1,0,1,0,0)
 		else
 			texture:SetTexture(0,0,0,0)
 		end