Never, Never do if (FALSE) it will make dead code. activate dead code after DrFreds bug.

svn path=/trunk/; revision=18996
This commit is contained in:
Magnus Olsen 2005-11-04 16:26:13 +00:00
parent 266f0076b8
commit 8886eb415a
2 changed files with 7 additions and 5 deletions

View file

@ -16,13 +16,14 @@ HRESULT WINAPI Main_DirectDraw_Initialize (LPDIRECTDRAW7 iface, LPGUID lpGUID)
IDirectDrawImpl* This = (IDirectDrawImpl*)iface;
HRESULT ret;
// this if it is not called by DirectDrawCreate
if(FALSE)
if (This->InitializeDraw == TRUE)
return DDERR_ALREADYINITIALIZED;
// save the parameter
This->lpGUID = lpGUID;
This->InitializeDraw = TRUE;
// get the HDC
This->hdc = GetWindowDC(GetDesktopWindow());
This->Height = GetDeviceCaps(This->hdc, VERTRES);

View file

@ -28,7 +28,8 @@ typedef struct
HDC hdc;
int Height, Width, Bpp;
GUID* lpGUID;
GUID InGUID;
BOOL InitializeDraw;
} IDirectDrawImpl;