fix: v1.4.4 - AceGUI pool fixes, event handling nil checks, QuestieLearner serialization, l10n format fixes

This commit is contained in:
Xurkon
2026-03-20 21:16:58 -05:00
parent f32520078c
commit 2df8a7b96d
26 changed files with 569 additions and 83 deletions
+20 -4
View File
@@ -172,6 +172,8 @@ end
function AceGUI:Create(type)
if WidgetRegistry[type] then
local widget = newWidget(type)
if not widget then return end
if rawget(widget, "Acquire") then
widget.OnAcquire = widget.Acquire
@@ -204,6 +206,7 @@ end
-- If this widget is a Container-Widget, all of its Child-Widgets will be releases as well.
-- @param widget The widget to release
function AceGUI:Release(widget)
if not widget then return end
safecall(widget.PauseLayout, widget)
widget:Fire("OnRelease")
safecall(widget.ReleaseChildren, widget)
@@ -310,6 +313,7 @@ do
end
WidgetBase.Fire = function(self, name, ...)
if not self or not self.type or not self.events then return end
if self.events[name] then
local success, ret = safecall(self.events[name], self, name, ...)
if success then
@@ -422,14 +426,19 @@ do
local WidgetContainerBase = AceGUI.WidgetContainerBase
WidgetContainerBase.PauseLayout = function(self)
self.LayoutPaused = true
if self then
self.LayoutPaused = true
end
end
WidgetContainerBase.ResumeLayout = function(self)
self.LayoutPaused = nil
if self then
self.LayoutPaused = nil
end
end
WidgetContainerBase.PerformLayout = function(self)
if not self then return end
if self.LayoutPaused then
return
end
@@ -438,7 +447,9 @@ do
--call this function to layout, makes sure layed out objects get a frame to get sizes etc
WidgetContainerBase.DoLayout = function(self)
self:PerformLayout()
if self then
self:PerformLayout()
end
-- if not self.parent then
-- self.frame:SetScript("OnUpdate", LayoutOnUpdate)
-- end
@@ -481,7 +492,9 @@ do
end
WidgetContainerBase.SetLayout = function(self, Layout)
self.LayoutFunc = AceGUI:GetLayout(Layout)
if self then
self.LayoutFunc = AceGUI:GetLayout(Layout)
end
end
WidgetContainerBase.SetAutoAdjustHeight = function(self, adjust)
@@ -627,6 +640,7 @@ end
-- Very simple Layout, Children are stacked on top of each other down the left side
AceGUI:RegisterLayout("List",
function(content, children)
if not content then return end
local height = 0
local width = content.width or content:GetWidth() or 0
for i = 1, #children do
@@ -664,6 +678,7 @@ AceGUI:RegisterLayout("List",
-- A single control fills the whole content area
AceGUI:RegisterLayout("Fill",
function(content, children)
if not content then return end
if children[1] then
children[1]:SetWidth(content:GetWidth() or 0)
children[1]:SetHeight(content:GetHeight() or 0)
@@ -683,6 +698,7 @@ end
AceGUI:RegisterLayout("Flow",
function(content, children)
if layoutrecursionblock then return end
if not content then return end
--used height so far
local height = 0
--width used in the current row