ddraw: Use wined3d_get_adapter_display_mode() in d3d_device2_EnumTextureFormats().

This commit is contained in:
Henri Verbeet 2012-06-21 19:35:35 +02:00 committed by Alexandre Julliard
parent 339ef6c252
commit 220a55c36c

View File

@ -1198,8 +1198,7 @@ static HRESULT WINAPI d3d_device2_EnumTextureFormats(IDirect3DDevice2 *iface,
wined3d_mutex_lock();
memset(&mode, 0, sizeof(mode));
hr = wined3d_device_get_display_mode(device->ddraw->wined3d_device, 0, &mode);
if (FAILED(hr))
if (FAILED(hr = wined3d_get_adapter_display_mode(device->ddraw->wined3d, WINED3DADAPTER_DEFAULT, &mode)))
{
wined3d_mutex_unlock();
WARN("Cannot get the current adapter format\n");