well I tried
Code:
switch(this->device->Present(0 , 0 , 0 , 0)){
case D3DERR_DEVICELOST: // application lost focus, reset
while(this->device->Reset(&this->d3d_parameters) == D3DERR_DEVICELOST) Sleep(0);
this->device->Release();
this->d3d->Release();
this->d3d = Direct3DCreate9(D3D_SDK_VERSION);
this->d3d->CreateDevice(D3DADAPTER_DEFAULT , D3DDEVTYPE_HAL , hwnd , this->VertexProcessingMethod , &this->d3d_parameters , &this->device);
break;
default:
break;
}
which does retake the screen, but there seems to be a conflict, as i get flashing pieces of the desktop or other appications. Right now all my application
is doing is clearing the back buffer, there are no other resources created, I want to get the alt tab thing figured out before i start adding code to handle
the meshes etc, so that i can add that into the alt tab handlign code as well where appropriate.