New GUI, many changes
[pierogi] / keysets / dell.cpp
1 #include "dell.h"
2 #include "protocols/mceprotocol.h"
3
4
5 DellRemote1::DellRemote1(
6   unsigned int index)
7   : PIRKeysetMetaData(
8       "Remote Keyset 1",
9       Dell_Make,
10       index)
11 {
12 }
13
14
15 void DellRemote1::populateProtocol(
16   QObject *guiObject)
17 {
18   if (threadableProtocol)
19   {
20     // Keyset already populated.
21     return;
22   }
23
24   threadableProtocol = new MCEProtocol(guiObject, index, 0x801C);
25
26   setPreData(0x2B, 7);
27
28   addKey("vol_off", Mute_Key, 0x0D, 8);
29
30   addKey("vol+", VolumeUp_Key, 0x10, 8);
31   addKey("vol-", VolumeDown_Key, 0x11, 8);
32
33   addKey("next", Next_Key, 0x20, 8);
34   addKey("prev", Previous_Key, 0x21, 8);
35   addKey("play_pause", Play_Key, 0x2C, 8);
36   addKey("play_pause", Pause_Key, 0x2C, 8);
37   addKey("forward", FastForward_Key, 0x2E, 8);
38   addKey("rewind", Rewind_Key, 0x2F, 8);
39   addKey("stop", Stop_Key, 0x31, 8);
40
41   addKey("cross_up", Up_Key, 0x58, 8);
42   addKey("cross_down", Down_Key, 0x59, 8);
43   addKey("cross_left", Left_Key, 0x5A, 8);
44   addKey("cross_right", Right_Key, 0x5B, 8);
45   addKey("cross_enter", Select_Key, 0x5C, 8);
46
47   addKey("up", PageUp_Key, 0xCE, 8);
48   addKey("down", PageDown_Key, 0xCF, 8);
49
50   addKey("back", Exit_Key, 0xA4, 8);
51 }