summaryrefslogtreecommitdiff
path: root/indra/newview/llappviewerwin32.cpp
diff options
context:
space:
mode:
authorAndrey Kleshchev <117672381+akleshchev@users.noreply.github.com>2025-08-06 18:41:52 +0300
committerGitHub <noreply@github.com>2025-08-06 18:41:52 +0300
commit55f1c8b9797836c9816528bb5b772eb83b083b50 (patch)
treefdbc5a913c62265f95e610819637e096f0f85339 /indra/newview/llappviewerwin32.cpp
parent514b658fde13bb0c0ec862b081eeebf47bace70d (diff)
parentce9d66cdd18c58c3b26fbebde633ae00732d7f9f (diff)
Merge pull request #4492 Merge Develop into Maint-C (2025.06)
Merge Develop into Maint-C (2025.06)
Diffstat (limited to 'indra/newview/llappviewerwin32.cpp')
-rw-r--r--indra/newview/llappviewerwin32.cpp24
1 files changed, 24 insertions, 0 deletions
diff --git a/indra/newview/llappviewerwin32.cpp b/indra/newview/llappviewerwin32.cpp
index 4f5fa53312..8477bd3044 100644
--- a/indra/newview/llappviewerwin32.cpp
+++ b/indra/newview/llappviewerwin32.cpp
@@ -448,6 +448,7 @@ int APIENTRY WINMAIN(HINSTANCE hInstance,
// *FIX: global
gIconResource = MAKEINTRESOURCE(IDI_LL_ICON);
+ gIconSmallResource = MAKEINTRESOURCE(IDI_LL_ICON_SMALL);
LLAppViewerWin32* viewer_app_ptr = new LLAppViewerWin32(ll_convert_wide_to_string(pCmdLine).c_str());
@@ -816,6 +817,29 @@ bool LLAppViewerWin32::reportCrashToBugsplat(void* pExcepInfo)
return false;
}
+bool LLAppViewerWin32::initWindow()
+{
+ // This is a workaround/hotfix for a change in Windows 11 24H2 (and possibly later)
+ // Where the window width and height need to correctly reflect an available FullScreen size
+ if (gSavedSettings.getBOOL("FullScreen"))
+ {
+ DEVMODE dev_mode;
+ ::ZeroMemory(&dev_mode, sizeof(DEVMODE));
+ dev_mode.dmSize = sizeof(DEVMODE);
+ if (EnumDisplaySettings(NULL, ENUM_CURRENT_SETTINGS, &dev_mode))
+ {
+ gSavedSettings.setU32("WindowWidth", dev_mode.dmPelsWidth);
+ gSavedSettings.setU32("WindowHeight", dev_mode.dmPelsHeight);
+ }
+ else
+ {
+ LL_WARNS("AppInit") << "Unable to set WindowWidth and WindowHeight for FullScreen mode" << LL_ENDL;
+ }
+ }
+
+ return LLAppViewer::initWindow();
+}
+
void LLAppViewerWin32::initLoggingAndGetLastDuration()
{
LLAppViewer::initLoggingAndGetLastDuration();