-
Notifications
You must be signed in to change notification settings - Fork 10
/
mediactrl.cpp
68 lines (59 loc) · 1.07 KB
/
mediactrl.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#include <stddef.h>
#include <stdtype.h>
#include "mediactrl.hpp"
#ifdef MEDIACTRL_WINKEYS
#include "mediactrl_WinKeys.hpp"
#endif
#ifdef MEDIACTRL_SMTC
#include "mediactrl_WinSMTC.hpp"
#endif
#ifdef MEDIACTRL_DBUS
#include "mediactrl_dbus.hpp"
#endif
MediaControl::MediaControl()
{
}
MediaControl::~MediaControl()
{
Deinit();
}
UINT8 MediaControl::Init(MediaInfo& mediaInfo)
{
return 0x00;
}
void MediaControl::Deinit(void)
{
return;
}
/*static*/ void MediaControl::SignalCB(MediaInfo* mInfo, void* userParam, UINT8 signalMask)
{
MediaControl* obj = static_cast<MediaControl*>(userParam);
obj->SignalHandler(signalMask);
return;
}
void MediaControl::SignalHandler(UINT8 signalMask)
{
return;
}
MediaControl* GetMediaControl(UINT8 mcSig)
{
switch(mcSig)
{
case MCTRLSIG_NONE:
return new MediaControl;
#ifdef MEDIACTRL_WINKEYS
case MCTRLSIG_WINKEY:
return new MediaCtrlMKeys;
#endif
#ifdef MEDIACTRL_SMTC
case MCTRLSIG_SMTC:
return new MediaCtrlSMTC;
#endif
#ifdef MEDIACTRL_DBUS
case MCTRLSIG_DBUS:
return new MediaCtrlDBus;
#endif
default:
return NULL;
}
}