diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2001-09-16 15:06:54 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2001-09-16 15:06:54 +0200 |
commit | a4e97d871e2d85819d957f4df10ab650ef0447ab (patch) | |
tree | d02fdf273761d743c0c4afc1946f43885993566c /vdr.c | |
parent | 987a0e931cbd488be35fcf4d8979ea9cf7d17b63 (diff) | |
download | vdr-a4e97d871e2d85819d957f4df10ab650ef0447ab.tar.gz vdr-a4e97d871e2d85819d957f4df10ab650ef0447ab.tar.bz2 |
New keys 'Volume+', 'Volume-' and 'Mute'
Diffstat (limited to 'vdr.c')
-rw-r--r-- | vdr.c | 14 |
1 files changed, 13 insertions, 1 deletions
@@ -22,7 +22,7 @@ * * The project's page is at http://www.cadsoft.de/people/kls/vdr * - * $Id: vdr.c 1.72 2001/09/08 14:34:29 kls Exp $ + * $Id: vdr.c 1.73 2001/09/16 14:54:45 kls Exp $ */ #define _GNU_SOURCE @@ -52,6 +52,8 @@ #define SHUTDOWNWAIT 300 // seconds to wait in user prompt before automatic shutdown #define MANUALSTART 600 // seconds the next timer must be in the future to assume manual start +#define VOLUMEDELTA 5 // used to increase/decrease the volume + static int Interrupted = 0; static void SignalHandler(int signum) @@ -424,6 +426,16 @@ int main(int argc, char *argv[]) case kMenu: Menu = new cMenuMain(ReplayControl); break; // Viewing Control: case kOk: LastChannel = -1; break; // forces channel display + // Volume Control: + case kVolUp|k_Repeat: + case kVolUp: + case kVolDn|k_Repeat: + case kVolDn: + cDvbApi::PrimaryDvbApi->SetVolume(NORMALKEY(key) == kVolDn ? -VOLUMEDELTA : VOLUMEDELTA); + break; + case kMute: + cDvbApi::PrimaryDvbApi->ToggleMute(); + break; // Power off: case kPower: isyslog(LOG_INFO, "Power button pressed"); DELETENULL(*Interact); |