wined3d: Set the main hwnd before setting up the screen.
This commit is contained in:
parent
9a177b6407
commit
38147d28dd
|
@ -1385,6 +1385,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateAdditionalSwapChain(IWineD3DDevic
|
||||||
if (!object->win_handle) {
|
if (!object->win_handle) {
|
||||||
object->win_handle = This->createParms.hFocusWindow;
|
object->win_handle = This->createParms.hFocusWindow;
|
||||||
}
|
}
|
||||||
|
if(!This->ddraw_window) IWineD3DDevice_SetHWND(iface, object->win_handle);
|
||||||
|
|
||||||
hDc = GetDC(object->win_handle);
|
hDc = GetDC(object->win_handle);
|
||||||
TRACE("Using hDc %p\n", hDc);
|
TRACE("Using hDc %p\n", hDc);
|
||||||
|
@ -2002,8 +2003,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Init3D(IWineD3DDevice *iface, WINED3DPR
|
||||||
}
|
}
|
||||||
This->swapchains[0] = (IWineD3DSwapChain *) swapchain;
|
This->swapchains[0] = (IWineD3DSwapChain *) swapchain;
|
||||||
|
|
||||||
if(!This->ddraw_window) IWineD3DDevice_SetHWND(iface, swapchain->win_handle);
|
|
||||||
|
|
||||||
if(swapchain->backBuffer && swapchain->backBuffer[0]) {
|
if(swapchain->backBuffer && swapchain->backBuffer[0]) {
|
||||||
TRACE("Setting rendertarget to %p\n", swapchain->backBuffer);
|
TRACE("Setting rendertarget to %p\n", swapchain->backBuffer);
|
||||||
This->render_targets[0] = swapchain->backBuffer[0];
|
This->render_targets[0] = swapchain->backBuffer[0];
|
||||||
|
|
Loading…
Reference in New Issue