diff --git a/doc/changelog.dox b/doc/changelog.dox index 5fbc172d4..3f0e1bdb8 100644 --- a/doc/changelog.dox +++ b/doc/changelog.dox @@ -98,6 +98,9 @@ See also: @subsection changelog-latest-bugfixes Bug fixes +- @ref Platform::Sdl2Application::viewportEvent() gets properly fired also + when window size changes programmatically (such as through + @ref Platform::Sdl2Application::setMinWindowSize() "setMinWindowSize()") - The @ref Primitives::cylinderSolid() and @ref Primitives::coneSolid() primitives were missing a face when both caps and texture coordinates were enabled (see [mosra/magnum#386](https://github.com/mosra/magnum/issues/386)) diff --git a/src/Magnum/Platform/Sdl2Application.cpp b/src/Magnum/Platform/Sdl2Application.cpp index 3388dc1f2..b4e20e994 100644 --- a/src/Magnum/Platform/Sdl2Application.cpp +++ b/src/Magnum/Platform/Sdl2Application.cpp @@ -755,7 +755,10 @@ bool Sdl2Application::mainLoopIteration() { switch(event.type) { case SDL_WINDOWEVENT: switch(event.window.event) { - case SDL_WINDOWEVENT_RESIZED: { + /* Not using SDL_WINDOWEVENT_RESIZED, because that doens't + get fired when the window is resized programmatically + (such as through setMaxWindowSize()) */ + case SDL_WINDOWEVENT_SIZE_CHANGED: { #ifdef CORRADE_TARGET_EMSCRIPTEN /* If anybody sees this assert, then emscripten finally implemented resize events. Praise them for that.