Quantcast

Update to profile saving and loothistory

Steven Jackson [07-04-14 - 00:43]
Update to profile saving and loothistory
Filename
Interface/AddOns/SVUI/system/classes/Database.lua
Interface/AddOns/SVUI/system/system.lua
Interface/AddOns/SVUI_StyleOMatic/addons/loothistory.lua
diff --git a/Interface/AddOns/SVUI/system/classes/Database.lua b/Interface/AddOns/SVUI/system/classes/Database.lua
index 982050b..268b266 100644
--- a/Interface/AddOns/SVUI/system/classes/Database.lua
+++ b/Interface/AddOns/SVUI/system/classes/Database.lua
@@ -3442,8 +3442,6 @@ local function importprofile(t, key)
 	local src = globals.profiles[key]
 	if(not src) then return end
 	importdata(src, sv)
-	t.profileKey = key
-	sv.profileKey = key
 	SuperVillain:RefreshEverything()
 end

@@ -3454,7 +3452,7 @@ local function exportprofile(t, key)
 		globals.profiles[key] = {}
 	end
 	local dest = globals.profiles[key]
-	tablecopy(dest, src)
+	tablecopy(dest, sv)
 	globals.profileKeys[key] = key
 end

diff --git a/Interface/AddOns/SVUI/system/system.lua b/Interface/AddOns/SVUI/system/system.lua
index db996a2..216a1f7 100644
--- a/Interface/AddOns/SVUI/system/system.lua
+++ b/Interface/AddOns/SVUI/system/system.lua
@@ -343,7 +343,7 @@ function SuperVillain:RefreshEverything(bypass)
 	collectgarbage("collect");

 	if not bypass then
-		if(SVUI_Profile.SAFEDATA.install_complete == nil or (SVUI_Profile.SAFEDATA.install_complete and type(SVUI_Profile.SAFEDATA.install_complete) == 'boolean') or (SVUI_Profile.SAFEDATA.install_complete and type(tonumber(SVUI_Profile.SAFEDATA.install_complete)) == 'number' and tonumber(SVUI_Profile.SAFEDATA.install_complete) < self.version)) then
+		if(SVUI_Profile.SAFEDATA.install_complete == nil or (SVUI_Profile.SAFEDATA.install_complete and type(SVUI_Profile.SAFEDATA.install_complete) == 'boolean') or (SVUI_Profile.SAFEDATA.install_complete and type(tonumber(SVUI_Profile.SAFEDATA.install_complete)) == 'number' and tonumber(SVUI_Profile.SAFEDATA.install_complete) < tonumber(self.version))) then
 			self:Install();
 		end
 	end
diff --git a/Interface/AddOns/SVUI_StyleOMatic/addons/loothistory.lua b/Interface/AddOns/SVUI_StyleOMatic/addons/loothistory.lua
index e4982fe..4bea8ea 100644
--- a/Interface/AddOns/SVUI_StyleOMatic/addons/loothistory.lua
+++ b/Interface/AddOns/SVUI_StyleOMatic/addons/loothistory.lua
@@ -59,7 +59,8 @@ LOOTHISTORY STYLER
 local function LootHistoryStyle()
   LootHistoryFrame:SetFrameStrata('HIGH')
   if SuperVillain.db.SVStyle.blizzard.enable ~= true or SuperVillain.db.SVStyle.blizzard.loot ~= true then return end;
-  local M = MissingLootFrame;M:Formula409()
+  local M = MissingLootFrame;
+  M:Formula409()
   M:SetPanelTemplate("Pattern")
   MOD:ApplyCloseButtonStyle(MissingLootFramePassButton)
   hooksecurefunc("MissingLootFrame_Show", MissingLootFrame_OnShow)
@@ -73,6 +74,14 @@ local function LootHistoryStyle()
   LootHistoryFrame.ResizeButton:Height(19)
   LootHistoryFrame.ResizeButton:ClearAllPoints()
   LootHistoryFrame.ResizeButton:Point("TOP", LootHistoryFrame, "BOTTOM", 0, -2)
+  LootHistoryFrame.ResizeButton:SetNormalTexture("")
+
+  local txt = LootHistoryFrame.ResizeButton:CreateFontString(nil,"OVERLAY")
+  txt:SetFont(SuperVillain.Media.font.roboto, 14, "NONE")
+  txt:SetAllPoints(LootHistoryFrame.ResizeButton)
+  txt:SetJustifyH("CENTER")
+  txt:SetText("RESIZE")
+
   LootHistoryFrameScrollFrame:Formula409()
   MOD:ApplyScrollStyle(LootHistoryFrameScrollFrameScrollBar)
   hooksecurefunc("LootHistoryFrame_FullUpdate", LootHistoryFrame_OnUpdate)