1
0
mirror of https://github.com/VDR4Arch/vdr.git synced 2023-10-10 13:36:52 +02:00

Improved responsiveness inside CAM menus

This commit is contained in:
Klaus Schmidinger 2005-08-20 11:24:42 +02:00
parent 101ee309e5
commit 7683e67826
3 changed files with 18 additions and 6 deletions

View File

@ -3699,3 +3699,7 @@ Video Disk Recorder Revision History
this).
- Removed the VIDEO_STILLPICTURE_WORKS_WITH_VDR_FRAMES stuff from
cDvbDevice::StillPicture(), since apparently the VIDEO_STILLPICTURE call works.
2005-08-20: Version 1.3.30
- Improved responsiveness inside CAM menus.

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: config.h 1.223 2005/08/13 09:43:27 kls Exp $
* $Id: config.h 1.224 2005/08/20 10:29:35 kls Exp $
*/
#ifndef __CONFIG_H
@ -20,8 +20,8 @@
#include "i18n.h"
#include "tools.h"
#define VDRVERSION "1.3.29"
#define VDRVERSNUM 10329 // Version * 10000 + Major * 100 + Minor
#define VDRVERSION "1.3.30"
#define VDRVERSNUM 10330 // Version * 10000 + Major * 100 + Minor
#define MAXPRIORITY 99
#define MAXLIFETIME 99

14
vdr.c
View File

@ -22,7 +22,7 @@
*
* The project's page is at http://www.cadsoft.de/vdr
*
* $Id: vdr.c 1.209 2005/07/31 11:25:16 kls Exp $
* $Id: vdr.c 1.210 2005/08/20 11:24:42 kls Exp $
*/
#include <getopt.h>
@ -63,6 +63,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 CHANNELSAVEDELTA 600 // seconds before saving channels.conf after automatic modifications
#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 EXIT(v) { ExitCode = (v); goto Exit; }
@ -389,6 +391,7 @@ int main(int argc, char *argv[])
int PreviousChannelIndex = 0;
time_t LastChannelChanged = time(NULL);
time_t LastActivity = 0;
time_t LastCamMenu = 0;
int MaxLatencyTime = 0;
bool ForceShutdown = false;
bool UserShutdown = false;
@ -660,11 +663,16 @@ int main(int argc, char *argv[])
if (!Menu && Recordings.NeedsUpdate())
Recordings.Load();
// CAM control:
if (!Menu && !cOsd::IsOpen())
if (!Menu && !cOsd::IsOpen()) {
Menu = CamControl();
if (Menu)
LastCamMenu = 0;
else if (!LastCamMenu)
LastCamMenu = time(NULL);
}
// User Input:
cOsdObject *Interact = Menu ? Menu : cControl::Control();
eKeys key = Interface->GetKey(!Interact || !Interact->NeedsFastResponse());
eKeys key = Interface->GetKey((!Interact || !Interact->NeedsFastResponse()) && time(NULL) - LastCamMenu > LASTCAMMENUTIMEOUT);
if (NORMALKEY(key) != kNone) {
EITScanner.Activity();
LastActivity = time(NULL);