fixed deprecation in sound system wrapper
This commit is contained in:
@@ -135,7 +135,7 @@ HRESULT wiSound::ReadChunkData(HANDLE hFile, void * buffer, DWORD buffersize, DW
|
||||
hr = HRESULT_FROM_WIN32( GetLastError() );
|
||||
return hr;
|
||||
}
|
||||
HRESULT wiSound::OpenFile(TCHAR* strFileName)
|
||||
HRESULT wiSound::OpenFile(const TCHAR* strFileName)
|
||||
{
|
||||
HRESULT hr;
|
||||
|
||||
@@ -195,11 +195,11 @@ HRESULT wiSound::OpenFile(TCHAR* strFileName)
|
||||
}
|
||||
HRESULT wiSound::Load(wstring filename)
|
||||
{
|
||||
return OpenFile(filename._Myptr());
|
||||
return OpenFile(filename.data());
|
||||
}
|
||||
HRESULT wiSound::Load(string filename)
|
||||
{
|
||||
return OpenFile(wstring(filename.begin(),filename.end())._Myptr());
|
||||
return OpenFile(wstring(filename.begin(),filename.end()).data());
|
||||
}
|
||||
void wiSound::Stop(){
|
||||
StopSound();
|
||||
|
||||
@@ -53,7 +53,7 @@ protected:
|
||||
|
||||
HRESULT FindChunk(HANDLE hFile, DWORD fourcc, DWORD & dwChunkSize, DWORD & dwChunkDataPosition);
|
||||
HRESULT ReadChunkData(HANDLE hFile, void * buffer, DWORD buffersize, DWORD bufferoffset);
|
||||
HRESULT OpenFile(TCHAR*);
|
||||
HRESULT OpenFile(const TCHAR*);
|
||||
|
||||
HRESULT PlaySound(wiAudioEngine* engine);
|
||||
void StopSound();
|
||||
|
||||
Reference in New Issue
Block a user