wined3d: Do not switch display mode when windowed is TRUE.
Fixes a regression introduced by commit
cad279449c
.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
bdd7be3747
commit
910fc594d9
|
@ -4648,6 +4648,7 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
|
||||||
struct wined3d_rendertarget_view_desc view_desc;
|
struct wined3d_rendertarget_view_desc view_desc;
|
||||||
struct wined3d_resource *resource, *cursor;
|
struct wined3d_resource *resource, *cursor;
|
||||||
struct wined3d_swapchain *swapchain;
|
struct wined3d_swapchain *swapchain;
|
||||||
|
BOOL backbuffer_resized;
|
||||||
HRESULT hr = WINED3D_OK;
|
HRESULT hr = WINED3D_OK;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
|
@ -4737,10 +4738,12 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
|
||||||
wined3d_swapchain_set_window(swapchain, NULL);
|
wined3d_swapchain_set_window(swapchain, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
backbuffer_resized = swapchain_desc->backbuffer_width != swapchain->desc.backbuffer_width
|
||||||
|
|| swapchain_desc->backbuffer_height != swapchain->desc.backbuffer_height;
|
||||||
|
|
||||||
if (!swapchain_desc->windowed != !swapchain->desc.windowed
|
if (!swapchain_desc->windowed != !swapchain->desc.windowed
|
||||||
|| swapchain->reapply_mode || mode
|
|| swapchain->reapply_mode || mode
|
||||||
|| swapchain_desc->backbuffer_width != swapchain->desc.backbuffer_width
|
|| (!swapchain_desc->windowed && backbuffer_resized))
|
||||||
|| swapchain_desc->backbuffer_height != swapchain->desc.backbuffer_height)
|
|
||||||
{
|
{
|
||||||
if (FAILED(hr = wined3d_swapchain_set_fullscreen(swapchain, swapchain_desc, mode)))
|
if (FAILED(hr = wined3d_swapchain_set_fullscreen(swapchain, swapchain_desc, mode)))
|
||||||
return hr;
|
return hr;
|
||||||
|
|
Loading…
Reference in New Issue