Added export to disable rounded corners on Windows 11

This commit is contained in:
Hyper 2025-01-27 06:47:38 +00:00
parent a9677084ea
commit 836a5e96e2
2 changed files with 7 additions and 0 deletions

View file

@ -231,6 +231,12 @@ void GameWindow::Init(const char* sdlVideoDriver)
#if defined(_WIN32)
s_renderWindow = info.info.win.window;
if (Config::DisableDWMRoundedCorners)
{
DWM_WINDOW_CORNER_PREFERENCE wcp = DWMWCP_DONOTROUND;
DwmSetWindowAttribute(s_renderWindow, DWMWA_WINDOW_CORNER_PREFERENCE, &wcp, sizeof(wcp));
}
#elif defined(SDL_VULKAN_ENABLED)
s_renderWindow = s_pWindow;
#elif defined(__linux__)

View file

@ -77,6 +77,7 @@ CONFIG_DEFINE_ENUM_LOCALISED("Video", EUIScaleMode, UIScaleMode, EUIScaleMode::E
CONFIG_DEFINE_HIDDEN("Exports", bool, AllowCancellingUnleash, false);
CONFIG_DEFINE_HIDDEN("Exports", bool, DisableAutoSaveWarning, false);
CONFIG_DEFINE_HIDDEN("Exports", bool, DisableDLCIcon, false);
CONFIG_DEFINE_HIDDEN("Exports", bool, DisableDWMRoundedCorners, false);
CONFIG_DEFINE_HIDDEN("Exports", bool, FixUnleashOutOfControlDrain, false);
CONFIG_DEFINE_HIDDEN("Exports", bool, HomingAttackOnBoost, true);
CONFIG_DEFINE_HIDDEN("Exports", bool, SaveScoreAtCheckpoints, false);