Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] Re: multiple funktions on one key on the remote



Hi,

> [...] The reason I'm asking
> is that the remots play-key is yello, the stop-key green, the
> fast-forward-key blue and the rewind-key red. E.g. I would like to use
> the play-key as yellow key in the menue but as play-key when using
> mplayer. Is this possible? If not, I'd order a different remote.

No need to order a different remote. I had the same problem and
simply changed the key settings in mplayer plugin. This code change
in menu-mplayer.c works for me (same buttons on remote control):

    bool DoShowMode = true;
    switch (Key) {
      case kYellow:  player->Play(); break;

      case kPause:   player->Pause(); break;

      case kRed|k_Repeat:
      case kRed:   player->SkipSeconds(-60); break;

      case kBlue|k_Repeat:
      case kBlue:  player->SkipSeconds(60); break;

      case kGreen: player->Quit(); break;

// Previous code:
//    case kGreen|k_Repeat:                      // reserved for future use
//    case kGreen:   player->SkipPrev(); break;
//    case kYellow|k_Repeat:
//    case kYellow:  player->SkipNext(); break;

//    case kStop:
//    case kBlue:
//    case kBack:    Hide(); Stop(); return osEnd;

This requires the mplayer to be used in slave mode and you have to add
a quit method to player-mplayer.c and player-mplayer.h :

void cMPlayerPlayer::Quit(void)
{
  if(slave) {
    MPlayerControl("quit");
  }
}

Hope this helps,
Martin



-- 
Info:
To unsubscribe send a mail to ecartis@linuxtv.org with "unsubscribe vdr" as subject.



Home | Main Index | Thread Index