summaryrefslogtreecommitdiff
path: root/indra/llwindow/llwindowwin32.cpp
diff options
context:
space:
mode:
authorAndrey Lihatskiy <alihatskiy@productengine.com>2024-05-15 12:27:46 +0300
committerAndrey Lihatskiy <alihatskiy@productengine.com>2024-05-15 12:27:46 +0300
commite59216443619dd2280ce0fff316a2b9e2ee7cf5e (patch)
tree27d782916858596d67a60ecf56ca07b6a44a4601 /indra/llwindow/llwindowwin32.cpp
parentdcb85f9f9d1019bb046a5719bc3645fa96a2d060 (diff)
parentbb3c36f5cbc0c3b542045fd27255eee24e03da22 (diff)
Merge branch 'main' into release/maint-c
# Conflicts: # indra/llui/lltexteditor.cpp # indra/newview/llcontrolavatar.cpp
Diffstat (limited to 'indra/llwindow/llwindowwin32.cpp')
-rw-r--r--indra/llwindow/llwindowwin32.cpp17
1 files changed, 13 insertions, 4 deletions
diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp
index a3c775990c..aea7367337 100644
--- a/indra/llwindow/llwindowwin32.cpp
+++ b/indra/llwindow/llwindowwin32.cpp
@@ -1646,7 +1646,9 @@ const S32 max_format = (S32)num_formats - 1;
}
else
{
- LL_WARNS("Window") << "No wgl_ARB_pixel_format extension, using default ChoosePixelFormat!" << LL_ENDL;
+ LLError::LLUserWarningMsg::show(mCallbacks->translateString("MBVideoDrvErr"));
+ // mWindowHandle is 0, going to crash either way
+ LL_ERRS("Window") << "No wgl_ARB_pixel_format extension!" << LL_ENDL;
}
// Verify what pixel format we actually received.
@@ -1899,12 +1901,16 @@ void LLWindowWin32::destroySharedContext(void* contextPtr)
void LLWindowWin32::toggleVSync(bool enable_vsync)
{
- if (!enable_vsync && wglSwapIntervalEXT)
+ if (wglSwapIntervalEXT == nullptr)
+ {
+ LL_INFOS("Window") << "VSync: wglSwapIntervalEXT not initialized" << LL_ENDL;
+ }
+ else if (!enable_vsync)
{
LL_INFOS("Window") << "Disabling vertical sync" << LL_ENDL;
wglSwapIntervalEXT(0);
}
- else if (wglSwapIntervalEXT)
+ else
{
LL_INFOS("Window") << "Enabling vertical sync" << LL_ENDL;
wglSwapIntervalEXT(1);
@@ -4475,7 +4481,10 @@ void* LLWindowWin32::getDirectInput8()
return &gDirectInput8;
}
-bool LLWindowWin32::getInputDevices(U32 device_type_filter, void * di8_devices_callback, void* userdata)
+bool LLWindowWin32::getInputDevices(U32 device_type_filter,
+ std::function<bool(std::string&, LLSD&, void*)> osx_callback,
+ void * di8_devices_callback,
+ void* userdata)
{
if (gDirectInput8 != NULL)
{