From 134fd2c9418a2b2c45e962edc259fdefdc54a0c7 Mon Sep 17 00:00:00 2001 From: Andreas Mair Date: Sat, 9 Apr 2011 08:42:09 +0200 Subject: "Call plugin after playback" option only changes BACK/EXIT key, BLUE key always jumps to LiveTV (suggested by Brougs78 @vdr-portal.de) --- myreplaycontrol.c | 12 ++++++++---- myreplaycontrol.h | 1 + 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/myreplaycontrol.c b/myreplaycontrol.c index 856ccf4..0e472ed 100644 --- a/myreplaycontrol.c +++ b/myreplaycontrol.c @@ -16,16 +16,19 @@ using namespace std; myReplayControl::myReplayControl() { timesearchactive=false; + lastState = osUnknown; } myReplayControl::~myReplayControl() { - if(mysetup.ReturnToPlugin) + if(lastState == osRecordings && mysetup.ReturnToPlugin) cRemote::CallPlugin("extrecmenu"); } eOSState myReplayControl::ProcessKey(eKeys Key) { + lastState = osUnknown; + if(Key!=kNone) { if(timesearchactive && mysetup.UseCutterQueue) @@ -69,10 +72,11 @@ eOSState myReplayControl::ProcessKey(eKeys Key) if(Key==kRed) timesearchactive=true; } - if(Key==kBack) - return osEnd; } } - return cReplayControl::ProcessKey(Key); + lastState = cReplayControl::ProcessKey(Key); + if(lastState == osRecordings && mysetup.ReturnToPlugin == 0) + lastState = osEnd; + return lastState; } diff --git a/myreplaycontrol.h b/myreplaycontrol.h index 85bc179..ae4a9c0 100644 --- a/myreplaycontrol.h +++ b/myreplaycontrol.h @@ -2,6 +2,7 @@ class myReplayControl:public cReplayControl { private: bool timesearchactive; + eOSState lastState; public: myReplayControl(); ~myReplayControl(); -- cgit v1.2.3