use void pointer

This commit is contained in:
twinaphex 2016-01-07 01:00:11 +01:00
parent 3b8932b302
commit b4b3574665
2 changed files with 7 additions and 4 deletions

View File

@ -217,7 +217,7 @@ static LRESULT CALLBACK WndProcCommon(bool *quit, HWND hwnd, UINT message,
return 0;
}
extern bool d3d_restore(d3d_video_t *data);
extern bool d3d_restore(void *data);
LRESULT CALLBACK WndProcD3D(HWND hwnd, UINT message,
WPARAM wparam, LPARAM lparam)

View File

@ -422,10 +422,13 @@ static bool d3d_initialize(d3d_video_t *d3d, const video_info_t *info)
return true;
}
bool d3d_restore(d3d_video_t *d3d)
bool d3d_restore(void *data)
{
d3d_video_t *d3d = (d3d_video_t*)data;
if (!d3d)
return false;
d3d_deinitialize(d3d);
d3d->needs_restore = !d3d_initialize(d3d, &d3d->video_info);