mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 930532: Adjust '#if defined(MOZ_CUBEB)' checks to include cubeb-only static functions in AudioStream.cpp, to fix build warnings in non-cubeb builds. r=padenot
This commit is contained in:
parent
ee3e66ad1e
commit
fdf896f1df
@ -53,7 +53,9 @@ uint32_t AudioStream::mPreferredSampleRate = 0;
|
||||
* dumped-audio-<nnn>.wav, one per nsBufferedAudioStream created, containing
|
||||
* the audio for the stream including any skips due to underruns.
|
||||
*/
|
||||
#if defined(MOZ_CUBEB)
|
||||
static int gDumpedAudioCount = 0;
|
||||
#endif
|
||||
|
||||
static int PrefChanged(const char* aPref, void* aClosure)
|
||||
{
|
||||
@ -78,13 +80,13 @@ static int PrefChanged(const char* aPref, void* aClosure)
|
||||
return 0;
|
||||
}
|
||||
|
||||
#if defined(MOZ_CUBEB)
|
||||
static double GetVolumeScale()
|
||||
{
|
||||
MutexAutoLock lock(*gAudioPrefsLock);
|
||||
return gVolumeScale;
|
||||
}
|
||||
|
||||
#if defined(MOZ_CUBEB)
|
||||
static cubeb* gCubebContext;
|
||||
|
||||
static cubeb* GetCubebContext()
|
||||
@ -466,6 +468,7 @@ int AudioStream::PreferredSampleRate()
|
||||
return mPreferredSampleRate;
|
||||
}
|
||||
|
||||
#if defined(MOZ_CUBEB)
|
||||
static void SetUint16LE(uint8_t* aDest, uint16_t aValue)
|
||||
{
|
||||
aDest[0] = aValue & 0xFF;
|
||||
@ -535,7 +538,6 @@ WriteDumpFile(FILE* aDumpFile, AudioStream* aStream, uint32_t aFrames,
|
||||
fflush(aDumpFile);
|
||||
}
|
||||
|
||||
#if defined(MOZ_CUBEB)
|
||||
BufferedAudioStream::BufferedAudioStream()
|
||||
: mMonitor("BufferedAudioStream"), mLostFrames(0), mDumpFile(nullptr),
|
||||
mVolume(1.0), mBytesPerFrame(0), mState(INITIALIZED)
|
||||
|
Loading…
Reference in New Issue
Block a user