=?UTF-8?Q?J=C3=B3zef=20Kucia=20?=: wined3d: Do not switch display mode when windowed is TRUE.
Alexandre Julliard
julliard at winehq.org
Tue Aug 16 10:41:00 CDT 2016
Module: wine
Branch: master
Commit: 910fc594d9e483143863e27eb7498dd26ccdd3d4
URL: http://source.winehq.org/git/wine.git/?a=commit;h=910fc594d9e483143863e27eb7498dd26ccdd3d4
Author: Józef Kucia <jkucia at codeweavers.com>
Date: Mon Aug 15 16:00:15 2016 +0200
wined3d: Do not switch display mode when windowed is TRUE.
Fixes a regression introduced by commit
cad279449c62a965a70a712a91b11ba52c4ff4f7.
Signed-off-by: Józef Kucia <jkucia at codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/wined3d/device.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
index 406dca9..c2a8c55 100644
--- a/dlls/wined3d/device.c
+++ b/dlls/wined3d/device.c
@@ -4648,6 +4648,7 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
struct wined3d_rendertarget_view_desc view_desc;
struct wined3d_resource *resource, *cursor;
struct wined3d_swapchain *swapchain;
+ BOOL backbuffer_resized;
HRESULT hr = WINED3D_OK;
unsigned int i;
@@ -4737,10 +4738,12 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
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
|| swapchain->reapply_mode || mode
- || swapchain_desc->backbuffer_width != swapchain->desc.backbuffer_width
- || swapchain_desc->backbuffer_height != swapchain->desc.backbuffer_height)
+ || (!swapchain_desc->windowed && backbuffer_resized))
{
if (FAILED(hr = wined3d_swapchain_set_fullscreen(swapchain, swapchain_desc, mode)))
return hr;
More information about the wine-cvs
mailing list