1.1 --- a/mplayer.c Sun Dec 12 11:31:54 2010 +0100
1.2 +++ b/mplayer.c Sun Dec 12 11:53:00 2010 +0100
1.3 @@ -1,7 +1,7 @@
1.4 /*
1.5 * MP3/MPlayer plugin to VDR (C++)
1.6 *
1.7 - * (C) 2001-2009 Stefan Huelswitt <s.huelswitt@gmx.de>
1.8 + * (C) 2001-2010 Stefan Huelswitt <s.huelswitt@gmx.de>
1.9 *
1.10 * This code is free software; you can redistribute it and/or
1.11 * modify it under the terms of the GNU General Public License
1.12 @@ -69,6 +69,7 @@
1.13 data=MPlayerSetup;
1.14 SetSection(tr("MPlayer"));
1.15 Add(new cMenuEditBoolItem(tr("Setup.MPlayer$Control mode"), &data.SlaveMode, tr("Traditional"), tr("Slave")));
1.16 + Add(new cMenuEditBoolItem(tr("Setup.MPlayer$Prev/Next keys"),&data.PrevNextKeyMode, tr("Chapter"), tr("Playlist")));
1.17 res[0]=tr("disabled");
1.18 res[1]=tr("global only");
1.19 res[2]=tr("local first");
1.20 @@ -88,6 +89,7 @@
1.21 SetupStore("ControlMode", MPlayerSetup.SlaveMode);
1.22 SetupStore("HideMainMenu",MPlayerSetup.HideMainMenu);
1.23 SetupStore("ResumeMode", MPlayerSetup.ResumeMode);
1.24 + SetupStore("PrevNextMode",MPlayerSetup.PrevNextKeyMode);
1.25 for(int i=0; i<10; i++) {
1.26 char name[16];
1.27 snprintf(name,sizeof(name),"KeyCmd%d",i);
1.28 @@ -368,17 +370,15 @@
1.29
1.30 case kRed: Jump(); break;
1.31
1.32 - case kGreen|k_Repeat: // temporary use
1.33 + case kGreen|k_Repeat:
1.34 case kGreen: player->SkipSeconds(-60); break;
1.35 case kYellow|k_Repeat:
1.36 case kYellow: player->SkipSeconds(60); break;
1.37 - // case kGreen|k_Repeat: // reserved for future use
1.38 - // case kGreen: player->SkipPrev(); break;
1.39 - // case kYellow|k_Repeat:
1.40 - // case kYellow: player->SkipNext(); break;
1.41 -
1.42 - case kBack:
1.43 - Hide();
1.44 +
1.45 + case kNext: player->SkipTrack(1,MPlayerSetup.PrevNextKeyMode!=0); break;
1.46 + case kPrev: player->SkipTrack(-1,MPlayerSetup.PrevNextKeyMode!=0); break;
1.47 +
1.48 + case kBack: Hide();
1.49 cRemote::CallPlugin(plugin_name);
1.50 return osBack;
1.51 case kStop:
1.52 @@ -393,12 +393,6 @@
1.53 case kAudio:
1.54 player->KeyCmd("switch_audio");
1.55 break;
1.56 - case kNext:
1.57 - player->KeyCmd("seek_chapter +1");
1.58 - break;
1.59 - case kPrev:
1.60 - player->KeyCmd("seek_chapter -1");
1.61 - break;
1.62 case k0:
1.63 case k1:
1.64 case k2:
1.65 @@ -696,6 +690,7 @@
1.66 if( !strcasecmp(Name, "ControlMode")) MPlayerSetup.SlaveMode = atoi(Value);
1.67 else if (!strcasecmp(Name, "HideMainMenu")) MPlayerSetup.HideMainMenu = atoi(Value);
1.68 else if (!strcasecmp(Name, "ResumeMode")) MPlayerSetup.ResumeMode = atoi(Value);
1.69 + else if (!strcasecmp(Name, "PrevNextMode")) MPlayerSetup.PrevNextKeyMode = atoi(Value);
1.70 else if (!strncasecmp(Name,"KeyCmd", 6) && strlen(Name)==7 && isdigit(Name[6]))
1.71 strn0cpy(MPlayerSetup.KeyCmd[Name[6]-'0'],Value,sizeof(MPlayerSetup.KeyCmd[0]));
1.72 else return false;
2.1 --- a/player-mplayer.c Sun Dec 12 11:31:54 2010 +0100
2.2 +++ b/player-mplayer.c Sun Dec 12 11:53:00 2010 +0100
2.3 @@ -1,7 +1,7 @@
2.4 /*
2.5 * MP3/MPlayer plugin to VDR (C++)
2.6 *
2.7 - * (C) 2001-2009 Stefan Huelswitt <s.huelswitt@gmx.de>
2.8 + * (C) 2001-2010 Stefan Huelswitt <s.huelswitt@gmx.de>
2.9 *
2.10 * This code is free software; you can redistribute it and/or
2.11 * modify it under the terms of the GNU General Public License
2.12 @@ -665,6 +665,17 @@
2.13 }
2.14 }
2.15
2.16 +void cMPlayerPlayer::SkipTrack(int dir, bool chapter)
2.17 +{
2.18 + if(slave) {
2.19 + bool p=false;
2.20 + if(playMode==pmPaused) { Play(); p=true; }
2.21 + MPlayerControl("%s %d",chapter ? "seek_chapter":"pt_step",dir);
2.22 + if(p) Pause();
2.23 + saveIndex=-1;
2.24 + }
2.25 +}
2.26 +
2.27 void cMPlayerPlayer::KeyCmd(const char *cmd)
2.28 {
2.29 if(slave) MPlayerControl(cmd);
3.1 --- a/player-mplayer.h Sun Dec 12 11:31:54 2010 +0100
3.2 +++ b/player-mplayer.h Sun Dec 12 11:53:00 2010 +0100
3.3 @@ -1,7 +1,7 @@
3.4 /*
3.5 * MP3/MPlayer plugin to VDR (C++)
3.6 *
3.7 - * (C) 2001-2006 Stefan Huelswitt <s.huelswitt@gmx.de>
3.8 + * (C) 2001-2010 Stefan Huelswitt <s.huelswitt@gmx.de>
3.9 *
3.10 * This code is free software; you can redistribute it and/or
3.11 * modify it under the terms of the GNU General Public License
3.12 @@ -80,6 +80,7 @@
3.13 void Play(void);
3.14 void Goto(int Index, bool percent, bool still);
3.15 void SkipSeconds(int secs);
3.16 + void SkipTrack(int dir, bool chapter);
3.17 void KeyCmd(const char *cmd);
3.18 char *GetCurrentName(void);
3.19 virtual bool GetIndex(int &Current, int &Total, bool SnapToIFrame);
4.1 --- a/po/ca_ES.po Sun Dec 12 11:31:54 2010 +0100
4.2 +++ b/po/ca_ES.po Sun Dec 12 11:53:00 2010 +0100
4.3 @@ -7,7 +7,7 @@
4.4 msgstr ""
4.5 "Project-Id-Version: VDR 1.5.9\n"
4.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
4.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
4.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
4.9 "PO-Revision-Date: 2007-08-27 16:33+0200\n"
4.10 "Last-Translator: Stefan Huelswitt <s.huelswitt@gmx.de>\n"
4.11 "Language-Team: <vdr@linuxtv.org>\n"
4.12 @@ -324,6 +324,15 @@
4.13 msgid "Slave"
4.14 msgstr "Esclau"
4.15
4.16 +msgid "Setup.MPlayer$Prev/Next keys"
4.17 +msgstr ""
4.18 +
4.19 +msgid "Chapter"
4.20 +msgstr ""
4.21 +
4.22 +msgid "Playlist"
4.23 +msgstr ""
4.24 +
4.25 msgid "global only"
4.26 msgstr ""
4.27
5.1 --- a/po/de_DE.po Sun Dec 12 11:31:54 2010 +0100
5.2 +++ b/po/de_DE.po Sun Dec 12 11:53:00 2010 +0100
5.3 @@ -7,7 +7,7 @@
5.4 msgstr ""
5.5 "Project-Id-Version: VDR 1.5.9\n"
5.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
5.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
5.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
5.9 "PO-Revision-Date: 2007-08-27 16:33+0200\n"
5.10 "Last-Translator: Stefan Huelswitt <s.huelswitt@gmx.de>\n"
5.11 "Language-Team: <vdr@linuxtv.org>\n"
5.12 @@ -324,6 +324,15 @@
5.13 msgid "Slave"
5.14 msgstr "Slave"
5.15
5.16 +msgid "Setup.MPlayer$Prev/Next keys"
5.17 +msgstr "Vor/Zurќck Taste"
5.18 +
5.19 +msgid "Chapter"
5.20 +msgstr "Kapitel"
5.21 +
5.22 +msgid "Playlist"
5.23 +msgstr "Abspielliste"
5.24 +
5.25 msgid "global only"
5.26 msgstr "nur global"
5.27
6.1 --- a/po/el_GR.po Sun Dec 12 11:31:54 2010 +0100
6.2 +++ b/po/el_GR.po Sun Dec 12 11:53:00 2010 +0100
6.3 @@ -7,7 +7,7 @@
6.4 msgstr ""
6.5 "Project-Id-Version: VDR 1.5.9\n"
6.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
6.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
6.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
6.9 "PO-Revision-Date: 2007-08-27 16:33+0200\n"
6.10 "Last-Translator: Stefan Huelswitt <s.huelswitt@gmx.de>\n"
6.11 "Language-Team: <vdr@linuxtv.org>\n"
6.12 @@ -324,6 +324,15 @@
6.13 msgid "Slave"
6.14 msgstr ""
6.15
6.16 +msgid "Setup.MPlayer$Prev/Next keys"
6.17 +msgstr ""
6.18 +
6.19 +msgid "Chapter"
6.20 +msgstr ""
6.21 +
6.22 +msgid "Playlist"
6.23 +msgstr ""
6.24 +
6.25 msgid "global only"
6.26 msgstr ""
6.27
7.1 --- a/po/es_ES.po Sun Dec 12 11:31:54 2010 +0100
7.2 +++ b/po/es_ES.po Sun Dec 12 11:53:00 2010 +0100
7.3 @@ -7,7 +7,7 @@
7.4 msgstr ""
7.5 "Project-Id-Version: VDR 1.5.9\n"
7.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
7.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
7.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
7.9 "PO-Revision-Date: 2007-08-27 16:33+0200\n"
7.10 "Last-Translator: Stefan Huelswitt <s.huelswitt@gmx.de>\n"
7.11 "Language-Team: <vdr@linuxtv.org>\n"
7.12 @@ -324,6 +324,15 @@
7.13 msgid "Slave"
7.14 msgstr "Esclavo"
7.15
7.16 +msgid "Setup.MPlayer$Prev/Next keys"
7.17 +msgstr ""
7.18 +
7.19 +msgid "Chapter"
7.20 +msgstr ""
7.21 +
7.22 +msgid "Playlist"
7.23 +msgstr ""
7.24 +
7.25 msgid "global only"
7.26 msgstr ""
7.27
8.1 --- a/po/fi_FI.po Sun Dec 12 11:31:54 2010 +0100
8.2 +++ b/po/fi_FI.po Sun Dec 12 11:53:00 2010 +0100
8.3 @@ -8,7 +8,7 @@
8.4 msgstr ""
8.5 "Project-Id-Version: VDR 1.5.9\n"
8.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
8.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
8.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
8.9 "PO-Revision-Date: 2007-08-27 16:33+0200\n"
8.10 "Last-Translator: Stefan Huelswitt <s.huelswitt@gmx.de>\n"
8.11 "Language-Team: <vdr@linuxtv.org>\n"
8.12 @@ -325,6 +325,15 @@
8.13 msgid "Slave"
8.14 msgstr "orja"
8.15
8.16 +msgid "Setup.MPlayer$Prev/Next keys"
8.17 +msgstr ""
8.18 +
8.19 +msgid "Chapter"
8.20 +msgstr ""
8.21 +
8.22 +msgid "Playlist"
8.23 +msgstr ""
8.24 +
8.25 msgid "global only"
8.26 msgstr "globaali"
8.27
9.1 --- a/po/fr_FR.po Sun Dec 12 11:31:54 2010 +0100
9.2 +++ b/po/fr_FR.po Sun Dec 12 11:53:00 2010 +0100
9.3 @@ -9,7 +9,7 @@
9.4 msgstr ""
9.5 "Project-Id-Version: VDR 1.5.9\n"
9.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
9.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
9.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
9.9 "PO-Revision-Date: 2007-08-27 16:33+0200\n"
9.10 "Last-Translator: Stefan Huelswitt <s.huelswitt@gmx.de>\n"
9.11 "Language-Team: <vdr@linuxtv.org>\n"
9.12 @@ -326,6 +326,15 @@
9.13 msgid "Slave"
9.14 msgstr "Esclave"
9.15
9.16 +msgid "Setup.MPlayer$Prev/Next keys"
9.17 +msgstr ""
9.18 +
9.19 +msgid "Chapter"
9.20 +msgstr ""
9.21 +
9.22 +msgid "Playlist"
9.23 +msgstr ""
9.24 +
9.25 msgid "global only"
9.26 msgstr "Global seulement"
9.27
10.1 --- a/po/it_IT.po Sun Dec 12 11:31:54 2010 +0100
10.2 +++ b/po/it_IT.po Sun Dec 12 11:53:00 2010 +0100
10.3 @@ -7,7 +7,7 @@
10.4 msgstr ""
10.5 "Project-Id-Version: VDR 1.5.9\n"
10.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
10.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
10.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
10.9 "PO-Revision-Date: 2008-06-25 23:37+0100\n"
10.10 "Last-Translator: Diego Pierotto <vdr-italian@tiscali.it>\n"
10.11 "Language-Team: <vdr@linuxtv.org>\n"
10.12 @@ -324,6 +324,15 @@
10.13 msgid "Slave"
10.14 msgstr "Esclavo"
10.15
10.16 +msgid "Setup.MPlayer$Prev/Next keys"
10.17 +msgstr ""
10.18 +
10.19 +msgid "Chapter"
10.20 +msgstr ""
10.21 +
10.22 +msgid "Playlist"
10.23 +msgstr ""
10.24 +
10.25 msgid "global only"
10.26 msgstr "solo globale"
10.27
11.1 --- a/po/ru_RU.po Sun Dec 12 11:31:54 2010 +0100
11.2 +++ b/po/ru_RU.po Sun Dec 12 11:53:00 2010 +0100
11.3 @@ -8,7 +8,7 @@
11.4 msgstr ""
11.5 "Project-Id-Version: VDR 1.5.9\n"
11.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
11.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
11.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
11.9 "PO-Revision-Date: 2008-03-12 19:50+0100\n"
11.10 "Last-Translator: Alexander <Bikalexander@gmail.com>\n"
11.11 "Language-Team: <vdr@linuxtv.org>\n"
11.12 @@ -326,6 +326,15 @@
11.13 msgid "Slave"
11.14 msgstr "расширенный"
11.15
11.16 +msgid "Setup.MPlayer$Prev/Next keys"
11.17 +msgstr ""
11.18 +
11.19 +msgid "Chapter"
11.20 +msgstr ""
11.21 +
11.22 +msgid "Playlist"
11.23 +msgstr ""
11.24 +
11.25 msgid "global only"
11.26 msgstr "только глобально"
11.27
12.1 --- a/po/sl_SI.po Sun Dec 12 11:31:54 2010 +0100
12.2 +++ b/po/sl_SI.po Sun Dec 12 11:53:00 2010 +0100
12.3 @@ -7,7 +7,7 @@
12.4 msgstr ""
12.5 "Project-Id-Version: VDR 1.5.9\n"
12.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
12.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
12.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
12.9 "PO-Revision-Date: 2007-08-27 16:33+0200\n"
12.10 "Last-Translator: Stefan Huelswitt <s.huelswitt@gmx.de>\n"
12.11 "Language-Team: <vdr@linuxtv.org>\n"
12.12 @@ -324,6 +324,15 @@
12.13 msgid "Slave"
12.14 msgstr ""
12.15
12.16 +msgid "Setup.MPlayer$Prev/Next keys"
12.17 +msgstr ""
12.18 +
12.19 +msgid "Chapter"
12.20 +msgstr ""
12.21 +
12.22 +msgid "Playlist"
12.23 +msgstr ""
12.24 +
12.25 msgid "global only"
12.26 msgstr ""
12.27
13.1 --- a/po/sv_SE.po Sun Dec 12 11:31:54 2010 +0100
13.2 +++ b/po/sv_SE.po Sun Dec 12 11:53:00 2010 +0100
13.3 @@ -7,7 +7,7 @@
13.4 msgstr ""
13.5 "Project-Id-Version: VDR 1.5.9\n"
13.6 "Report-Msgid-Bugs-To: <s.huelswitt@gmx.de>\n"
13.7 -"POT-Creation-Date: 2009-08-17 09:00-0400\n"
13.8 +"POT-Creation-Date: 2010-12-12 11:45+0100\n"
13.9 "PO-Revision-Date: 2007-08-27 16:33+0200\n"
13.10 "Last-Translator: Stefan Huelswitt <s.huelswitt@gmx.de>\n"
13.11 "Language-Team: <vdr@linuxtv.org>\n"
13.12 @@ -324,6 +324,15 @@
13.13 msgid "Slave"
13.14 msgstr "Slav"
13.15
13.16 +msgid "Setup.MPlayer$Prev/Next keys"
13.17 +msgstr ""
13.18 +
13.19 +msgid "Chapter"
13.20 +msgstr ""
13.21 +
13.22 +msgid "Playlist"
13.23 +msgstr ""
13.24 +
13.25 msgid "global only"
13.26 msgstr ""
13.27
14.1 --- a/setup-mplayer.c Sun Dec 12 11:31:54 2010 +0100
14.2 +++ b/setup-mplayer.c Sun Dec 12 11:53:00 2010 +0100
14.3 @@ -1,7 +1,7 @@
14.4 /*
14.5 * MP3/MPlayer plugin to VDR (C++)
14.6 *
14.7 - * (C) 2001-2009 Stefan Huelswitt <s.huelswitt@gmx.de>
14.8 + * (C) 2001-2010 Stefan Huelswitt <s.huelswitt@gmx.de>
14.9 *
14.10 * This code is free software; you can redistribute it and/or
14.11 * modify it under the terms of the GNU General Public License
14.12 @@ -33,6 +33,7 @@
14.13 SlaveMode = 1;
14.14 ResumeMode = 2;
14.15 HideMainMenu = 0;
14.16 + PrevNextKeyMode = 0;
14.17 memset(KeyCmd,0,sizeof(KeyCmd));
14.18 strcpy(KeyCmd[1],"audio_delay +0.1");
14.19 strcpy(KeyCmd[7],"audio_delay -0.1");
15.1 --- a/setup-mplayer.h Sun Dec 12 11:31:54 2010 +0100
15.2 +++ b/setup-mplayer.h Sun Dec 12 11:53:00 2010 +0100
15.3 @@ -1,7 +1,7 @@
15.4 /*
15.5 * MP3/MPlayer plugin to VDR (C++)
15.6 *
15.7 - * (C) 2001-2009 Stefan Huelswitt <s.huelswitt@gmx.de>
15.8 + * (C) 2001-2010 Stefan Huelswitt <s.huelswitt@gmx.de>
15.9 *
15.10 * This code is free software; you can redistribute it and/or
15.11 * modify it under the terms of the GNU General Public License
15.12 @@ -33,6 +33,7 @@
15.13 int SlaveMode;
15.14 int ResumeMode;
15.15 int HideMainMenu;
15.16 + int PrevNextKeyMode;
15.17 char KeyCmd[10][MAX_KEYCMD];
15.18 public:
15.19 cMPlayerSetup(void);