Fixed issues with position saving and reseting profiles

This commit is contained in:
Hendrik Leppkes
2008-11-11 16:13:49 +01:00
parent 7f57e78c61
commit 90c58593b9
8 changed files with 42 additions and 19 deletions
+6 -2
View File
@@ -29,8 +29,6 @@ end
function StanceBarMod:OnEnable()
if not self.bar then
self.bar = setmetatable(Bartender4.ButtonBar:Create("StanceBar", self.db.profile, L["Stance Bar"]), {__index = StanceBar})
self.bar:ClearSetPoint("CENTER", -55, -10)
self.bar:SetScript("OnEvent", StanceBar.OnEvent)
end
self.bar:Enable()
@@ -207,6 +205,12 @@ end
function StanceBar:ApplyConfig(config)
ButtonBar.ApplyConfig(self, config)
if not self.config.position then
self:ClearSetPoint("CENTER", -55, -10)
self:SavePosition()
end
self:UpdateStanceButtons()
self:ForAll("ApplyStyle", self.config.style)
end