Closed zhengying closed 1 month ago
Can you provide some code and steps to reproduce the issue for you?
I noticed that it is actually called twice: the first time returns the old size, and the second time returns the new size. Is this by design?
reproduce step
1. new a simple main.lua :
function love.load()
love.window.setMode(1024,768,{resizable=true})
end
function love.resize(w, h)
print(tostring(w), tostring(h))
end
2. run it with love2d 11.5
3. resize window
5. see console log:
the result is :
1024 768
934 705
Thanks! I'm able to reproduce the issue. I'm not sure yet whether love's own event handling code has some bad assumptions around the order of SDL resize events, or if SDL is doing something weird with them. I'll need to investigate more.
macOS 13.4 intel x86, love2d 11.5
The w and h parameters should have a new width and height, but I got the old size. Is this a bug?