Cleanup WINDOWS and HAS_WASAPI usages

This commit is contained in:
badaix 2020-05-07 22:38:25 +02:00
parent d7c39bf13b
commit 860c0e5c8f
2 changed files with 6 additions and 3 deletions

View file

@ -44,7 +44,7 @@
#ifdef HAS_COREAUDIO #ifdef HAS_COREAUDIO
#include "player/coreaudio_player.hpp" #include "player/coreaudio_player.hpp"
#endif #endif
#ifdef WINDOWS #ifdef HAS_WASAPI
#include "player/wasapi_player.h" #include "player/wasapi_player.h"
#endif #endif

View file

@ -29,6 +29,9 @@
#ifdef HAS_ALSA #ifdef HAS_ALSA
#include "player/alsa_player.hpp" #include "player/alsa_player.hpp"
#endif #endif
#ifdef HAS_WASAPI
#include "player/wasapi_player.h"
#endif
#ifdef HAS_DAEMON #ifdef HAS_DAEMON
#include "common/daemon.hpp" #include "common/daemon.hpp"
#endif #endif
@ -49,7 +52,7 @@ static constexpr auto LOG_TAG = "Snapclient";
PcmDevice getPcmDevice(const std::string& soundcard) PcmDevice getPcmDevice(const std::string& soundcard)
{ {
#if defined(HAS_ALSA) || defined(WINDOWS) #if defined(HAS_ALSA) || defined(HAS_WASAPI)
vector<PcmDevice> pcmDevices = vector<PcmDevice> pcmDevices =
#ifdef HAS_ALSA #ifdef HAS_ALSA
AlsaPlayer::pcm_list(); AlsaPlayer::pcm_list();
@ -176,7 +179,7 @@ int main(int argc, char** argv)
exit(EXIT_SUCCESS); exit(EXIT_SUCCESS);
} }
#if defined(HAS_ALSA) || defined(WINDOWS) #if defined(HAS_ALSA) || defined(HAS_WASAPI)
if (listSwitch->is_set()) if (listSwitch->is_set())
{ {
vector<PcmDevice> pcmDevices = vector<PcmDevice> pcmDevices =