diff --git a/CHANGES b/CHANGES index ef075bd9c..f225b8b15 100644 --- a/CHANGES +++ b/CHANGES @@ -52,6 +52,7 @@ Misc: - Qt: Remove maligned double-click-to-fullscreen shortcut (closes mgba.io/i/2632) - Qt: Pass logging context through to video proxy thread (fixes mgba.io/i/3095) - Qt: Show maker code and game version in ROM info + - Qt: Make window corners square on Windows 11 (fixes mgba.io/i/3285) - Res: Port NSO-gba-colors shader (closes mgba.io/i/2834) - Scripting: Add `callbacks:oneshot` for single-call callbacks - Switch: Add bilinear filtering option (closes mgba.io/i/3111) diff --git a/src/platform/qt/Window.cpp b/src/platform/qt/Window.cpp index 010dde782..0e3d73b00 100644 --- a/src/platform/qt/Window.cpp +++ b/src/platform/qt/Window.cpp @@ -14,6 +14,10 @@ #include #include +#ifdef Q_OS_WIN +#include +#endif + #ifdef USE_SQLITE3 #include "ArchiveInspector.h" #include "library/LibraryController.h" @@ -717,6 +721,11 @@ void Window::showEvent(QShowEvent* event) { return; } m_wasOpened = true; +#ifdef Q_OS_WIN + HWND hwnd = reinterpret_cast(winId()); + DWM_WINDOW_CORNER_PREFERENCE cornerPref = DWMWCP_DONOTROUND; + DwmSetWindowAttribute(hwnd, DWMWA_WINDOW_CORNER_PREFERENCE, &cornerPref, sizeof(cornerPref)); +#endif if (m_initialSize.isValid()) { resizeFrame(m_initialSize); }