From d5c85f5ff84ffea666c63eca5dbe04632283cb04 Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sun, 11 Sep 2005 18:00:00 +0200 Subject: =?UTF-8?q?Version=201.3.32=20-=20Added=20some=20missing=20braces?= =?UTF-8?q?=20in=20remux.c=20(thanks=20to=20Wayne=20Keer=20for=20reporting?= =?UTF-8?q?=20this=20one).=20-=20Removed=20unused=20MAINMENUENTRY=20from?= =?UTF-8?q?=20svdrpdemo.c=20(thanks=20to=20Udo=20Richter=20for=20reporting?= =?UTF-8?q?=20=20=20this=20one).=20-=20Fixed=20appending=20sequence=20end?= =?UTF-8?q?=20code=20in=20cDvbPlayer::Goto()=20(thanks=20to=20Reinhard=20N?= =?UTF-8?q?issl).=20-=20Fixed=20syncing=20in=20cRepacker=20(thanks=20to=20?= =?UTF-8?q?Reinhard=20Nissl).=20-=20Now=20always=20using=20stream=20id=200?= =?UTF-8?q?xE0=20for=20the=20video=20stream,=20to=20avoid=20problems=20wit?= =?UTF-8?q?h=20=20=20post=20processing=20tools=20that=20choke=20on=20diffe?= =?UTF-8?q?rent=20ids=20(suggested=20by=20Reinhard=20Nissl).=20-=20Updated?= =?UTF-8?q?=20the=20Estonian=20OSD=20texts=20(thanks=20to=20Arthur=20Konov?= =?UTF-8?q?alov).=20-=20Fixed=20cDvbPlayer::SkipFrames()=20to=20properly?= =?UTF-8?q?=20handle=20radio=20recordings=20(thanks=20to=20=20=20Reinhard?= =?UTF-8?q?=20Nissl).=20-=20Updated=20the=20Swedish=20OSD=20texts=20(thank?= =?UTF-8?q?s=20to=20Tomas=20Prybil).=20-=20Updated=20the=20Slovenian=20OSD?= =?UTF-8?q?=20texts=20(thanks=20to=20Matjaz=20Thaler).=20-=20Updated=20the?= =?UTF-8?q?=20Danish=20OSD=20texts=20(thanks=20to=20Mogens=20Elneff).=20-?= =?UTF-8?q?=20Made=20LIRC=20command=20parsing=20more=20robust=20(thanks=20?= =?UTF-8?q?to=20Ville=20Skytt=C3=A4).=20-=20Introduced=20a=20separate=20'p?= =?UTF-8?q?lugins-install'=20target=20in=20the=20Makefile=20(thanks=20to?= =?UTF-8?q?=20Daniel=20=20=20Thompson).=20-=20Re-introduced=20the=20code?= =?UTF-8?q?=20that=20waits=20for=20a=20tuner=20lock=20in=20VDR/device.c,?= =?UTF-8?q?=20since=20=20=20apparently=20some=20users=20actually=20need=20?= =?UTF-8?q?it.=20It's=20not=20active=20by=20default,=20you'll=20have=20=20?= =?UTF-8?q?=20to=20define=20the=20WAIT=5FFOR=5FTUNER=5FLOCK=20macro=20in?= =?UTF-8?q?=20that=20file=20if=20you=20need=20it=20(suggested=20=20=20by?= =?UTF-8?q?=20Malcolm=20Caldwell).=20-=20Adjusted=20the=20Makefile=20to=20?= =?UTF-8?q?the=20dvb-kernel=20driver=20on=20kernel=202.6=20and=20up=20(tha?= =?UTF-8?q?nks=20to=20=20=20Lauri=20Tischler).=20-=20Repeat=20keys=20are?= =?UTF-8?q?=20now=20ignored=20when=20waiting=20for=20a=20keypress=20to=20c?= =?UTF-8?q?ancel=20an=20operation=20=20=20(thanks=20to=20Marko=20M=C3=A4ke?= =?UTF-8?q?l=C3=A4).=20-=20The=20main=20menu=20function=20of=20a=20plugin?= =?UTF-8?q?=20can=20now=20be=20activated=20through=20a=20key=20macro=20of?= =?UTF-8?q?=20=20=20the=20form=20"@plugin"=20even=20if=20that=20plugin=20d?= =?UTF-8?q?oesn't=20have=20a=20main=20menu=20entry=20(using=20=20=20part?= =?UTF-8?q?=20of=20a=20patch=20by=20Hardy=20Flor,=20which=20originally=20i?= =?UTF-8?q?mplemented=20calling=20plugins=20from=20=20=20SVDRP).=20-=20The?= =?UTF-8?q?=20menu=20timeout=20handling=20is=20now=20done=20centrally=20in?= =?UTF-8?q?=20the=20main=20program=20loop.=20-=20Added=20missing=20help=20?= =?UTF-8?q?for=20the=20'help'=20keyword=20in=20the=20SVDRP=20command=20PLU?= =?UTF-8?q?G.=20-=20The=20main=20menu=20function=20of=20a=20plugin=20can?= =?UTF-8?q?=20now=20be=20called=20programmatically=20through=20=20=20the?= =?UTF-8?q?=20static=20function=20cRemote::CallPlugin().=20-=20The=20SVDRP?= =?UTF-8?q?=20command=20PLUG=20now=20has=20a=20new=20option=20'main'=20whi?= =?UTF-8?q?ch=20can=20be=20used=20to=20initiate=20=20=20a=20call=20to=20th?= =?UTF-8?q?e=20main=20menu=20function=20of=20a=20plugin=20(using=20part=20?= =?UTF-8?q?of=20a=20patch=20by=20Hardy=20Flor).=20-=20The=20new=20command?= =?UTF-8?q?=20line=20option=20'--vfat'=20can=20be=20used=20to=20make=20VDR?= =?UTF-8?q?=20encode=20special=20=20=20characters=20in=20recording=20file?= =?UTF-8?q?=20names,=20even=20if=20it=20wasn't=20compiled=20with=20VFAT=3D?= =?UTF-8?q?1=20=20=20(suggested=20by=20Peter=20Bieringer).=20The=20compile?= =?UTF-8?q?=20time=20option=20VFAT=20still=20exists=20and=20=20=20creates?= =?UTF-8?q?=20a=20VDR=20that=20always=20behaves=20as=20if=20it=20were=20ca?= =?UTF-8?q?lled=20with=20'--vfat'.=20-=20Replaced=20the=20':'=20delimiter?= =?UTF-8?q?=20between=20hour=20and=20minute=20in=20recording=20file=20name?= =?UTF-8?q?s=20with=20=20=20a=20'.'=20under=20Linux,=20too.=20Existing=20r?= =?UTF-8?q?ecordings=20with=20':'=20as=20delimiter=20will=20still=20work.?= =?UTF-8?q?=20-=20Implemented=20the=20SVDRP=20command=20MOVC=20(thanks=20t?= =?UTF-8?q?o=20Andreas=20Brachold).=20-=20Added=20support=20for=20multiple?= =?UTF-8?q?=20audio=20language=20codes=20in=20ISO639LanguageDescriptors=20?= =?UTF-8?q?to=20=20=20'libsi'=20(thanks=20to=20Marcel=20Wiesweg).=20-=20Ch?= =?UTF-8?q?anged=20the=20audio=20PID=20language=20codes=20to=20hold=20up?= =?UTF-8?q?=20to=20two=203=20letter=20codes,=20separated=20=20=20by=20'+',?= =?UTF-8?q?=20to=20store=20separate=20languages=20broadcast=20in=20two=20c?= =?UTF-8?q?hannel=20audio=20mode.=20-=20If=20the=20preferred=20audio=20lan?= =?UTF-8?q?guage=20is=20broadcast=20on=20a=20PID=20that=20has=20two=20diff?= =?UTF-8?q?erent=20=20=20languages=20in=20the=20two=20stereo=20channels,?= =?UTF-8?q?=20the=20audio=20channel=20is=20now=20properly=20set=20when=20?= =?UTF-8?q?=20=20switching=20to=20such=20a=20channel=20(thanks=20to=20Moge?= =?UTF-8?q?ns=20Elneff=20for=20his=20help=20in=20testing=20this).=20-=20Fi?= =?UTF-8?q?xed=20some=20typos=20in=20MANUAL=20(thanks=20to=20Ville=20Skytt?= =?UTF-8?q?=C3=A4).=20-=20Fixed=20the=20default=20value=20for=20"Setup/EPG?= =?UTF-8?q?=20bugfix=20level"=20(thanks=20to=20Ville=20Skytt=C3=A4=20for?= =?UTF-8?q?=20=20=20reporting=20this=20one).=20-=20Fixed=20defining=20time?= =?UTF-8?q?rs=20that=20only=20differ=20in=20the=20day=20of=20week=20(thank?= =?UTF-8?q?s=20to=20Patrick=20=20=20Rother=20for=20reporting=20this=20one)?= =?UTF-8?q?.=20-=20Fixed=20converting=20summary.vdr=20files=20that=20would?= =?UTF-8?q?=20result=20in=20a=20very=20long=20'short=20text'=20=20=20(than?= =?UTF-8?q?ks=20to=20Carsten=20Koch).=20-=20Implemented=20a=20hash=20for?= =?UTF-8?q?=20the=20channels=20to=20reduce=20the=20system=20load=20in=20th?= =?UTF-8?q?e=20EIT=20scanning=20=20=20thread=20(based=20on=20a=20patch=20b?= =?UTF-8?q?y=20Georg=20Acher).?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- vdr.c | 42 +++++++++++++++++++++++++++++++++++++----- 1 file changed, 37 insertions(+), 5 deletions(-) (limited to 'vdr.c') diff --git a/vdr.c b/vdr.c index c98ee0d..0e0e428 100644 --- a/vdr.c +++ b/vdr.c @@ -22,7 +22,7 @@ * * The project's page is at http://www.cadsoft.de/vdr * - * $Id: vdr.c 1.211 2005/08/21 08:47:06 kls Exp $ + * $Id: vdr.c 1.216 2005/09/04 08:57:15 kls Exp $ */ #include @@ -66,6 +66,7 @@ #define LASTCAMMENUTIMEOUT 3 // seconds to run the main loop 'fast' after a CAM menu has been closed // in order to react on a possible new CAM menu as soon as possible #define DEVICEREADYTIMEOUT 30 // seconds to wait until all devices are ready +#define MENUTIMEOUT 120 // seconds of user inactivity after which an OSD display is closed #define EXIT(v) { ExitCode = (v); goto Exit; } @@ -130,6 +131,9 @@ int main(int argc, char *argv[]) #elif defined(REMOTE_RCU) RcuDevice = RCU_DEVICE; #endif +#if defined(VFAT) + VfatFileSystem = true; +#endif cPluginManager PluginManager(DEFAULTPLUGINDIR); int ExitCode = 0; @@ -153,6 +157,7 @@ int main(int argc, char *argv[]) { "shutdown", required_argument, NULL, 's' }, { "terminal", required_argument, NULL, 't' }, { "version", no_argument, NULL, 'V' }, + { "vfat", no_argument, NULL, 'v' | 0x100 }, { "video", required_argument, NULL, 'v' }, { "watchdog", required_argument, NULL, 'w' }, { NULL } @@ -245,6 +250,9 @@ int main(int argc, char *argv[]) break; case 'V': DisplayVersion = true; break; + case 'v' | 0x100: + VfatFileSystem = true; + break; case 'v': VideoDirectory = optarg; while (optarg && *optarg && optarg[strlen(optarg) - 1] == '/') optarg[strlen(optarg) - 1] = 0; @@ -303,6 +311,8 @@ int main(int argc, char *argv[]) " -t TTY, --terminal=TTY controlling tty\n" " -v DIR, --video=DIR use DIR as video directory (default: %s)\n" " -V, --version print version information and exit\n" + " --vfat encode special characters in recording names to\n" + " avoid problems with VFAT file systems\n" " -w SEC, --watchdog=SEC activate the watchdog timer with a timeout of SEC\n" " seconds (default: %d); '0' disables the watchdog\n" "\n", @@ -695,7 +705,7 @@ int main(int argc, char *argv[]) Menu = new cMenuMain(cControl::Control()); Temp = NULL; break; - #define DirectMainFunction(function...)\ + #define DirectMainFunction(function)\ DELETENULL(Menu);\ if (cControl::Control())\ cControl::Control()->Hide();\ @@ -709,7 +719,25 @@ int main(int argc, char *argv[]) case kSetup: DirectMainFunction(osSetup); break; case kCommands: DirectMainFunction(osCommands); break; case kUser1 ... kUser9: cRemote::PutMacro(key); key = kNone; break; - case k_Plugin: DirectMainFunction(osPlugin, cRemote::GetPlugin()); break; + case k_Plugin: { + DELETENULL(Menu); + Temp = NULL; + if (cControl::Control()) + cControl::Control()->Hide(); + cPlugin *plugin = cPluginManager::GetPlugin(cRemote::GetPlugin()); + if (plugin) { + Menu = Temp = plugin->MainMenuAction(); + if (Menu) { + Menu->Show(); + if (Menu->IsMenu()) + ((cOsdMenu*)Menu)->Display(); + } + } + else + esyslog("ERROR: unknown plugin '%s'", cRemote::GetPlugin()); + key = kNone; // nobody else needs to see these keys + } + break; // Channel up/down: case kChanUp|k_Repeat: case kChanUp: @@ -790,8 +818,12 @@ int main(int argc, char *argv[]) Interact = Menu ? Menu : cControl::Control(); // might have been closed in the mean time if (Interact) { eOSState state = Interact->ProcessKey(key); - if (state == osUnknown && ISMODELESSKEY(key) && cControl::Control() && Interact != cControl::Control()) - state = cControl::Control()->ProcessKey(key); + if (state == osUnknown && Interact != cControl::Control()) { + if (ISMODELESSKEY(key) && cControl::Control()) + state = cControl::Control()->ProcessKey(key); + else if (time(NULL) - LastActivity > MENUTIMEOUT) + state = osEnd; + } switch (state) { case osPause: DELETENULL(Menu); cControl::Shutdown(); // just in case -- cgit v1.2.3