From cc61b1641e6a009cb113dd088cbbb935b1f71886 Mon Sep 17 00:00:00 2001 From: TangoCash Date: Sat, 13 Oct 2018 00:11:06 +0200 Subject: [PATCH] remotetimers: fix fetch from other box Origin commit data ------------------ Commit: https://github.com/neutrino-images/ni-neutrino/commit/3eaac8f0d9831165d79535b8417931faddbcc1f4 Author: TangoCash Date: 2018-10-13 (Sat, 13 Oct 2018) --- lib/timerdclient/timerdclient.h | 4 ++-- src/gui/timerlist.cpp | 10 ++-------- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/lib/timerdclient/timerdclient.h b/lib/timerdclient/timerdclient.h index 40ee5a06f..610d28eba 100644 --- a/lib/timerdclient/timerdclient.h +++ b/lib/timerdclient/timerdclient.h @@ -111,7 +111,7 @@ class CTimerdClient:private CBasicClient // adds new record timer event int addRecordTimerEvent(const t_channel_id channel_id, time_t alarmtime, time_t stoptime, uint64_t epgID=0, time_t epg_starttime=0, time_t announcetime = 0, - unsigned char apids=TIMERD_APIDS_STD, bool safety=false,bool autoAdjust=false, std::string recDir="", bool forceAdd=true, bool channel_ci=false) //NI + unsigned char apids=TIMERD_APIDS_STD, bool safety=false,bool autoAdjust=false, std::string recDir="", bool forceAdd=true, bool channel_ci=false, CTimerd::CTimerEventRepeat evrepeat = CTimerd::TIMERREPEAT_ONCE, uint32_t repeatcount = 0) { CTimerd::RecordingInfo eventInfo; eventInfo.channel_id = channel_id; @@ -122,7 +122,7 @@ class CTimerdClient:private CBasicClient eventInfo.autoAdjustToEPG = autoAdjust; eventInfo.channel_ci = channel_ci; //NI strncpy(eventInfo.recordingDir, recDir.c_str(), RECORD_DIR_MAXLEN); - return addTimerEvent(CTimerd::TIMER_RECORD, &eventInfo, announcetime, alarmtime, stoptime,CTimerd::TIMERREPEAT_ONCE, 0,forceAdd); + return addTimerEvent(CTimerd::TIMER_RECORD, &eventInfo, announcetime, alarmtime, stoptime, evrepeat, repeatcount,forceAdd); }; int addImmediateRecordTimerEvent(const t_channel_id channel_id, time_t alarmtime, time_t stoptime, diff --git a/src/gui/timerlist.cpp b/src/gui/timerlist.cpp index f48947f98..2f89d0319 100644 --- a/src/gui/timerlist.cpp +++ b/src/gui/timerlist.cpp @@ -478,7 +478,7 @@ int CTimerList::exec(CMenuTarget* parent, const std::string & actionKey) int res = Timer->addRecordTimerEvent(timerlist[selected].channel_id, timerlist[selected].alarmTime + timerlist[selected].rem_pre, timerlist[selected].stopTime - timerlist[selected].rem_post, 0, 0, timerlist[selected].announceTime + timerlist[selected].rem_pre, - TIMERD_APIDS_CONF, true, timerlist[selected].announceTime > time(NULL),"",false); + TIMERD_APIDS_CONF, true, timerlist[selected].announceTime > time(NULL),"",false, false, timerlist[selected].eventRepeat, timerlist[selected].repeatCount); if (res == -1) { @@ -488,15 +488,9 @@ int CTimerList::exec(CMenuTarget* parent, const std::string & actionKey) { res = Timer->addRecordTimerEvent(timerlist[selected].channel_id, timerlist[selected].alarmTime + timerlist[selected].rem_pre, timerlist[selected].stopTime - timerlist[selected].rem_post, 0, 0, timerlist[selected].announceTime + timerlist[selected].rem_pre, - TIMERD_APIDS_CONF, true, timerlist[selected].announceTime > time(NULL),"",true); + TIMERD_APIDS_CONF, true, timerlist[selected].announceTime > time(NULL),"", true, false, timerlist[selected].eventRepeat, timerlist[selected].repeatCount); } } - if (res > 0) - Timer->modifyTimerEvent(res, timerlist[selected].announceTime + timerlist[selected].rem_pre, - timerlist[selected].alarmTime + timerlist[selected].rem_pre, - timerlist[selected].stopTime - timerlist[selected].rem_post, - timerlist[selected].eventRepeat, - timerlist[selected].repeatCount); CHTTPTool httpTool; std::string r_url;