mirror of
https://github.com/Bluewhale1337/ElvUIModernized.git
synced 2026-07-27 08:24:44 +00:00
update AceGUI-3.0-SharedMediaWidgets
This commit is contained in:
@@ -171,7 +171,7 @@ do
|
|||||||
end
|
end
|
||||||
f.obj = self
|
f.obj = self
|
||||||
f.dropdown = self.dropdown
|
f.dropdown = self.dropdown
|
||||||
self.dropdown:AddFrame(f)
|
self.dropdown:AddFrame(f, i)
|
||||||
end
|
end
|
||||||
wipe(sortedlist)
|
wipe(sortedlist)
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -166,7 +166,7 @@ do
|
|||||||
end
|
end
|
||||||
f.obj = self
|
f.obj = self
|
||||||
f.dropdown = self.dropdown
|
f.dropdown = self.dropdown
|
||||||
self.dropdown:AddFrame(f)
|
self.dropdown:AddFrame(f, i)
|
||||||
end
|
end
|
||||||
wipe(sortedlist)
|
wipe(sortedlist)
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -153,7 +153,7 @@ do
|
|||||||
f.check:Show()
|
f.check:Show()
|
||||||
end
|
end
|
||||||
f.obj = self
|
f.obj = self
|
||||||
self.dropdown:AddFrame(f)
|
self.dropdown:AddFrame(f, i)
|
||||||
end
|
end
|
||||||
wipe(sortedlist)
|
wipe(sortedlist)
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -175,7 +175,7 @@ do
|
|||||||
f.check:Show()
|
f.check:Show()
|
||||||
end
|
end
|
||||||
f.obj = self
|
f.obj = self
|
||||||
self.dropdown:AddFrame(f)
|
self.dropdown:AddFrame(f, i)
|
||||||
end
|
end
|
||||||
wipe(sortedlist)
|
wipe(sortedlist)
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -163,7 +163,7 @@ do
|
|||||||
f.bar:SetTexture(statusbar)
|
f.bar:SetTexture(statusbar)
|
||||||
f.obj = self
|
f.obj = self
|
||||||
f.dropdown = self.dropdown
|
f.dropdown = self.dropdown
|
||||||
self.dropdown:AddFrame(f)
|
self.dropdown:AddFrame(f, i)
|
||||||
end
|
end
|
||||||
wipe(sortedlist)
|
wipe(sortedlist)
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ local Media = LibStub("LibSharedMedia-3.0")
|
|||||||
AGSMW = AGSMW or {}
|
AGSMW = AGSMW or {}
|
||||||
|
|
||||||
local next, ipairs = next, ipairs
|
local next, ipairs = next, ipairs
|
||||||
local getn, setn, tinsert, tremove = table.getn, table.setn, table.insert, table.remove
|
local tinsert, tremove = table.insert, table.remove
|
||||||
|
|
||||||
AceGUIWidgetLSMlists = {
|
AceGUIWidgetLSMlists = {
|
||||||
['font'] = Media:HashTable("font"),
|
['font'] = Media:HashTable("font"),
|
||||||
@@ -163,20 +163,19 @@ do
|
|||||||
self.slider:SetValue(self.slider:GetValue()+(15*dir*-1))
|
self.slider:SetValue(self.slider:GetValue()+(15*dir*-1))
|
||||||
end
|
end
|
||||||
|
|
||||||
local function AddFrame(self, frame)
|
local function AddFrame(self, frame, i)
|
||||||
frame:SetParent(self.contentframe)
|
frame:SetParent(self.contentframe)
|
||||||
frame:SetFrameStrata(self:GetFrameStrata())
|
frame:SetFrameStrata(self:GetFrameStrata())
|
||||||
frame:SetFrameLevel(self:GetFrameLevel() + 100)
|
frame:SetFrameLevel(self:GetFrameLevel() + 100)
|
||||||
|
|
||||||
if next(self.contentRepo) then
|
if next(self.contentRepo) then
|
||||||
frame:SetPoint("TOPLEFT", self.contentRepo[getn(self.contentRepo)], "BOTTOMLEFT", 0, 0)
|
frame:SetPoint("TOPLEFT", self.contentRepo[i-1], "BOTTOMLEFT", 0, 0)
|
||||||
self.contentframe:SetHeight(self.contentframe:GetHeight() + frame:GetHeight())
|
self.contentframe:SetHeight(self.contentframe:GetHeight() + frame:GetHeight())
|
||||||
tinsert(self.contentRepo, frame)
|
|
||||||
else
|
else
|
||||||
self.contentframe:SetHeight(frame:GetHeight())
|
self.contentframe:SetHeight(frame:GetHeight())
|
||||||
frame:SetPoint("TOPLEFT", self.contentframe, 0, 0)
|
frame:SetPoint("TOPLEFT", self.contentframe, 0, 0)
|
||||||
tinsert(self.contentRepo, frame)
|
|
||||||
end
|
end
|
||||||
|
self.contentRepo[i] = frame
|
||||||
|
|
||||||
if self.contentframe:GetHeight() > GetScreenHeight()*2/5 - 20 then
|
if self.contentframe:GetHeight() > GetScreenHeight()*2/5 - 20 then
|
||||||
self.scrollframe:SetWidth(128)
|
self.scrollframe:SetWidth(128)
|
||||||
@@ -202,7 +201,6 @@ do
|
|||||||
frame:ReturnSelf()
|
frame:ReturnSelf()
|
||||||
self.contentRepo[i] = nil
|
self.contentRepo[i] = nil
|
||||||
end
|
end
|
||||||
setn(self.contentRepo, 0)
|
|
||||||
end
|
end
|
||||||
|
|
||||||
local function slider_OnValueChanged()
|
local function slider_OnValueChanged()
|
||||||
|
|||||||
Reference in New Issue
Block a user