mirror of https://github.com/stella-emu/stella.git
Updated VS 2005 project with latest changes.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2266 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
parent
55f4de0725
commit
672461b942
|
@ -50,7 +50,11 @@ SoundSDL::SoundSDL(OSystem* osystem)
|
|||
SoundSDL::~SoundSDL()
|
||||
{
|
||||
// Close the SDL audio system if it's initialized
|
||||
close();
|
||||
if(myIsInitializedFlag)
|
||||
{
|
||||
SDL_CloseAudio();
|
||||
myIsInitializedFlag = false;
|
||||
}
|
||||
}
|
||||
|
||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
|
@ -75,8 +79,9 @@ void SoundSDL::open()
|
|||
myRegWriteQueue.clear();
|
||||
myTIASound.reset();
|
||||
|
||||
if(SDL_WasInit(SDL_INIT_AUDIO) == 0)
|
||||
if(!myIsInitializedFlag && SDL_WasInit(SDL_INIT_AUDIO) == 0)
|
||||
{
|
||||
cerr << "SoundSDL::open()\n";
|
||||
myIsInitializedFlag = false;
|
||||
myIsMuted = false;
|
||||
myLastRegisterSetCycle = 0;
|
||||
|
@ -158,8 +163,8 @@ void SoundSDL::close()
|
|||
{
|
||||
if(myIsInitializedFlag)
|
||||
{
|
||||
SDL_CloseAudio();
|
||||
myIsInitializedFlag = false;
|
||||
cerr << "SoundSDL::close()\n";
|
||||
SDL_PauseAudio(1);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -464,8 +464,8 @@ fallback:
|
|||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
void OSystem::createSound()
|
||||
{
|
||||
delete mySound; mySound = NULL;
|
||||
mySound = MediaFactory::createAudio(this);
|
||||
if(!mySound)
|
||||
mySound = MediaFactory::createAudio(this);
|
||||
#ifndef SOUND_SUPPORT
|
||||
mySettings->setBool("sound", false);
|
||||
#endif
|
||||
|
|
|
@ -736,6 +736,10 @@
|
|||
RelativePath="..\gui\ListWidget.cxx"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\gui\LoggerDialog.cxx"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\gui\Menu.cxx"
|
||||
>
|
||||
|
@ -1550,6 +1554,10 @@
|
|||
RelativePath="..\gui\ListWidget.hxx"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\gui\LoggerDialog.hxx"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\gui\Menu.hxx"
|
||||
>
|
||||
|
|
Loading…
Reference in New Issue