Fix: apply saved window settings after the game loads them
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WyQKCL92ZLwPi9qmYQtNdc
This commit is contained in:
@@ -11,6 +11,9 @@
|
||||
- The "no DLL: estimates only" note is gone from the panel: without the DLL the timers are now accurate. `/ob debug` still shows whether the DLL is loaded.
|
||||
- The footer no longer names the route with the oldest data (the restart correction makes it unnecessary). It only appears after a server restart, while a route in the window has not been seen since.
|
||||
|
||||
### Fixed
|
||||
- Window size, look, lock, position and the minimap icon's spot were not restored after logging in: they were applied before the game had loaded the saved settings.
|
||||
|
||||
## 1.3.4 (12 October 2026)
|
||||
|
||||
### Fixed
|
||||
|
||||
+15
@@ -1759,6 +1759,21 @@ local OB_OK, OB_ERR = pcall(function ()
|
||||
end
|
||||
end
|
||||
|
||||
-- This file runs before the game loads the saved settings, so everything set up above
|
||||
-- used the defaults. Once they are loaded, apply them: size, look, lock, icon and
|
||||
-- window position.
|
||||
do
|
||||
local f = CreateFrame("Frame")
|
||||
f:RegisterEvent("VARIABLES_LOADED")
|
||||
f:SetScript("OnEvent", function()
|
||||
panel:SetScale(CFG.scale or 1)
|
||||
ApplyLook()
|
||||
if CFG.locked then grip:Hide() else grip:Show() end
|
||||
PlaceButton()
|
||||
PlacePanel()
|
||||
end)
|
||||
end
|
||||
|
||||
-- for the settings window (OctoBusOptions.lua)
|
||||
OctoBus = {
|
||||
cfg = CFG,
|
||||
|
||||
Reference in New Issue
Block a user