Win32 Unicode fixes.

This commit is contained in:
Camilla Berglund
2012-07-06 13:55:54 +02:00
parent 78bc624ba9
commit db066b4f46
3 changed files with 15 additions and 7 deletions
+9 -1
View File
@@ -199,7 +199,15 @@ int _glfwPlatformGetVideoModes(_GLFWmonitor* monitor, GLFWvidmode* list, int ma
for (;;)
{
if (!EnumDisplaySettings(monitor->Win32.name, deviceModeNum, &deviceMode))
BOOL result;
WCHAR* wideName = _glfwCreateWideStringFromUTF8(monitor->Win32.name);
if (!wideName)
break;
result = EnumDisplaySettings(wideName, deviceModeNum, &deviceMode);
free(wideName);
if (!result)
break;
if (vidModesCount >= maxcount)