MythTV  master
audiopulsehandler.h
Go to the documentation of this file.
1 #ifndef AUDIOPULSEHANDLER_H
2 #define AUDIOPULSEHANDLER_H
3 
4 #include <pulse/pulseaudio.h>
5 
6 class QThread;
7 
9 {
10  public:
12  {
16  };
17 
18  static bool Suspend(enum PulseAction action);
20  static bool g_pulseHandlerActive;
21 
22  ~PulseHandler(void);
23  bool Valid(void);
24 
25  pa_context_state m_ctxState {PA_CONTEXT_UNCONNECTED};
26  pa_context *m_ctx {nullptr};
28 
29  private:
30  PulseHandler(void) = default;
31  bool Init(void);
32  bool SuspendInternal(bool suspend);
33 
34  pa_mainloop *m_loop {nullptr};
35  bool m_initialised {false};
36  bool m_valid {false};
37  QThread *m_thread {nullptr};
38 };
39 
40 #endif // AUDIOPULSEHANDLER_H
PulseHandler::Suspend
static bool Suspend(enum PulseAction action)
Definition: audiopulsehandler.cpp:38
PulseHandler::m_ctx
pa_context * m_ctx
Definition: audiopulsehandler.h:26
PulseHandler::Valid
bool Valid(void)
Definition: audiopulsehandler.cpp:216
PulseHandler::m_loop
pa_mainloop * m_loop
Definition: audiopulsehandler.h:34
PulseHandler::PulseAction
PulseAction
Definition: audiopulsehandler.h:11
PulseHandler::m_pendingOperations
int m_pendingOperations
Definition: audiopulsehandler.h:27
PulseHandler::m_thread
QThread * m_thread
Definition: audiopulsehandler.h:37
PulseHandler::Init
bool Init(void)
Definition: audiopulsehandler.cpp:226
PulseHandler::~PulseHandler
~PulseHandler(void)
Definition: audiopulsehandler.cpp:196
PulseHandler::m_ctxState
pa_context_state m_ctxState
Definition: audiopulsehandler.h:25
PulseHandler
Definition: audiopulsehandler.h:8
PulseHandler::kPulseResume
@ kPulseResume
Definition: audiopulsehandler.h:14
PulseHandler::m_valid
bool m_valid
Definition: audiopulsehandler.h:36
PulseHandler::PulseHandler
PulseHandler(void)=default
PulseHandler::kPulseSuspend
@ kPulseSuspend
Definition: audiopulsehandler.h:13
PulseHandler::SuspendInternal
bool SuspendInternal(bool suspend)
Definition: audiopulsehandler.cpp:287
PulseHandler::g_pulseHandler
static PulseHandler * g_pulseHandler
Definition: audiopulsehandler.h:19
PulseHandler::m_initialised
bool m_initialised
Definition: audiopulsehandler.h:35
build_compdb.action
action
Definition: build_compdb.py:9
PulseHandler::kPulseCleanup
@ kPulseCleanup
Definition: audiopulsehandler.h:15
PulseHandler::g_pulseHandlerActive
static bool g_pulseHandlerActive
Definition: audiopulsehandler.h:20