Commit 45166d33 authored by Andrew Eikum's avatar Andrew Eikum Committed by Alexandre Julliard

dxgi: Return DXGI_ERROR_NOT_CURRENTLY_AVAILABLE if setting the fullscreen state failed.

parent 67110d37
......@@ -385,18 +385,18 @@ static HRESULT STDMETHODCALLTYPE DECLSPEC_HOTPATCH d3d11_swapchain_SetFullscreen
swapchain_desc.windowed = !fullscreen;
hr = wined3d_swapchain_set_fullscreen(swapchain->wined3d_swapchain, &swapchain_desc, NULL);
wined3d_mutex_unlock();
if (SUCCEEDED(hr))
if (FAILED(hr))
{
if (swapchain->target)
IDXGIOutput_Release(swapchain->target);
swapchain->target = target;
return S_OK;
if (target)
IDXGIOutput_Release(target);
return DXGI_ERROR_NOT_CURRENTLY_AVAILABLE;
}
if (target)
IDXGIOutput_Release(target);
return hr;
if (swapchain->target)
IDXGIOutput_Release(swapchain->target);
swapchain->target = target;
return S_OK;
}
static HRESULT STDMETHODCALLTYPE d3d11_swapchain_GetFullscreenState(IDXGISwapChain1 *iface,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment