Fixed win2k sound bug

This commit is contained in:
pagefault
2001-05-09 01:06:42 +00:00
parent 7c017d5a91
commit 622de7e59c

View File

@@ -497,7 +497,14 @@ InitSound()
if(DS_OK == DirectSoundCreate(NULL, &lpDirectSound,NULL)) if(DS_OK == DirectSoundCreate(NULL, &lpDirectSound,NULL))
{ {
if (DS_OK != lpDirectSound->SetCooperativeLevel(hMainWindow, DSSCL_NORMAL)) {SoundEnabled=0; return FALSE;} if (DS_OK != lpDirectSound->SetCooperativeLevel(hMainWindow, DSSCL_NORMAL))
{
if (DS_OK != lpDirectSound->SetCooperativeLevel(hMainWindow, DSSCL_EXCLUSIVE))
{
SoundEnabled=0;
return FALSE;
}
}
} }
else else
{ {