mirror of
https://projects.vdr-developer.org/git/vdr-plugin-tvguide.git
synced 2023-10-05 15:01:48 +02:00
Cosmetic changes / SwitchTimer& operator / std:min,std:max
This commit is contained in:
parent
6ae27238af
commit
bf2937d86c
@ -5,12 +5,12 @@ cChannelColumn::cChannelColumn(int num, const cChannel *channel, cMyTime *myTime
|
|||||||
this->channel = channel;
|
this->channel = channel;
|
||||||
this->num = num;
|
this->num = num;
|
||||||
this->myTime = myTime;
|
this->myTime = myTime;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
#else
|
#else
|
||||||
hasTimer = channel->HasTimer();
|
hasTimer = channel->HasTimer();
|
||||||
#endif
|
#endif
|
||||||
hasSwitchTimer = SwitchTimers.ChannelInSwitchList(channel);
|
hasSwitchTimer = SwitchTimers.ChannelInSwitchList(channel);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
#else
|
#else
|
||||||
schedulesLock = new cSchedulesLock(false, 100);
|
schedulesLock = new cSchedulesLock(false, 100);
|
||||||
#endif
|
#endif
|
||||||
@ -21,7 +21,7 @@ cChannelColumn::~cChannelColumn(void) {
|
|||||||
if (header)
|
if (header)
|
||||||
delete header;
|
delete header;
|
||||||
grids.Clear();
|
grids.Clear();
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
#else
|
#else
|
||||||
delete schedulesLock;
|
delete schedulesLock;
|
||||||
#endif
|
#endif
|
||||||
@ -42,7 +42,7 @@ void cChannelColumn::drawHeader() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
bool cChannelColumn::readGrids() {
|
bool cChannelColumn::readGrids() {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_SCHEDULES_READ;
|
LOCK_SCHEDULES_READ;
|
||||||
const cSchedules* schedules = Schedules;
|
const cSchedules* schedules = Schedules;
|
||||||
#else
|
#else
|
||||||
@ -200,7 +200,7 @@ void cChannelColumn::AddNewGridsAtStart() {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
//if not, i have to add new ones to the list
|
//if not, i have to add new ones to the list
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_SCHEDULES_READ;
|
LOCK_SCHEDULES_READ;
|
||||||
const cSchedules* schedules = Schedules;
|
const cSchedules* schedules = Schedules;
|
||||||
#else
|
#else
|
||||||
@ -253,7 +253,7 @@ void cChannelColumn::AddNewGridsAtEnd() {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
//if not, i have to add new ones to the list
|
//if not, i have to add new ones to the list
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_SCHEDULES_READ;
|
LOCK_SCHEDULES_READ;
|
||||||
const cSchedules* schedules = Schedules;
|
const cSchedules* schedules = Schedules;
|
||||||
#else
|
#else
|
||||||
@ -366,7 +366,7 @@ cGrid *cChannelColumn::addDummyGrid(time_t start, time_t end, cGrid *firstGrid,
|
|||||||
}
|
}
|
||||||
|
|
||||||
void cChannelColumn::SetTimers() {
|
void cChannelColumn::SetTimers() {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
#else
|
#else
|
||||||
hasTimer = channel->HasTimer();
|
hasTimer = channel->HasTimer();
|
||||||
#endif
|
#endif
|
||||||
|
@ -20,7 +20,7 @@ private:
|
|||||||
const cChannel *channel;
|
const cChannel *channel;
|
||||||
cHeaderGrid *header;
|
cHeaderGrid *header;
|
||||||
cList<cGrid> grids;
|
cList<cGrid> grids;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
#else
|
#else
|
||||||
cSchedulesLock *schedulesLock;
|
cSchedulesLock *schedulesLock;
|
||||||
#endif
|
#endif
|
||||||
@ -53,7 +53,7 @@ public:
|
|||||||
void ClearOutdatedEnd();
|
void ClearOutdatedEnd();
|
||||||
int GetNum() {return num;};
|
int GetNum() {return num;};
|
||||||
void SetNum(int num) {this->num = num;};
|
void SetNum(int num) {this->num = num;};
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
void setTimer();
|
void setTimer();
|
||||||
#else
|
#else
|
||||||
void setTimer() {hasTimer = channel->HasTimer();};
|
void setTimer() {hasTimer = channel->HasTimer();};
|
||||||
|
@ -10,7 +10,7 @@ cChannelGroups::~cChannelGroups(void) {
|
|||||||
void cChannelGroups::ReadChannelGroups(void) {
|
void cChannelGroups::ReadChannelGroups(void) {
|
||||||
bool setStart = false;
|
bool setStart = false;
|
||||||
int lastChannelNumber = 0;
|
int lastChannelNumber = 0;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *first = Channels->First();
|
const cChannel *first = Channels->First();
|
||||||
#else
|
#else
|
||||||
@ -20,7 +20,7 @@ void cChannelGroups::ReadChannelGroups(void) {
|
|||||||
channelGroups.push_back(cChannelGroup(tr("Main Program")));
|
channelGroups.push_back(cChannelGroup(tr("Main Program")));
|
||||||
setStart = true;
|
setStart = true;
|
||||||
}
|
}
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
for (const cChannel *channel = Channels->First(); channel; channel = Channels->Next(channel)) {
|
for (const cChannel *channel = Channels->First(); channel; channel = Channels->Next(channel)) {
|
||||||
#else
|
#else
|
||||||
for (const cChannel *channel = Channels.First(); channel; channel = Channels.Next(channel)) {
|
for (const cChannel *channel = Channels.First(); channel; channel = Channels.Next(channel)) {
|
||||||
@ -112,7 +112,7 @@ void cChannelGroups::DrawChannelGroups(const cChannel *start, const cChannel *st
|
|||||||
int groupLast = group;
|
int groupLast = group;
|
||||||
int line = 0;
|
int line = 0;
|
||||||
int lineStart = 0;
|
int lineStart = 0;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
for (const cChannel *channel = Channels->Next(start); channel; channel = Channels->Next(channel)) {
|
for (const cChannel *channel = Channels->Next(start); channel; channel = Channels->Next(channel)) {
|
||||||
#else
|
#else
|
||||||
|
@ -11,7 +11,7 @@ cChannelJump::cChannelJump(cChannelGroups *channelGroups) {
|
|||||||
pixmapText = NULL;
|
pixmapText = NULL;
|
||||||
channel = 0;
|
channel = 0;
|
||||||
if (!tvguideConfig.hideLastGroup) {
|
if (!tvguideConfig.hideLastGroup) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
maxChannels = Channels->MaxNumber();
|
maxChannels = Channels->MaxNumber();
|
||||||
#else
|
#else
|
||||||
|
@ -9,7 +9,7 @@ cDetailView::~cDetailView(void){
|
|||||||
Cancel(-1);
|
Cancel(-1);
|
||||||
while (Active())
|
while (Active())
|
||||||
cCondWait::SleepMs(10);
|
cCondWait::SleepMs(10);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
footer->LeaveDetailedViewMode(Channels->GetByChannelID(event->ChannelID()));
|
footer->LeaveDetailedViewMode(Channels->GetByChannelID(event->ChannelID()));
|
||||||
#else
|
#else
|
||||||
@ -47,7 +47,7 @@ void cDetailView::InitiateView(void) {
|
|||||||
dateTime = cString::sprintf("%s %s - %s (%d %s)", *event->GetDateString(), *event->GetTimeString(), *event->GetEndTimeString(), event->Duration()/60, tr("min"));
|
dateTime = cString::sprintf("%s %s - %s (%d %s)", *event->GetDateString(), *event->GetTimeString(), *event->GetEndTimeString(), event->Duration()/60, tr("min"));
|
||||||
}
|
}
|
||||||
view->SetDateTime(*dateTime);
|
view->SetDateTime(*dateTime);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
view->SetChannel(Channels->GetByChannelID(event->ChannelID(), true));
|
view->SetChannel(Channels->GetByChannelID(event->ChannelID(), true));
|
||||||
#else
|
#else
|
||||||
@ -100,7 +100,7 @@ std::string cDetailView::LoadReruns(void) {
|
|||||||
continue;
|
continue;
|
||||||
i++;
|
i++;
|
||||||
sstrReruns << *DayDateTime(r->event->StartTime());
|
sstrReruns << *DayDateTime(r->event->StartTime());
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *channel = Channels->GetByChannelID(r->event->ChannelID(), true, true);
|
const cChannel *channel = Channels->GetByChannelID(r->event->ChannelID(), true, true);
|
||||||
#else
|
#else
|
||||||
|
10
imagecache.c
10
imagecache.c
@ -280,7 +280,7 @@ void cImageCache::CreateLogoCache(void) {
|
|||||||
return;
|
return;
|
||||||
if (tvguideConfig.numLogosInitial > 0) {
|
if (tvguideConfig.numLogosInitial > 0) {
|
||||||
int channelsCached = 0;
|
int channelsCached = 0;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
for (const cChannel *channel = Channels->First(); channel; channel = Channels->Next(channel)) {
|
for (const cChannel *channel = Channels->First(); channel; channel = Channels->Next(channel)) {
|
||||||
#else
|
#else
|
||||||
@ -460,7 +460,7 @@ void cImageCache::AddCornersHorizontal(cImage *img, bool active) {
|
|||||||
}
|
}
|
||||||
if (!cornerLeft || !cornerRight)
|
if (!cornerLeft || !cornerRight)
|
||||||
return;
|
return;
|
||||||
int maxX = min(cornerWidth, imgWidth);
|
int maxX = std::min(cornerWidth, imgWidth);
|
||||||
for (int row = 0; row < cornerHeight; row++) {
|
for (int row = 0; row < cornerHeight; row++) {
|
||||||
for (int col = 0; col < maxX; ++col) {
|
for (int col = 0; col < maxX; ++col) {
|
||||||
img->SetPixel(cPoint(col, row), cornerLeft->GetPixel(cPoint(col, row)));
|
img->SetPixel(cPoint(col, row), cornerLeft->GetPixel(cPoint(col, row)));
|
||||||
@ -482,7 +482,7 @@ void cImageCache::AddCornersVertical(cImage *img, bool active) {
|
|||||||
}
|
}
|
||||||
if (!cornerHead || !cornerBottom)
|
if (!cornerHead || !cornerBottom)
|
||||||
return;
|
return;
|
||||||
int maxY = min(cornerHeight, imgHeight);
|
int maxY = std::min(cornerHeight, imgHeight);
|
||||||
for (int row = 0; row < maxY; row++) {
|
for (int row = 0; row < maxY; row++) {
|
||||||
for (int col = 0; col < cornerWidth; ++col) {
|
for (int col = 0; col < cornerWidth; ++col) {
|
||||||
img->SetPixel(cPoint(col, row), cornerHead->GetPixel(cPoint(col, row)));
|
img->SetPixel(cPoint(col, row), cornerHead->GetPixel(cPoint(col, row)));
|
||||||
@ -527,7 +527,7 @@ void cImageCache::AddCornersGroupHorizontal(cImage *img) {
|
|||||||
int imgWidth = img->Width();
|
int imgWidth = img->Width();
|
||||||
int imgHeight = img->Height();
|
int imgHeight = img->Height();
|
||||||
int heightHeadBottom = groupsHead->Height();
|
int heightHeadBottom = groupsHead->Height();
|
||||||
int maxY = min(heightHeadBottom, imgHeight);
|
int maxY = std::min(heightHeadBottom, imgHeight);
|
||||||
for (int row = 0; row < maxY; row++) {
|
for (int row = 0; row < maxY; row++) {
|
||||||
for (int col = 0; col < imgWidth; ++col) {
|
for (int col = 0; col < imgWidth; ++col) {
|
||||||
img->SetPixel(cPoint(col, row), groupsHead->GetPixel(cPoint(col, row)));
|
img->SetPixel(cPoint(col, row), groupsHead->GetPixel(cPoint(col, row)));
|
||||||
@ -542,7 +542,7 @@ void cImageCache::AddCornersGroupVertical(cImage *img) {
|
|||||||
int imgWidth = img->Width();
|
int imgWidth = img->Width();
|
||||||
int imgHeight = img->Height();
|
int imgHeight = img->Height();
|
||||||
int widthLeftRight = groupsLeft->Width();
|
int widthLeftRight = groupsLeft->Width();
|
||||||
int maxX = min(widthLeftRight, imgWidth);
|
int maxX = std::min(widthLeftRight, imgWidth);
|
||||||
for (int row = 0; row < imgHeight; row++) {
|
for (int row = 0; row < imgHeight; row++) {
|
||||||
for (int col = 0; col < maxX; ++col) {
|
for (int col = 0; col < maxX; ++col) {
|
||||||
img->SetPixel(cPoint(col, row), groupsLeft->GetPixel(cPoint(col, row)));
|
img->SetPixel(cPoint(col, row), groupsLeft->GetPixel(cPoint(col, row)));
|
||||||
|
64
recmanager.c
64
recmanager.c
@ -56,7 +56,7 @@ bool cRecManager::CheckEventForTimer(const cEvent *event) {
|
|||||||
return hasTimer;
|
return hasTimer;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *cRecManager::GetTimerForEvent(const cEvent *event) {
|
const cTimer *cRecManager::GetTimerForEvent(const cEvent *event) {
|
||||||
const cTimer *timer = NULL;
|
const cTimer *timer = NULL;
|
||||||
#else
|
#else
|
||||||
@ -68,7 +68,7 @@ cTimer *cRecManager::GetTimerForEvent(const cEvent *event) {
|
|||||||
rtMatch.event = event;
|
rtMatch.event = event;
|
||||||
pRemoteTimers->Service("RemoteTimers::GetMatch-v1.0", &rtMatch);
|
pRemoteTimers->Service("RemoteTimers::GetMatch-v1.0", &rtMatch);
|
||||||
timer = rtMatch.timer;
|
timer = rtMatch.timer;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
return timer;
|
return timer;
|
||||||
}
|
}
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
@ -92,7 +92,7 @@ cTimer *cRecManager::createTimer(const cEvent *event, std::string path) {
|
|||||||
|
|
||||||
cTimer *cRecManager::createLocalTimer(const cEvent *event, std::string path) {
|
cTimer *cRecManager::createLocalTimer(const cEvent *event, std::string path) {
|
||||||
cTimer *timer = new cTimer(event);
|
cTimer *timer = new cTimer(event);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_WRITE;
|
LOCK_TIMERS_WRITE;
|
||||||
cTimer *t = Timers->GetTimer(timer);
|
cTimer *t = Timers->GetTimer(timer);
|
||||||
#else
|
#else
|
||||||
@ -100,7 +100,7 @@ cTimer *cRecManager::createLocalTimer(const cEvent *event, std::string path) {
|
|||||||
#endif
|
#endif
|
||||||
if (t) {
|
if (t) {
|
||||||
t->OnOff();
|
t->OnOff();
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
t->SetEvent(event);
|
t->SetEvent(event);
|
||||||
#else
|
#else
|
||||||
t->SetEventFromSchedule();
|
t->SetEventFromSchedule();
|
||||||
@ -109,7 +109,7 @@ cTimer *cRecManager::createLocalTimer(const cEvent *event, std::string path) {
|
|||||||
timer = t;
|
timer = t;
|
||||||
isyslog("timer %s reactivated", *t->ToDescr());
|
isyslog("timer %s reactivated", *t->ToDescr());
|
||||||
} else {
|
} else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
Timers->Add(timer);
|
Timers->Add(timer);
|
||||||
#else
|
#else
|
||||||
Timers.Add(timer);
|
Timers.Add(timer);
|
||||||
@ -117,7 +117,7 @@ cTimer *cRecManager::createLocalTimer(const cEvent *event, std::string path) {
|
|||||||
isyslog("timer %s added (active)", *timer->ToDescr());
|
isyslog("timer %s added (active)", *timer->ToDescr());
|
||||||
}
|
}
|
||||||
SetTimerPath(timer, event, path);
|
SetTimerPath(timer, event, path);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
Timers->SetModified();
|
Timers->SetModified();
|
||||||
#else
|
#else
|
||||||
Timers.SetModified();
|
Timers.SetModified();
|
||||||
@ -178,7 +178,7 @@ void cRecManager::SetTimerPath(cTimer *timer, const cEvent *event, std::string p
|
|||||||
}
|
}
|
||||||
|
|
||||||
void cRecManager::DeleteTimer(int timerID) {
|
void cRecManager::DeleteTimer(int timerID) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *t = Timers->Get(timerID);
|
const cTimer *t = Timers->Get(timerID);
|
||||||
#else
|
#else
|
||||||
@ -200,7 +200,7 @@ void cRecManager::DeleteTimer(const cEvent *event) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void cRecManager::DeleteLocalTimer(const cEvent *event) {
|
void cRecManager::DeleteLocalTimer(const cEvent *event) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *t = Timers->GetMatch(event);
|
const cTimer *t = Timers->GetMatch(event);
|
||||||
#else
|
#else
|
||||||
@ -212,7 +212,7 @@ void cRecManager::DeleteLocalTimer(const cEvent *event) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
void cRecManager::DeleteTimer(const cTimer *timer) {
|
void cRecManager::DeleteTimer(const cTimer *timer) {
|
||||||
LOCK_TIMERS_WRITE;
|
LOCK_TIMERS_WRITE;
|
||||||
cTimers* timers = Timers;
|
cTimers* timers = Timers;
|
||||||
@ -230,7 +230,7 @@ void cRecManager::DeleteTimer(cTimer *timer) {
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
isyslog("timer %s deleted", *timer->ToDescr());
|
isyslog("timer %s deleted", *timer->ToDescr());
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
timers->Del(t, true);
|
timers->Del(t, true);
|
||||||
timers->SetModified();
|
timers->SetModified();
|
||||||
#else
|
#else
|
||||||
@ -253,7 +253,7 @@ void cRecManager::DeleteRemoteTimer(const cEvent *event) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
void cRecManager::SaveTimer(const cTimer *timer, cTimer newTimerSettings) {
|
void cRecManager::SaveTimer(const cTimer *timer, cTimer newTimerSettings) {
|
||||||
#else
|
#else
|
||||||
void cRecManager::SaveTimer(cTimer *timer, cTimer newTimerSettings) {
|
void cRecManager::SaveTimer(cTimer *timer, cTimer newTimerSettings) {
|
||||||
@ -269,7 +269,7 @@ void cRecManager::SaveTimer(cTimer *timer, cTimer newTimerSettings) {
|
|||||||
int stop = newTimerSettings.Stop();
|
int stop = newTimerSettings.Stop();
|
||||||
std::string fileName = newTimerSettings.File();
|
std::string fileName = newTimerSettings.File();
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
((cTimer*)timer)->SetDay(day);
|
((cTimer*)timer)->SetDay(day);
|
||||||
((cTimer*)timer)->SetStart(start);
|
((cTimer*)timer)->SetStart(start);
|
||||||
((cTimer*)timer)->SetStop(stop);
|
((cTimer*)timer)->SetStop(stop);
|
||||||
@ -286,7 +286,7 @@ void cRecManager::SaveTimer(cTimer *timer, cTimer newTimerSettings) {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (timer->HasFlags(tfActive) && !active)
|
if (timer->HasFlags(tfActive) && !active)
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
((cTimer*)timer)->ClrFlags(tfActive);
|
((cTimer*)timer)->ClrFlags(tfActive);
|
||||||
else if (!timer->HasFlags(tfActive) && active)
|
else if (!timer->HasFlags(tfActive) && active)
|
||||||
((cTimer*)timer)->SetFlags(tfActive);
|
((cTimer*)timer)->SetFlags(tfActive);
|
||||||
@ -300,7 +300,7 @@ void cRecManager::SaveTimer(cTimer *timer, cTimer newTimerSettings) {
|
|||||||
#endif
|
#endif
|
||||||
if (tvguideConfig.useRemoteTimers && pRemoteTimers) {
|
if (tvguideConfig.useRemoteTimers && pRemoteTimers) {
|
||||||
RemoteTimers_Timer_v1_0 rt;
|
RemoteTimers_Timer_v1_0 rt;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
rt.timer = (cTimer*)timer;
|
rt.timer = (cTimer*)timer;
|
||||||
#else
|
#else
|
||||||
rt.timer = timer;
|
rt.timer = timer;
|
||||||
@ -309,7 +309,7 @@ void cRecManager::SaveTimer(cTimer *timer, cTimer newTimerSettings) {
|
|||||||
rt.timer = NULL;
|
rt.timer = NULL;
|
||||||
RefreshRemoteTimers();
|
RefreshRemoteTimers();
|
||||||
} else {
|
} else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_WRITE;
|
LOCK_TIMERS_WRITE;
|
||||||
Timers->SetModified();
|
Timers->SetModified();
|
||||||
#else
|
#else
|
||||||
@ -320,7 +320,7 @@ void cRecManager::SaveTimer(cTimer *timer, cTimer newTimerSettings) {
|
|||||||
|
|
||||||
|
|
||||||
bool cRecManager::IsRecorded(const cEvent *event) {
|
bool cRecManager::IsRecorded(const cEvent *event) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_WRITE;
|
LOCK_TIMERS_WRITE;
|
||||||
cTimer *timer = Timers->GetMatch(event);
|
cTimer *timer = Timers->GetMatch(event);
|
||||||
#else
|
#else
|
||||||
@ -351,7 +351,7 @@ cTVGuideTimerConflicts *cRecManager::CheckTimerConflict(void) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void cRecManager::CreateSeriesTimer(cTimer *seriesTimer) {
|
void cRecManager::CreateSeriesTimer(cTimer *seriesTimer) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
#else
|
#else
|
||||||
seriesTimer->SetEventFromSchedule();
|
seriesTimer->SetEventFromSchedule();
|
||||||
#endif
|
#endif
|
||||||
@ -362,7 +362,7 @@ void cRecManager::CreateSeriesTimer(cTimer *seriesTimer) {
|
|||||||
isyslog("%s", *rt.errorMsg);
|
isyslog("%s", *rt.errorMsg);
|
||||||
RefreshRemoteTimers();
|
RefreshRemoteTimers();
|
||||||
} else {
|
} else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_WRITE;
|
LOCK_TIMERS_WRITE;
|
||||||
cTimers* timers = Timers;
|
cTimers* timers = Timers;
|
||||||
timers->Add(seriesTimer);
|
timers->Add(seriesTimer);
|
||||||
@ -417,7 +417,7 @@ const cEvent **cRecManager::PerformSearchTimerSearch(std::string epgSearchString
|
|||||||
numResults = results.size();
|
numResults = results.size();
|
||||||
if (numResults > 0) {
|
if (numResults > 0) {
|
||||||
searchResults = new const cEvent *[numResults];
|
searchResults = new const cEvent *[numResults];
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_SCHEDULES_READ;
|
LOCK_SCHEDULES_READ;
|
||||||
const cSchedules* schedules = Schedules;
|
const cSchedules* schedules = Schedules;
|
||||||
#else
|
#else
|
||||||
@ -434,7 +434,7 @@ const cEvent **cRecManager::PerformSearchTimerSearch(std::string epgSearchString
|
|||||||
int eventID = atoi(flds[1].c_str());
|
int eventID = atoi(flds[1].c_str());
|
||||||
std::string channelID = flds[7];
|
std::string channelID = flds[7];
|
||||||
tChannelID chanID = tChannelID::FromString(channelID.c_str());
|
tChannelID chanID = tChannelID::FromString(channelID.c_str());
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *channel = Channels->GetByChannelID(chanID);
|
const cChannel *channel = Channels->GetByChannelID(chanID);
|
||||||
#else
|
#else
|
||||||
@ -546,7 +546,7 @@ void cRecManager::DeleteSearchTimer(cTVGuideSearchTimer *searchTimer, bool delTi
|
|||||||
return;
|
return;
|
||||||
int searchTimerID = searchTimer->GetID();
|
int searchTimerID = searchTimer->GetID();
|
||||||
if (delTimers) {
|
if (delTimers) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_WRITE;
|
LOCK_TIMERS_WRITE;
|
||||||
cTimer *timer = Timers->First();
|
cTimer *timer = Timers->First();
|
||||||
#else
|
#else
|
||||||
@ -557,7 +557,7 @@ void cRecManager::DeleteSearchTimer(cTVGuideSearchTimer *searchTimer, bool delTi
|
|||||||
char* searchID = GetAuxValue(timer, "s-id");
|
char* searchID = GetAuxValue(timer, "s-id");
|
||||||
if (searchID) {
|
if (searchID) {
|
||||||
if (searchTimerID == atoi(searchID)) {
|
if (searchTimerID == atoi(searchID)) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cTimer* timerNext = Timers->Next(timer);
|
cTimer* timerNext = Timers->Next(timer);
|
||||||
#else
|
#else
|
||||||
cTimer* timerNext = Timers.Next(timer);
|
cTimer* timerNext = Timers.Next(timer);
|
||||||
@ -565,7 +565,7 @@ void cRecManager::DeleteSearchTimer(cTVGuideSearchTimer *searchTimer, bool delTi
|
|||||||
DeleteTimer(timer);
|
DeleteTimer(timer);
|
||||||
timer = timerNext;
|
timer = timerNext;
|
||||||
} else {
|
} else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
timer = Timers->Next(timer);
|
timer = Timers->Next(timer);
|
||||||
#else
|
#else
|
||||||
timer = Timers.Next(timer);
|
timer = Timers.Next(timer);
|
||||||
@ -573,14 +573,14 @@ void cRecManager::DeleteSearchTimer(cTVGuideSearchTimer *searchTimer, bool delTi
|
|||||||
}
|
}
|
||||||
free(searchID);
|
free(searchID);
|
||||||
} else {
|
} else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
timer = Timers->Next(timer);
|
timer = Timers->Next(timer);
|
||||||
#else
|
#else
|
||||||
timer = Timers.Next(timer);
|
timer = Timers.Next(timer);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
timer = Timers->Next(timer);
|
timer = Timers->Next(timer);
|
||||||
#else
|
#else
|
||||||
timer = Timers.Next(timer);
|
timer = Timers.Next(timer);
|
||||||
@ -637,7 +637,7 @@ void cRecManager::DeleteSwitchTimer(const cEvent *event) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cRecording **cRecManager::SearchForRecordings(std::string searchString, int &numResults) {
|
const cRecording **cRecManager::SearchForRecordings(std::string searchString, int &numResults) {
|
||||||
|
|
||||||
const cRecording **matchingRecordings = NULL;
|
const cRecording **matchingRecordings = NULL;
|
||||||
@ -649,7 +649,7 @@ cRecording **cRecManager::SearchForRecordings(std::string searchString, int &num
|
|||||||
int num = 0;
|
int num = 0;
|
||||||
numResults = 0;
|
numResults = 0;
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_RECORDINGS_READ;
|
LOCK_RECORDINGS_READ;
|
||||||
for (const cRecording *recording = Recordings->First(); recording; recording = Recordings->Next(recording)) {
|
for (const cRecording *recording = Recordings->First(); recording; recording = Recordings->Next(recording)) {
|
||||||
#else
|
#else
|
||||||
@ -685,7 +685,7 @@ cRecording **cRecManager::SearchForRecordings(std::string searchString, int &num
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (match) {
|
if (match) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
matchingRecordings = (const cRecording **)realloc(matchingRecordings, (num + 1) * sizeof(cRecording *));
|
matchingRecordings = (const cRecording **)realloc(matchingRecordings, (num + 1) * sizeof(cRecording *));
|
||||||
#else
|
#else
|
||||||
matchingRecordings = (cRecording **)realloc(matchingRecordings, (num + 1) * sizeof(cRecording *));
|
matchingRecordings = (cRecording **)realloc(matchingRecordings, (num + 1) * sizeof(cRecording *));
|
||||||
@ -766,7 +766,7 @@ void cRecManager::GetFavorites(std::vector<cTVGuideSearchTimer> *favorites) {
|
|||||||
|
|
||||||
const cEvent **cRecManager::WhatsOnNow(bool nowOrNext, int &numResults) {
|
const cEvent **cRecManager::WhatsOnNow(bool nowOrNext, int &numResults) {
|
||||||
std::vector<const cEvent*> tmpResults;
|
std::vector<const cEvent*> tmpResults;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_SCHEDULES_READ;
|
LOCK_SCHEDULES_READ;
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannels* channels = Channels;
|
const cChannels* channels = Channels;
|
||||||
@ -777,7 +777,7 @@ const cEvent **cRecManager::WhatsOnNow(bool nowOrNext, int &numResults) {
|
|||||||
#endif
|
#endif
|
||||||
const cChannel *startChannel = NULL, *stopChannel = NULL;
|
const cChannel *startChannel = NULL, *stopChannel = NULL;
|
||||||
if (tvguideConfig.favLimitChannels) {
|
if (tvguideConfig.favLimitChannels) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
startChannel = Channels->GetByNumber(tvguideConfig.favStartChannel);
|
startChannel = Channels->GetByNumber(tvguideConfig.favStartChannel);
|
||||||
stopChannel = Channels->GetByNumber(tvguideConfig.favStopChannel);
|
stopChannel = Channels->GetByNumber(tvguideConfig.favStopChannel);
|
||||||
}
|
}
|
||||||
@ -843,7 +843,7 @@ const cEvent **cRecManager::UserDefinedTime(int userTime, int &numResults) {
|
|||||||
if (searchTime < now)
|
if (searchTime < now)
|
||||||
searchTime += 24*60*60;
|
searchTime += 24*60*60;
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
LOCK_SCHEDULES_READ;
|
LOCK_SCHEDULES_READ;
|
||||||
const cChannels* channels = Channels;
|
const cChannels* channels = Channels;
|
||||||
@ -854,7 +854,7 @@ const cEvent **cRecManager::UserDefinedTime(int userTime, int &numResults) {
|
|||||||
#endif
|
#endif
|
||||||
const cChannel *startChannel = NULL, *stopChannel = NULL;
|
const cChannel *startChannel = NULL, *stopChannel = NULL;
|
||||||
if (tvguideConfig.favLimitChannels) {
|
if (tvguideConfig.favLimitChannels) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
startChannel = Channels->GetByNumber(tvguideConfig.favStartChannel);
|
startChannel = Channels->GetByNumber(tvguideConfig.favStartChannel);
|
||||||
stopChannel = Channels->GetByNumber(tvguideConfig.favStopChannel);
|
stopChannel = Channels->GetByNumber(tvguideConfig.favStopChannel);
|
||||||
}
|
}
|
||||||
|
@ -28,7 +28,7 @@ public:
|
|||||||
bool EpgSearchAvailable(void) {return epgSearchAvailable;};
|
bool EpgSearchAvailable(void) {return epgSearchAvailable;};
|
||||||
bool RefreshRemoteTimers(void);
|
bool RefreshRemoteTimers(void);
|
||||||
bool CheckEventForTimer(const cEvent *event);
|
bool CheckEventForTimer(const cEvent *event);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *GetTimerForEvent(const cEvent *event);
|
const cTimer *GetTimerForEvent(const cEvent *event);
|
||||||
#else
|
#else
|
||||||
cTimer *GetTimerForEvent(const cEvent *event);
|
cTimer *GetTimerForEvent(const cEvent *event);
|
||||||
@ -37,7 +37,7 @@ public:
|
|||||||
cTimer *createLocalTimer(const cEvent *event, std::string path);
|
cTimer *createLocalTimer(const cEvent *event, std::string path);
|
||||||
cTimer *createRemoteTimer(const cEvent *event, std::string path);
|
cTimer *createRemoteTimer(const cEvent *event, std::string path);
|
||||||
void SetTimerPath(cTimer *timer, const cEvent *event, std::string path);
|
void SetTimerPath(cTimer *timer, const cEvent *event, std::string path);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
void DeleteTimer(const cTimer *timer);
|
void DeleteTimer(const cTimer *timer);
|
||||||
#else
|
#else
|
||||||
void DeleteTimer(cTimer *timer);
|
void DeleteTimer(cTimer *timer);
|
||||||
@ -46,7 +46,7 @@ public:
|
|||||||
void DeleteTimer(const cEvent *event);
|
void DeleteTimer(const cEvent *event);
|
||||||
void DeleteLocalTimer(const cEvent *event);
|
void DeleteLocalTimer(const cEvent *event);
|
||||||
void DeleteRemoteTimer(const cEvent *event);
|
void DeleteRemoteTimer(const cEvent *event);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
void SaveTimer(const cTimer *timer, cTimer newTimerSettings);
|
void SaveTimer(const cTimer *timer, cTimer newTimerSettings);
|
||||||
#else
|
#else
|
||||||
void SaveTimer(cTimer *timer, cTimer newTimerSettings);
|
void SaveTimer(cTimer *timer, cTimer newTimerSettings);
|
||||||
@ -64,7 +64,7 @@ public:
|
|||||||
void UpdateSearchTimers(void);
|
void UpdateSearchTimers(void);
|
||||||
bool CreateSwitchTimer(const cEvent *event, cSwitchTimer switchTimer);
|
bool CreateSwitchTimer(const cEvent *event, cSwitchTimer switchTimer);
|
||||||
void DeleteSwitchTimer(const cEvent *event);
|
void DeleteSwitchTimer(const cEvent *event);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cRecording **SearchForRecordings(std::string searchString, int &numResults);
|
const cRecording **SearchForRecordings(std::string searchString, int &numResults);
|
||||||
#else
|
#else
|
||||||
cRecording **SearchForRecordings(std::string searchString, int &numResults);
|
cRecording **SearchForRecordings(std::string searchString, int &numResults);
|
||||||
|
@ -1817,7 +1817,7 @@ void cRecMenuItemEvent::Draw(void) {
|
|||||||
if (!event)
|
if (!event)
|
||||||
return;
|
return;
|
||||||
int logoX = DrawIcons();
|
int logoX = DrawIcons();
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *channel = Channels->GetByChannelID(event->ChannelID());
|
const cChannel *channel = Channels->GetByChannelID(event->ChannelID());
|
||||||
#else
|
#else
|
||||||
@ -1918,7 +1918,7 @@ eRecMenuState cRecMenuItemEvent::ProcessKey(eKeys Key) {
|
|||||||
|
|
||||||
// --- cRecMenuItemChannelChooser -------------------------------------------------------
|
// --- cRecMenuItemChannelChooser -------------------------------------------------------
|
||||||
cRecMenuItemChannelChooser::cRecMenuItemChannelChooser(cString text,
|
cRecMenuItemChannelChooser::cRecMenuItemChannelChooser(cString text,
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cChannel *initialChannel,
|
const cChannel *initialChannel,
|
||||||
#else
|
#else
|
||||||
cChannel *initialChannel,
|
cChannel *initialChannel,
|
||||||
@ -2007,7 +2007,7 @@ eRecMenuState cRecMenuItemChannelChooser::ProcessKey(eKeys Key) {
|
|||||||
fresh = true;
|
fresh = true;
|
||||||
if (!channel)
|
if (!channel)
|
||||||
return rmsConsumed;
|
return rmsConsumed;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cChannel *prev = channel;
|
const cChannel *prev = channel;
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *firstChannel = Channels->First();
|
const cChannel *firstChannel = Channels->First();
|
||||||
@ -2016,7 +2016,7 @@ eRecMenuState cRecMenuItemChannelChooser::ProcessKey(eKeys Key) {
|
|||||||
cChannel *firstChannel = Channels.First();
|
cChannel *firstChannel = Channels.First();
|
||||||
#endif
|
#endif
|
||||||
if(firstChannel->GroupSep())
|
if(firstChannel->GroupSep())
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
firstChannel = Channels->Next(firstChannel);
|
firstChannel = Channels->Next(firstChannel);
|
||||||
#else
|
#else
|
||||||
firstChannel = Channels.Next(firstChannel);
|
firstChannel = Channels.Next(firstChannel);
|
||||||
@ -2025,7 +2025,7 @@ eRecMenuState cRecMenuItemChannelChooser::ProcessKey(eKeys Key) {
|
|||||||
if (!initialChannelSet)
|
if (!initialChannelSet)
|
||||||
channel = NULL;
|
channel = NULL;
|
||||||
} else {
|
} else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
while (prev = Channels->Prev(prev)) {
|
while (prev = Channels->Prev(prev)) {
|
||||||
#else
|
#else
|
||||||
while (prev = Channels.Prev(prev)) {
|
while (prev = Channels.Prev(prev)) {
|
||||||
@ -2046,24 +2046,24 @@ eRecMenuState cRecMenuItemChannelChooser::ProcessKey(eKeys Key) {
|
|||||||
return rmsConsumed;
|
return rmsConsumed;
|
||||||
break; }
|
break; }
|
||||||
case kRight: {
|
case kRight: {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
#endif
|
#endif
|
||||||
fresh = true;
|
fresh = true;
|
||||||
if (!channel) {
|
if (!channel) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
channel = Channels->First();
|
channel = Channels->First();
|
||||||
#else
|
#else
|
||||||
channel = Channels.First();
|
channel = Channels.First();
|
||||||
#endif
|
#endif
|
||||||
if(channel->GroupSep())
|
if(channel->GroupSep())
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
channel = Channels->Next(channel);
|
channel = Channels->Next(channel);
|
||||||
#else
|
#else
|
||||||
channel = Channels.Next(channel);
|
channel = Channels.Next(channel);
|
||||||
#endif
|
#endif
|
||||||
} else {
|
} else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cChannel *next = channel;
|
const cChannel *next = channel;
|
||||||
while (next = Channels->Next(next)) {
|
while (next = Channels->Next(next)) {
|
||||||
#else
|
#else
|
||||||
@ -2091,7 +2091,7 @@ eRecMenuState cRecMenuItemChannelChooser::ProcessKey(eKeys Key) {
|
|||||||
fresh = false;
|
fresh = false;
|
||||||
}
|
}
|
||||||
channelNumber = channelNumber * 10 + (Key - k0);
|
channelNumber = channelNumber * 10 + (Key - k0);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *chanNew = Channels->GetByNumber(channelNumber);
|
const cChannel *chanNew = Channels->GetByNumber(channelNumber);
|
||||||
#else
|
#else
|
||||||
@ -2258,7 +2258,7 @@ eRecMenuState cRecMenuItemDayChooser::ProcessKey(eKeys Key) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// --- cRecMenuItemRecording -------------------------------------------------------
|
// --- cRecMenuItemRecording -------------------------------------------------------
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuItemRecording::cRecMenuItemRecording(const cRecording *recording, bool active) {
|
cRecMenuItemRecording::cRecMenuItemRecording(const cRecording *recording, bool active) {
|
||||||
#else
|
#else
|
||||||
cRecMenuItemRecording::cRecMenuItemRecording(cRecording *recording, bool active) {
|
cRecMenuItemRecording::cRecMenuItemRecording(cRecording *recording, bool active) {
|
||||||
@ -2290,7 +2290,7 @@ void cRecMenuItemRecording::Draw(void) {
|
|||||||
if (!recording)
|
if (!recording)
|
||||||
return;
|
return;
|
||||||
const cRecordingInfo *recInfo = recording->Info();
|
const cRecordingInfo *recInfo = recording->Info();
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *channel = Channels->GetByChannelID(recInfo->ChannelID());
|
const cChannel *channel = Channels->GetByChannelID(recInfo->ChannelID());
|
||||||
#else
|
#else
|
||||||
@ -2510,7 +2510,7 @@ void cRecMenuItemTimelineHeader::Show(void) {
|
|||||||
|
|
||||||
|
|
||||||
// --- cRecMenuItemTimelineTimer -------------------------------------------------------
|
// --- cRecMenuItemTimelineTimer -------------------------------------------------------
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuItemTimelineTimer::cRecMenuItemTimelineTimer(const cTimer *timer, time_t start, time_t stop, std::vector<cTVGuideTimerConflict*> conflictsToday, cRecMenuItemTimelineHeader *header, bool active) {
|
cRecMenuItemTimelineTimer::cRecMenuItemTimelineTimer(const cTimer *timer, time_t start, time_t stop, std::vector<cTVGuideTimerConflict*> conflictsToday, cRecMenuItemTimelineHeader *header, bool active) {
|
||||||
#else
|
#else
|
||||||
cRecMenuItemTimelineTimer::cRecMenuItemTimelineTimer(cTimer *timer, time_t start, time_t stop, std::vector<cTVGuideTimerConflict*> conflictsToday, cRecMenuItemTimelineHeader *header, bool active) {
|
cRecMenuItemTimelineTimer::cRecMenuItemTimelineTimer(cTimer *timer, time_t start, time_t stop, std::vector<cTVGuideTimerConflict*> conflictsToday, cRecMenuItemTimelineHeader *header, bool active) {
|
||||||
@ -2661,7 +2661,7 @@ void cRecMenuItemTimelineTimer::Show(void) {
|
|||||||
if (pixmapTimerConflicts) pixmapTimerConflicts->SetLayer(6);
|
if (pixmapTimerConflicts) pixmapTimerConflicts->SetLayer(6);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *cRecMenuItemTimelineTimer::GetTimerValue(void) {
|
const cTimer *cRecMenuItemTimelineTimer::GetTimerValue(void) {
|
||||||
#else
|
#else
|
||||||
cTimer *cRecMenuItemTimelineTimer::GetTimerValue(void) {
|
cTimer *cRecMenuItemTimelineTimer::GetTimerValue(void) {
|
||||||
|
@ -123,7 +123,7 @@ public:
|
|||||||
virtual bool GetBoolValue(void) { return false; };
|
virtual bool GetBoolValue(void) { return false; };
|
||||||
virtual cString GetStringValue(void) { return cString(""); };
|
virtual cString GetStringValue(void) { return cString(""); };
|
||||||
virtual const cEvent *GetEventValue(void) { return NULL; };
|
virtual const cEvent *GetEventValue(void) { return NULL; };
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
virtual const cTimer *GetTimerValue(void) { return NULL; };
|
virtual const cTimer *GetTimerValue(void) { return NULL; };
|
||||||
#else
|
#else
|
||||||
virtual cTimer *GetTimerValue(void) { return NULL; };
|
virtual cTimer *GetTimerValue(void) { return NULL; };
|
||||||
@ -493,7 +493,7 @@ public:
|
|||||||
class cRecMenuItemChannelChooser : public cRecMenuItem {
|
class cRecMenuItemChannelChooser : public cRecMenuItem {
|
||||||
private:
|
private:
|
||||||
cString text;
|
cString text;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cChannel *channel;
|
const cChannel *channel;
|
||||||
#else
|
#else
|
||||||
cChannel *channel;
|
cChannel *channel;
|
||||||
@ -506,7 +506,7 @@ private:
|
|||||||
void DrawValue(void);
|
void DrawValue(void);
|
||||||
public:
|
public:
|
||||||
cRecMenuItemChannelChooser (cString text,
|
cRecMenuItemChannelChooser (cString text,
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cChannel *initialChannel,
|
const cChannel *initialChannel,
|
||||||
#else
|
#else
|
||||||
cChannel *initialChannel,
|
cChannel *initialChannel,
|
||||||
@ -560,14 +560,14 @@ public:
|
|||||||
// --- cRecMenuItemRecording -------------------------------------------------------
|
// --- cRecMenuItemRecording -------------------------------------------------------
|
||||||
class cRecMenuItemRecording : public cRecMenuItem {
|
class cRecMenuItemRecording : public cRecMenuItem {
|
||||||
private:
|
private:
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cRecording *recording;
|
const cRecording *recording;
|
||||||
#else
|
#else
|
||||||
cRecording *recording;
|
cRecording *recording;
|
||||||
#endif
|
#endif
|
||||||
cPixmap *pixmapText;
|
cPixmap *pixmapText;
|
||||||
public:
|
public:
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuItemRecording(const cRecording *recording, bool active);
|
cRecMenuItemRecording(const cRecording *recording, bool active);
|
||||||
#else
|
#else
|
||||||
cRecMenuItemRecording(cRecording *recording, bool active);
|
cRecMenuItemRecording(cRecording *recording, bool active);
|
||||||
@ -583,7 +583,7 @@ public:
|
|||||||
class cRecMenuItemTimelineHeader : public cRecMenuItem {
|
class cRecMenuItemTimelineHeader : public cRecMenuItem {
|
||||||
private:
|
private:
|
||||||
time_t day;
|
time_t day;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *timer;
|
const cTimer *timer;
|
||||||
#else
|
#else
|
||||||
cTimer *timer;
|
cTimer *timer;
|
||||||
@ -603,7 +603,7 @@ public:
|
|||||||
virtual ~cRecMenuItemTimelineHeader(void);
|
virtual ~cRecMenuItemTimelineHeader(void);
|
||||||
void SetDay(time_t day) { this->day = day; };
|
void SetDay(time_t day) { this->day = day; };
|
||||||
void SetPixmaps(void);
|
void SetPixmaps(void);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
void SetCurrentTimer(const cTimer *timer) { this->timer = timer; };
|
void SetCurrentTimer(const cTimer *timer) { this->timer = timer; };
|
||||||
#else
|
#else
|
||||||
void SetCurrentTimer(cTimer *timer) { this->timer = timer; };
|
void SetCurrentTimer(cTimer *timer) { this->timer = timer; };
|
||||||
@ -618,7 +618,7 @@ public:
|
|||||||
// --- cRecMenuItemTimelineTimer -------------------------------------------------------
|
// --- cRecMenuItemTimelineTimer -------------------------------------------------------
|
||||||
class cRecMenuItemTimelineTimer : public cRecMenuItem {
|
class cRecMenuItemTimelineTimer : public cRecMenuItem {
|
||||||
private:
|
private:
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *timer;
|
const cTimer *timer;
|
||||||
#else
|
#else
|
||||||
cTimer *timer;
|
cTimer *timer;
|
||||||
@ -637,7 +637,7 @@ private:
|
|||||||
void DrawTimerConflicts(void);
|
void DrawTimerConflicts(void);
|
||||||
void DrawNoTimerInfo(void);
|
void DrawNoTimerInfo(void);
|
||||||
public:
|
public:
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuItemTimelineTimer(const cTimer *timer, time_t start, time_t stop, std::vector<cTVGuideTimerConflict*> conflictsToday, cRecMenuItemTimelineHeader *header, bool active);
|
cRecMenuItemTimelineTimer(const cTimer *timer, time_t start, time_t stop, std::vector<cTVGuideTimerConflict*> conflictsToday, cRecMenuItemTimelineHeader *header, bool active);
|
||||||
#else
|
#else
|
||||||
cRecMenuItemTimelineTimer(cTimer *timer, time_t start, time_t stop, std::vector<cTVGuideTimerConflict*> conflictsToday, cRecMenuItemTimelineHeader *header, bool active);
|
cRecMenuItemTimelineTimer(cTimer *timer, time_t start, time_t stop, std::vector<cTVGuideTimerConflict*> conflictsToday, cRecMenuItemTimelineHeader *header, bool active);
|
||||||
@ -649,7 +649,7 @@ public:
|
|||||||
void Hide(void);
|
void Hide(void);
|
||||||
void Show(void);
|
void Show(void);
|
||||||
void Draw(void);
|
void Draw(void);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *GetTimerValue(void);
|
const cTimer *GetTimerValue(void);
|
||||||
#else
|
#else
|
||||||
cTimer *GetTimerValue(void);
|
cTimer *GetTimerValue(void);
|
||||||
|
@ -125,7 +125,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
timerIndex = menu->GetTimerConflictIndex();
|
timerIndex = menu->GetTimerConflictIndex();
|
||||||
} else break;
|
} else break;
|
||||||
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex);
|
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *t = Timers->Get(timerID);
|
const cTimer *t = Timers->Get(timerID);
|
||||||
#else
|
#else
|
||||||
@ -161,7 +161,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
timerIndex = menu->GetTimerConflictIndex();
|
timerIndex = menu->GetTimerConflictIndex();
|
||||||
} else break;
|
} else break;
|
||||||
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex);
|
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timer = Timers->Get(timerID);
|
const cTimer *timer = Timers->Get(timerID);
|
||||||
#else
|
#else
|
||||||
@ -177,7 +177,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
//caller: cRecMenuEditTimer
|
//caller: cRecMenuEditTimer
|
||||||
//save timer from current timer conflict
|
//save timer from current timer conflict
|
||||||
cTimer timerModified;
|
cTimer timerModified;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *originalTimer;
|
const cTimer *originalTimer;
|
||||||
#else
|
#else
|
||||||
cTimer *originalTimer;
|
cTimer *originalTimer;
|
||||||
@ -214,7 +214,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
break;
|
break;
|
||||||
case rmsEditTimer: {
|
case rmsEditTimer: {
|
||||||
//edit timer for active event
|
//edit timer for active event
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timer = recManager->GetTimerForEvent(event);
|
const cTimer *timer = recManager->GetTimerForEvent(event);
|
||||||
#else
|
#else
|
||||||
@ -230,7 +230,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
//caller: cRecMenuEditTimer
|
//caller: cRecMenuEditTimer
|
||||||
//save timer for active event
|
//save timer for active event
|
||||||
cTimer timerModified;
|
cTimer timerModified;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *originalTimer;
|
const cTimer *originalTimer;
|
||||||
#else
|
#else
|
||||||
cTimer *originalTimer;
|
cTimer *originalTimer;
|
||||||
@ -253,7 +253,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
recFolder = menu->GetFolder();
|
recFolder = menu->GetFolder();
|
||||||
}
|
}
|
||||||
delete activeMenu;
|
delete activeMenu;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *channel = Channels->GetByChannelID(event->ChannelID());
|
const cChannel *channel = Channels->GetByChannelID(event->ChannelID());
|
||||||
#else
|
#else
|
||||||
@ -500,7 +500,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
activeMenu = new cRecMenuRecordingSearch(searchString);
|
activeMenu = new cRecMenuRecordingSearch(searchString);
|
||||||
} else {
|
} else {
|
||||||
int numSearchResults = 0;
|
int numSearchResults = 0;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cRecording **searchResult = recManager->SearchForRecordings(searchString, numSearchResults);
|
const cRecording **searchResult = recManager->SearchForRecordings(searchString, numSearchResults);
|
||||||
#else
|
#else
|
||||||
cRecording **searchResult = recManager->SearchForRecordings(searchString, numSearchResults);
|
cRecording **searchResult = recManager->SearchForRecordings(searchString, numSearchResults);
|
||||||
@ -638,7 +638,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
timerConflict = menu->GetTimerConflictIndex();
|
timerConflict = menu->GetTimerConflictIndex();
|
||||||
} else break;
|
} else break;
|
||||||
int timerID = timerConflicts->GetCurrentConflictTimerID(timerConflict);
|
int timerID = timerConflicts->GetCurrentConflictTimerID(timerConflict);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timer = Timers->Get(timerID);
|
const cTimer *timer = Timers->Get(timerID);
|
||||||
#else
|
#else
|
||||||
@ -685,7 +685,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
originalConflictIndex = menu->GetTimerConflictIndex();
|
originalConflictIndex = menu->GetTimerConflictIndex();
|
||||||
} else break;
|
} else break;
|
||||||
int originalTimerID = timerConflicts->GetCurrentConflictTimerID(originalConflictIndex);
|
int originalTimerID = timerConflicts->GetCurrentConflictTimerID(originalConflictIndex);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timerOriginal = Timers->Get(originalTimerID);
|
const cTimer *timerOriginal = Timers->Get(originalTimerID);
|
||||||
#else
|
#else
|
||||||
@ -716,7 +716,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
activeMenu->Display();
|
activeMenu->Display();
|
||||||
break; }
|
break; }
|
||||||
case rmsTimelineTimerEdit: {
|
case rmsTimelineTimerEdit: {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *timer;
|
const cTimer *timer;
|
||||||
#else
|
#else
|
||||||
cTimer *timer;
|
cTimer *timer;
|
||||||
@ -732,7 +732,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
break;}
|
break;}
|
||||||
case rmsTimelineTimerSave: {
|
case rmsTimelineTimerSave: {
|
||||||
cTimer timerModified;
|
cTimer timerModified;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *originalTimer;
|
const cTimer *originalTimer;
|
||||||
#else
|
#else
|
||||||
cTimer *originalTimer;
|
cTimer *originalTimer;
|
||||||
@ -751,7 +751,7 @@ eOSState cRecMenuManager::StateMachine(eRecMenuState nextState) {
|
|||||||
activeMenu->Display();
|
activeMenu->Display();
|
||||||
break; }
|
break; }
|
||||||
case rmsTimelineTimerDelete: {
|
case rmsTimelineTimerDelete: {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *timer;
|
const cTimer *timer;
|
||||||
#else
|
#else
|
||||||
cTimer *timer;
|
cTimer *timer;
|
||||||
@ -872,7 +872,7 @@ void cRecMenuManager::DisplaySearchTimerList(void) {
|
|||||||
activeMenu->Display();
|
activeMenu->Display();
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
bool cRecMenuManager::DisplayTimerConflict(const cTimer *timer) {
|
bool cRecMenuManager::DisplayTimerConflict(const cTimer *timer) {
|
||||||
int timerID = 0;
|
int timerID = 0;
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
|
@ -23,7 +23,7 @@ private:
|
|||||||
void SetBackground(void);
|
void SetBackground(void);
|
||||||
void DeleteBackground(void);
|
void DeleteBackground(void);
|
||||||
void DisplaySearchTimerList(void);
|
void DisplaySearchTimerList(void);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
bool DisplayTimerConflict(const cTimer *timer);
|
bool DisplayTimerConflict(const cTimer *timer);
|
||||||
#else
|
#else
|
||||||
bool DisplayTimerConflict(cTimer *timer);
|
bool DisplayTimerConflict(cTimer *timer);
|
||||||
|
30
recmenus.c
30
recmenus.c
@ -105,7 +105,7 @@ std::string cRecMenuAskFolder::GetFolder(void) {
|
|||||||
// --- cRecMenuConfirmTimer ---------------------------------------------------------
|
// --- cRecMenuConfirmTimer ---------------------------------------------------------
|
||||||
cRecMenuConfirmTimer::cRecMenuConfirmTimer(const cEvent *event) {
|
cRecMenuConfirmTimer::cRecMenuConfirmTimer(const cEvent *event) {
|
||||||
SetWidthPercent(50);
|
SetWidthPercent(50);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cString channelName = Channels->GetByChannelID(event->ChannelID())->Name();
|
const cString channelName = Channels->GetByChannelID(event->ChannelID())->Name();
|
||||||
#else
|
#else
|
||||||
@ -148,7 +148,7 @@ cRecMenuConfirmTimer::cRecMenuConfirmTimer(const cEvent *event) {
|
|||||||
// --- cRecMenuConfirmDeleteTimer ---------------------------------------------------------
|
// --- cRecMenuConfirmDeleteTimer ---------------------------------------------------------
|
||||||
cRecMenuConfirmDeleteTimer::cRecMenuConfirmDeleteTimer(const cEvent *event) {
|
cRecMenuConfirmDeleteTimer::cRecMenuConfirmDeleteTimer(const cEvent *event) {
|
||||||
SetWidthPercent(50);
|
SetWidthPercent(50);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cString channelName = Channels->GetByChannelID(event->ChannelID())->Name();
|
const cString channelName = Channels->GetByChannelID(event->ChannelID())->Name();
|
||||||
#else
|
#else
|
||||||
@ -175,7 +175,7 @@ cRecMenuConfirmDeleteTimer::cRecMenuConfirmDeleteTimer(const cEvent *event) {
|
|||||||
// --- cRecMenuAskDeleteTimer ---------------------------------------------------------
|
// --- cRecMenuAskDeleteTimer ---------------------------------------------------------
|
||||||
cRecMenuAskDeleteTimer::cRecMenuAskDeleteTimer(const cEvent *event) {
|
cRecMenuAskDeleteTimer::cRecMenuAskDeleteTimer(const cEvent *event) {
|
||||||
SetWidthPercent(50);
|
SetWidthPercent(50);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cString channelName = Channels->GetByChannelID(event->ChannelID())->Name();
|
const cString channelName = Channels->GetByChannelID(event->ChannelID())->Name();
|
||||||
#else
|
#else
|
||||||
@ -243,7 +243,7 @@ cRecMenuTimerConflict::cRecMenuTimerConflict(cTVGuideTimerConflict *conflict) {
|
|||||||
SetFooter(new cRecMenuItemButton(tr("Ignore Conflict"), rmsIgnoreTimerConflict, false, true));
|
SetFooter(new cRecMenuItemButton(tr("Ignore Conflict"), rmsIgnoreTimerConflict, false, true));
|
||||||
int i=0;
|
int i=0;
|
||||||
for(std::vector<int>::iterator it = conflict->timerIDs.begin(); it != conflict->timerIDs.end(); it++) {
|
for(std::vector<int>::iterator it = conflict->timerIDs.begin(); it != conflict->timerIDs.end(); it++) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timer = Timers->Get(*it);
|
const cTimer *timer = Timers->Get(*it);
|
||||||
#else
|
#else
|
||||||
@ -272,7 +272,7 @@ cRecMenuTimerConflict::cRecMenuTimerConflict(cTVGuideTimerConflict *conflict) {
|
|||||||
|
|
||||||
cRecMenuItem *cRecMenuTimerConflict::GetMenuItem(int number) {
|
cRecMenuItem *cRecMenuTimerConflict::GetMenuItem(int number) {
|
||||||
if ((number >= 0) && (number < conflict->timerIDs.size())) {
|
if ((number >= 0) && (number < conflict->timerIDs.size())) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timer = Timers->Get(conflict->timerIDs[number]);
|
const cTimer *timer = Timers->Get(conflict->timerIDs[number]);
|
||||||
#else
|
#else
|
||||||
@ -378,7 +378,7 @@ cRecMenuNoRerunsFound::cRecMenuNoRerunsFound(cString searchString) {
|
|||||||
// --- cRecMenuConfirmRerunUsed ---------------------------------------------------------
|
// --- cRecMenuConfirmRerunUsed ---------------------------------------------------------
|
||||||
cRecMenuConfirmRerunUsed::cRecMenuConfirmRerunUsed(const cEvent *original, const cEvent *replace) {
|
cRecMenuConfirmRerunUsed::cRecMenuConfirmRerunUsed(const cEvent *original, const cEvent *replace) {
|
||||||
SetWidthPercent(70);
|
SetWidthPercent(70);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cString channelOrig = Channels->GetByChannelID(original->ChannelID())->Name();
|
const cString channelOrig = Channels->GetByChannelID(original->ChannelID())->Name();
|
||||||
const cString channelReplace = Channels->GetByChannelID(replace->ChannelID())->Name();
|
const cString channelReplace = Channels->GetByChannelID(replace->ChannelID())->Name();
|
||||||
@ -409,7 +409,7 @@ cRecMenuConfirmRerunUsed::cRecMenuConfirmRerunUsed(const cEvent *original, const
|
|||||||
}
|
}
|
||||||
|
|
||||||
// --- cRecMenuEditTimer ---------------------------------------------------------
|
// --- cRecMenuEditTimer ---------------------------------------------------------
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuEditTimer::cRecMenuEditTimer(const cTimer *timer, eRecMenuState nextState) {
|
cRecMenuEditTimer::cRecMenuEditTimer(const cTimer *timer, eRecMenuState nextState) {
|
||||||
const cTimer *originalTimer;
|
const cTimer *originalTimer;
|
||||||
#else
|
#else
|
||||||
@ -471,7 +471,7 @@ cRecMenuEditTimer::cRecMenuEditTimer(cTimer *timer, eRecMenuState nextState) {
|
|||||||
Arrange();
|
Arrange();
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *cRecMenuEditTimer::GetOriginalTimer(void) {
|
const cTimer *cRecMenuEditTimer::GetOriginalTimer(void) {
|
||||||
#else
|
#else
|
||||||
cTimer *cRecMenuEditTimer::GetOriginalTimer(void) {
|
cTimer *cRecMenuEditTimer::GetOriginalTimer(void) {
|
||||||
@ -513,7 +513,7 @@ cTimer cRecMenuEditTimer::GetTimer(void) {
|
|||||||
******************************************************************************************/
|
******************************************************************************************/
|
||||||
|
|
||||||
// --- cRecMenuSeriesTimer ---------------------------------------------------------
|
// --- cRecMenuSeriesTimer ---------------------------------------------------------
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuSeriesTimer::cRecMenuSeriesTimer(const cChannel *initialChannel, const cEvent *event, std::string folder) {
|
cRecMenuSeriesTimer::cRecMenuSeriesTimer(const cChannel *initialChannel, const cEvent *event, std::string folder) {
|
||||||
#else
|
#else
|
||||||
cRecMenuSeriesTimer::cRecMenuSeriesTimer(cChannel *initialChannel, const cEvent *event, std::string folder) {
|
cRecMenuSeriesTimer::cRecMenuSeriesTimer(cChannel *initialChannel, const cEvent *event, std::string folder) {
|
||||||
@ -552,7 +552,7 @@ cRecMenuSeriesTimer::cRecMenuSeriesTimer(cChannel *initialChannel, const cEvent
|
|||||||
}
|
}
|
||||||
|
|
||||||
cTimer *cRecMenuSeriesTimer::GetTimer(void) {
|
cTimer *cRecMenuSeriesTimer::GetTimer(void) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *chan = Channels->GetByNumber(channel);
|
const cChannel *chan = Channels->GetByNumber(channel);
|
||||||
#else
|
#else
|
||||||
@ -838,7 +838,7 @@ void cRecMenuSearchTimerEdit::InitMenuItems(void) {
|
|||||||
startChannel = 1;
|
startChannel = 1;
|
||||||
if (stopChannel == 0)
|
if (stopChannel == 0)
|
||||||
stopChannel = 1;
|
stopChannel = 1;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
useChannelSubMenu.push_back(new cRecMenuItemChannelChooser(tr("Start Channel"), Channels->GetByNumber(startChannel), false, &startChannel, rmsSearchTimerSave));
|
useChannelSubMenu.push_back(new cRecMenuItemChannelChooser(tr("Start Channel"), Channels->GetByNumber(startChannel), false, &startChannel, rmsSearchTimerSave));
|
||||||
useChannelSubMenu.push_back(new cRecMenuItemChannelChooser(tr("Stop Channel"), Channels->GetByNumber(stopChannel), false, &stopChannel, rmsSearchTimerSave));
|
useChannelSubMenu.push_back(new cRecMenuItemChannelChooser(tr("Stop Channel"), Channels->GetByNumber(stopChannel), false, &stopChannel, rmsSearchTimerSave));
|
||||||
@ -1269,7 +1269,7 @@ const cEvent *cRecMenuSearchResults::GetEvent(void) {
|
|||||||
// --- cRecMenuSearchConfirmTimer ---------------------------------------------------------
|
// --- cRecMenuSearchConfirmTimer ---------------------------------------------------------
|
||||||
cRecMenuSearchConfirmTimer::cRecMenuSearchConfirmTimer(const cEvent *event, eRecMenuState nextAction) {
|
cRecMenuSearchConfirmTimer::cRecMenuSearchConfirmTimer(const cEvent *event, eRecMenuState nextAction) {
|
||||||
SetWidthPercent(50);
|
SetWidthPercent(50);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cString channelName = Channels->GetByChannelID(event->ChannelID())->Name();
|
const cString channelName = Channels->GetByChannelID(event->ChannelID())->Name();
|
||||||
#else
|
#else
|
||||||
@ -1339,7 +1339,7 @@ cRecMenuRecordingSearch::cRecMenuRecordingSearch(std::string search) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// --- cRecMenuRecordingSearchResults ---------------------------------------------------------
|
// --- cRecMenuRecordingSearchResults ---------------------------------------------------------
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuRecordingSearchResults::cRecMenuRecordingSearchResults(std::string searchString, const cRecording **searchResults, int numResults) {
|
cRecMenuRecordingSearchResults::cRecMenuRecordingSearchResults(std::string searchString, const cRecording **searchResults, int numResults) {
|
||||||
#else
|
#else
|
||||||
cRecMenuRecordingSearchResults::cRecMenuRecordingSearchResults(std::string searchString, cRecording **searchResults, int numResults) {
|
cRecMenuRecordingSearchResults::cRecMenuRecordingSearchResults(std::string searchString, cRecording **searchResults, int numResults) {
|
||||||
@ -1427,7 +1427,7 @@ void cRecMenuTimeline::SetStartStop(void) {
|
|||||||
|
|
||||||
void cRecMenuTimeline::GetTimersForDay(void) {
|
void cRecMenuTimeline::GetTimersForDay(void) {
|
||||||
timersToday.clear();
|
timersToday.clear();
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimers* timers = Timers;
|
const cTimers* timers = Timers;
|
||||||
for (const cTimer *t = Timers->First(); t; t = Timers->Next(t)) {
|
for (const cTimer *t = Timers->First(); t; t = Timers->Next(t)) {
|
||||||
@ -1507,7 +1507,7 @@ void cRecMenuTimeline::ClearMenu(void) {
|
|||||||
header->UnsetCurrentTimer();
|
header->UnsetCurrentTimer();
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *cRecMenuTimeline::GetTimer(void) {
|
const cTimer *cRecMenuTimeline::GetTimer(void) {
|
||||||
#else
|
#else
|
||||||
cTimer *cRecMenuTimeline::GetTimer(void) {
|
cTimer *cRecMenuTimeline::GetTimer(void) {
|
||||||
|
14
recmenus.h
14
recmenus.h
@ -115,7 +115,7 @@ public:
|
|||||||
// --- cRecMenuEditTimer ---------------------------------------------------------
|
// --- cRecMenuEditTimer ---------------------------------------------------------
|
||||||
class cRecMenuEditTimer: public cRecMenu {
|
class cRecMenuEditTimer: public cRecMenu {
|
||||||
private:
|
private:
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *originalTimer;
|
const cTimer *originalTimer;
|
||||||
#else
|
#else
|
||||||
cTimer *originalTimer;
|
cTimer *originalTimer;
|
||||||
@ -128,7 +128,7 @@ private:
|
|||||||
int lifetime;
|
int lifetime;
|
||||||
char folder[TEXTINPUTLENGTH];
|
char folder[TEXTINPUTLENGTH];
|
||||||
public:
|
public:
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuEditTimer(const cTimer *timer, eRecMenuState nextState);
|
cRecMenuEditTimer(const cTimer *timer, eRecMenuState nextState);
|
||||||
const cTimer *GetOriginalTimer(void);
|
const cTimer *GetOriginalTimer(void);
|
||||||
#else
|
#else
|
||||||
@ -157,7 +157,7 @@ class cRecMenuSeriesTimer: public cRecMenu {
|
|||||||
int lifetime;
|
int lifetime;
|
||||||
void CalculateTimes(const cEvent *event);
|
void CalculateTimes(const cEvent *event);
|
||||||
public:
|
public:
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuSeriesTimer(const cChannel *initialChannel, const cEvent *event, std::string folder);
|
cRecMenuSeriesTimer(const cChannel *initialChannel, const cEvent *event, std::string folder);
|
||||||
#else
|
#else
|
||||||
cRecMenuSeriesTimer(cChannel *initialChannel, const cEvent *event, std::string folder);
|
cRecMenuSeriesTimer(cChannel *initialChannel, const cEvent *event, std::string folder);
|
||||||
@ -425,14 +425,14 @@ public:
|
|||||||
class cRecMenuRecordingSearchResults: public cRecMenu {
|
class cRecMenuRecordingSearchResults: public cRecMenu {
|
||||||
private:
|
private:
|
||||||
std::string searchString;
|
std::string searchString;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cRecording **searchResults;
|
const cRecording **searchResults;
|
||||||
#else
|
#else
|
||||||
cRecording **searchResults;
|
cRecording **searchResults;
|
||||||
#endif
|
#endif
|
||||||
int numResults;
|
int numResults;
|
||||||
public:
|
public:
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
cRecMenuRecordingSearchResults(std::string searchString, const cRecording **searchResults, int numResults);
|
cRecMenuRecordingSearchResults(std::string searchString, const cRecording **searchResults, int numResults);
|
||||||
#else
|
#else
|
||||||
cRecMenuRecordingSearchResults(std::string searchString, cRecording **searchResults, int numResults);
|
cRecMenuRecordingSearchResults(std::string searchString, cRecording **searchResults, int numResults);
|
||||||
@ -459,7 +459,7 @@ public:
|
|||||||
// --- cRecMenuTimeline ---------------------------------------------------------
|
// --- cRecMenuTimeline ---------------------------------------------------------
|
||||||
class cRecMenuTimeline: public cRecMenu {
|
class cRecMenuTimeline: public cRecMenu {
|
||||||
private:
|
private:
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
std::vector<const cTimer*> timersToday;
|
std::vector<const cTimer*> timersToday;
|
||||||
#else
|
#else
|
||||||
std::vector<cTimer*> timersToday;
|
std::vector<cTimer*> timersToday;
|
||||||
@ -484,7 +484,7 @@ public:
|
|||||||
virtual ~cRecMenuTimeline(void) {
|
virtual ~cRecMenuTimeline(void) {
|
||||||
};
|
};
|
||||||
eRecMenuState ProcessKey(eKeys Key);
|
eRecMenuState ProcessKey(eKeys Key);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cTimer *GetTimer(void);
|
const cTimer *GetTimer(void);
|
||||||
#else
|
#else
|
||||||
cTimer *GetTimer(void);
|
cTimer *GetTimer(void);
|
||||||
|
@ -16,7 +16,7 @@ cTVGuideSearchTimer::cTVGuideSearchTimer(void) {
|
|||||||
startTime = 0000;
|
startTime = 0000;
|
||||||
stopTime = 2359;
|
stopTime = 2359;
|
||||||
useChannel = false;
|
useChannel = false;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
channelMin = Channels->GetByNumber(cDevice::CurrentChannel());
|
channelMin = Channels->GetByNumber(cDevice::CurrentChannel());
|
||||||
channelMax = Channels->GetByNumber(cDevice::CurrentChannel());
|
channelMax = Channels->GetByNumber(cDevice::CurrentChannel());
|
||||||
@ -245,7 +245,7 @@ bool cTVGuideSearchTimer::Parse(bool readTemplate) {
|
|||||||
char *channelMinbuffer = NULL;
|
char *channelMinbuffer = NULL;
|
||||||
char *channelMaxbuffer = NULL;
|
char *channelMaxbuffer = NULL;
|
||||||
int channels = sscanf(values[value].c_str(), "%a[^|]|%a[^|]", &channelMinbuffer, &channelMaxbuffer);
|
int channels = sscanf(values[value].c_str(), "%a[^|]|%a[^|]", &channelMinbuffer, &channelMaxbuffer);
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
channelMin = Channels->GetByChannelID(tChannelID::FromString(channelMinbuffer), true, true);
|
channelMin = Channels->GetByChannelID(tChannelID::FromString(channelMinbuffer), true, true);
|
||||||
#else
|
#else
|
||||||
@ -258,7 +258,7 @@ bool cTVGuideSearchTimer::Parse(bool readTemplate) {
|
|||||||
if (channels == 1)
|
if (channels == 1)
|
||||||
channelMax = channelMin;
|
channelMax = channelMin;
|
||||||
else {
|
else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
channelMax = Channels->GetByChannelID(tChannelID::FromString(channelMaxbuffer), true, true);
|
channelMax = Channels->GetByChannelID(tChannelID::FromString(channelMaxbuffer), true, true);
|
||||||
#else
|
#else
|
||||||
channelMax = Channels.GetByChannelID(tChannelID::FromString(channelMaxbuffer), true, true);
|
channelMax = Channels.GetByChannelID(tChannelID::FromString(channelMaxbuffer), true, true);
|
||||||
@ -526,7 +526,7 @@ int cTVGuideSearchTimer::GetNumTimers(void) {
|
|||||||
int numTimers = 0;
|
int numTimers = 0;
|
||||||
if (ID < 0)
|
if (ID < 0)
|
||||||
return numTimers;
|
return numTimers;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
for (const cTimer *timer = Timers->First(); timer; timer = Timers->Next(timer)) {
|
for (const cTimer *timer = Timers->First(); timer; timer = Timers->Next(timer)) {
|
||||||
#else
|
#else
|
||||||
@ -545,7 +545,7 @@ int cTVGuideSearchTimer::GetNumRecordings(void) {
|
|||||||
int numRecordings = 0;
|
int numRecordings = 0;
|
||||||
if (ID < 0)
|
if (ID < 0)
|
||||||
return numRecordings;
|
return numRecordings;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_RECORDINGS_READ;
|
LOCK_RECORDINGS_READ;
|
||||||
for (const cRecording *recording = Recordings->First(); recording; recording = Recordings->Next(recording)) {
|
for (const cRecording *recording = Recordings->First(); recording; recording = Recordings->Next(recording)) {
|
||||||
#else
|
#else
|
||||||
@ -595,7 +595,7 @@ void cTVGuideSearchTimer::Dump(void) {
|
|||||||
|
|
||||||
void cTVGuideSearchTimer::SetStartChannel(int startChannel)
|
void cTVGuideSearchTimer::SetStartChannel(int startChannel)
|
||||||
{
|
{
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
channelMin = Channels->GetByNumber(startChannel);
|
channelMin = Channels->GetByNumber(startChannel);
|
||||||
#else
|
#else
|
||||||
@ -605,7 +605,7 @@ void cTVGuideSearchTimer::SetStartChannel(int startChannel)
|
|||||||
|
|
||||||
void cTVGuideSearchTimer::SetStopChannel(int stopChannel)
|
void cTVGuideSearchTimer::SetStopChannel(int stopChannel)
|
||||||
{
|
{
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
channelMax = Channels->GetByNumber(stopChannel);
|
channelMax = Channels->GetByNumber(stopChannel);
|
||||||
#else
|
#else
|
||||||
|
@ -11,7 +11,7 @@ private:
|
|||||||
int startTime;
|
int startTime;
|
||||||
int stopTime;
|
int stopTime;
|
||||||
int useChannel;
|
int useChannel;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cChannel *channelMin;
|
const cChannel *channelMin;
|
||||||
const cChannel *channelMax;
|
const cChannel *channelMax;
|
||||||
#else
|
#else
|
||||||
|
@ -82,7 +82,7 @@ void cStatusHeader::DrawInfoText(cGrid *grid) {
|
|||||||
int lineHeight = fontManager.FontStatusHeader->Height();
|
int lineHeight = fontManager.FontStatusHeader->Height();
|
||||||
int textLines = description.Lines();
|
int textLines = description.Lines();
|
||||||
int maxLines = heightText / lineHeight;
|
int maxLines = heightText / lineHeight;
|
||||||
int lines = min(textLines, maxLines);
|
int lines = std::min(textLines, maxLines);
|
||||||
for (int i = 0; i < lines-1; i++) {
|
for (int i = 0; i < lines-1; i++) {
|
||||||
pixmapText->DrawText(cPoint(x,y), description.GetLine(i), theme.Color(clrFont), colorTextBack, fontManager.FontStatusHeader);
|
pixmapText->DrawText(cPoint(x,y), description.GetLine(i), theme.Color(clrFont), colorTextBack, fontManager.FontStatusHeader);
|
||||||
y += lineHeight;
|
y += lineHeight;
|
||||||
|
@ -20,6 +20,17 @@ cSwitchTimer::cSwitchTimer(const cEvent* Event) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if VDRVERSNUM >= 20305
|
||||||
|
cSwitchTimer& cSwitchTimer::operator= (const cSwitchTimer &SwitchTimer)
|
||||||
|
{
|
||||||
|
this->eventID = SwitchTimer.eventID;
|
||||||
|
this->startTime = SwitchTimer.startTime;
|
||||||
|
this->channelID = SwitchTimer.channelID;
|
||||||
|
this->switchMinsBefore = SwitchTimer.switchMinsBefore;
|
||||||
|
return *this;
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
bool cSwitchTimer::Parse(const char *s) {
|
bool cSwitchTimer::Parse(const char *s) {
|
||||||
char *line;
|
char *line;
|
||||||
char *pos;
|
char *pos;
|
||||||
|
@ -10,6 +10,10 @@ public:
|
|||||||
tChannelID channelID;
|
tChannelID channelID;
|
||||||
int switchMinsBefore;
|
int switchMinsBefore;
|
||||||
int announceOnly;
|
int announceOnly;
|
||||||
|
#if VDRVERSNUM >= 20305
|
||||||
|
cSwitchTimer(const cSwitchTimer &SwitchTimer) { *this = SwitchTimer; };
|
||||||
|
cSwitchTimer& operator= (const cSwitchTimer &SwitchTimer);
|
||||||
|
#endif
|
||||||
cSwitchTimer(void);
|
cSwitchTimer(void);
|
||||||
cSwitchTimer(const cEvent* Event);
|
cSwitchTimer(const cEvent* Event);
|
||||||
bool Parse(const char *s);
|
bool Parse(const char *s);
|
||||||
|
@ -86,7 +86,7 @@ void cTVGuideTimerConflicts::CalculateConflicts(void) {
|
|||||||
cTimeInterval *unionSet = NULL;
|
cTimeInterval *unionSet = NULL;
|
||||||
int numTimers = conflicts[i]->timerIDs.size();
|
int numTimers = conflicts[i]->timerIDs.size();
|
||||||
for (int j=0; j < numTimers; j++) {
|
for (int j=0; j < numTimers; j++) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timer = Timers->Get(conflicts[i]->timerIDs[j]);
|
const cTimer *timer = Timers->Get(conflicts[i]->timerIDs[j]);
|
||||||
#else
|
#else
|
||||||
@ -110,7 +110,7 @@ void cTVGuideTimerConflicts::CalculateConflicts(void) {
|
|||||||
|
|
||||||
cTimeInterval *intersect = NULL;
|
cTimeInterval *intersect = NULL;
|
||||||
for (int j=0; j < numTimers; j++) {
|
for (int j=0; j < numTimers; j++) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timer = Timers->Get(conflicts[i]->timerIDs[j]);
|
const cTimer *timer = Timers->Get(conflicts[i]->timerIDs[j]);
|
||||||
#else
|
#else
|
||||||
|
24
tvguideosd.c
24
tvguideosd.c
@ -73,7 +73,7 @@ void cTvGuideOsd::Show(void) {
|
|||||||
|
|
||||||
void cTvGuideOsd::drawOsd() {
|
void cTvGuideOsd::drawOsd() {
|
||||||
cPixmap::Lock();
|
cPixmap::Lock();
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *startChannel = Channels->GetByNumber(cDevice::CurrentChannel());
|
const cChannel *startChannel = Channels->GetByNumber(cDevice::CurrentChannel());
|
||||||
#else
|
#else
|
||||||
@ -82,7 +82,7 @@ void cTvGuideOsd::drawOsd() {
|
|||||||
int numBack = tvguideConfig.numGrids / 2;
|
int numBack = tvguideConfig.numGrids / 2;
|
||||||
int offset = 0;
|
int offset = 0;
|
||||||
const cChannel *newStartChannel = startChannel;
|
const cChannel *newStartChannel = startChannel;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
for (; newStartChannel ; newStartChannel = Channels->Prev(newStartChannel)) {
|
for (; newStartChannel ; newStartChannel = Channels->Prev(newStartChannel)) {
|
||||||
#else
|
#else
|
||||||
for (; newStartChannel ; newStartChannel = Channels.Prev(newStartChannel)) {
|
for (; newStartChannel ; newStartChannel = Channels.Prev(newStartChannel)) {
|
||||||
@ -94,7 +94,7 @@ void cTvGuideOsd::drawOsd() {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (!newStartChannel)
|
if (!newStartChannel)
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
newStartChannel = Channels->First();
|
newStartChannel = Channels->First();
|
||||||
#else
|
#else
|
||||||
newStartChannel = Channels.First();
|
newStartChannel = Channels.First();
|
||||||
@ -135,7 +135,7 @@ void cTvGuideOsd::readChannels(const cChannel *channelStart) {
|
|||||||
columns.Clear();
|
columns.Clear();
|
||||||
if (!channelStart)
|
if (!channelStart)
|
||||||
return;
|
return;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
for (const cChannel *channel = channelStart; channel; channel = Channels->Next(channel)) {
|
for (const cChannel *channel = channelStart; channel; channel = Channels->Next(channel)) {
|
||||||
#else
|
#else
|
||||||
@ -162,7 +162,7 @@ void cTvGuideOsd::readChannels(const cChannel *channelStart) {
|
|||||||
int numCurrent = columns.Count();
|
int numCurrent = columns.Count();
|
||||||
int numBack = tvguideConfig.numGrids - numCurrent;
|
int numBack = tvguideConfig.numGrids - numCurrent;
|
||||||
int newChannelNumber = columns.First()->getChannel()->Number() - numBack;
|
int newChannelNumber = columns.First()->getChannel()->Number() - numBack;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
const cChannel *newStart = Channels->GetByNumber(newChannelNumber);
|
const cChannel *newStart = Channels->GetByNumber(newChannelNumber);
|
||||||
#else
|
#else
|
||||||
const cChannel *newStart = Channels.GetByNumber(newChannelNumber);
|
const cChannel *newStart = Channels.GetByNumber(newChannelNumber);
|
||||||
@ -235,7 +235,7 @@ void cTvGuideOsd::channelForward() {
|
|||||||
bool colAdded = false;
|
bool colAdded = false;
|
||||||
if (!colRight) {
|
if (!colRight) {
|
||||||
const cChannel *channelRight = activeGrid->column->getChannel();
|
const cChannel *channelRight = activeGrid->column->getChannel();
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
while (channelRight = Channels->Next(channelRight)) {
|
while (channelRight = Channels->Next(channelRight)) {
|
||||||
#else
|
#else
|
||||||
@ -290,7 +290,7 @@ void cTvGuideOsd::channelBack() {
|
|||||||
bool colAdded = false;
|
bool colAdded = false;
|
||||||
if (!colLeft) {
|
if (!colLeft) {
|
||||||
const cChannel *channelLeft = activeGrid->column->getChannel();
|
const cChannel *channelLeft = activeGrid->column->getChannel();
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
while (channelLeft = Channels->Prev(channelLeft)) {
|
while (channelLeft = Channels->Prev(channelLeft)) {
|
||||||
#else
|
#else
|
||||||
@ -466,7 +466,7 @@ void cTvGuideOsd::processKeyGreen() {
|
|||||||
if (tvguideConfig.channelJumpMode == eGroupJump) {
|
if (tvguideConfig.channelJumpMode == eGroupJump) {
|
||||||
int prevNum = channelGroups->GetPrevGroupChannelNumber(currentChannel);
|
int prevNum = channelGroups->GetPrevGroupChannelNumber(currentChannel);
|
||||||
if (prevNum) {
|
if (prevNum) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
prev = Channels->GetByNumber(prevNum);
|
prev = Channels->GetByNumber(prevNum);
|
||||||
#else
|
#else
|
||||||
@ -475,7 +475,7 @@ void cTvGuideOsd::processKeyGreen() {
|
|||||||
}
|
}
|
||||||
} else if (tvguideConfig.channelJumpMode == eNumJump) {
|
} else if (tvguideConfig.channelJumpMode == eNumJump) {
|
||||||
int i = tvguideConfig.jumpChannels + 1;
|
int i = tvguideConfig.jumpChannels + 1;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
for (const cChannel *channel = firstChannel; channel; channel = Channels->Prev(channel)) {
|
for (const cChannel *channel = firstChannel; channel; channel = Channels->Prev(channel)) {
|
||||||
#else
|
#else
|
||||||
@ -512,7 +512,7 @@ void cTvGuideOsd::processKeyYellow() {
|
|||||||
if (tvguideConfig.channelJumpMode == eGroupJump) {
|
if (tvguideConfig.channelJumpMode == eGroupJump) {
|
||||||
int nextNum = channelGroups->GetNextGroupChannelNumber(currentChannel);
|
int nextNum = channelGroups->GetNextGroupChannelNumber(currentChannel);
|
||||||
if (nextNum) {
|
if (nextNum) {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
next = Channels->GetByNumber(nextNum);
|
next = Channels->GetByNumber(nextNum);
|
||||||
#else
|
#else
|
||||||
@ -521,7 +521,7 @@ void cTvGuideOsd::processKeyYellow() {
|
|||||||
}
|
}
|
||||||
} else if (tvguideConfig.channelJumpMode == eNumJump) {
|
} else if (tvguideConfig.channelJumpMode == eNumJump) {
|
||||||
int i=0;
|
int i=0;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
for (const cChannel *channel = firstChannel; channel; channel = Channels->Next(channel)) {
|
for (const cChannel *channel = firstChannel; channel; channel = Channels->Next(channel)) {
|
||||||
#else
|
#else
|
||||||
@ -677,7 +677,7 @@ void cTvGuideOsd::CheckTimeout(void) {
|
|||||||
int newChannelNum = channelJumper->GetChannel();
|
int newChannelNum = channelJumper->GetChannel();
|
||||||
delete channelJumper;
|
delete channelJumper;
|
||||||
channelJumper = NULL;
|
channelJumper = NULL;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_CHANNELS_READ;
|
LOCK_CHANNELS_READ;
|
||||||
const cChannel *newChannel = Channels->GetByNumber(newChannelNum);
|
const cChannel *newChannel = Channels->GetByNumber(newChannelNum);
|
||||||
#else
|
#else
|
||||||
|
4
view.c
4
view.c
@ -120,7 +120,7 @@ void cView::DrawHeader(void) {
|
|||||||
pixmapHeader->DrawText(cPoint(xText, ySubtitle), CutText(subTitle, textWidthMax, fontHeader).c_str(), theme.Color(clrFont), theme.Color(clrStatusHeader), fontHeader);
|
pixmapHeader->DrawText(cPoint(xText, ySubtitle), CutText(subTitle, textWidthMax, fontHeader).c_str(), theme.Color(clrFont), theme.Color(clrStatusHeader), fontHeader);
|
||||||
//REC Icon
|
//REC Icon
|
||||||
eTimerMatch timerMatch=tmNone;
|
eTimerMatch timerMatch=tmNone;
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *ti;
|
const cTimer *ti;
|
||||||
#else
|
#else
|
||||||
@ -135,7 +135,7 @@ void cView::DrawHeader(void) {
|
|||||||
timerMatch = (eTimerMatch)rtMatch.timerMatch;
|
timerMatch = (eTimerMatch)rtMatch.timerMatch;
|
||||||
ti = rtMatch.timer;
|
ti = rtMatch.timer;
|
||||||
} else {
|
} else {
|
||||||
#if defined (APIVERSNUM) && (APIVERSNUM >= 20301)
|
#if VDRVERSNUM >= 20301
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
ti=Timers->GetMatch(event, &timerMatch);
|
ti=Timers->GetMatch(event, &timerMatch);
|
||||||
#else
|
#else
|
||||||
|
Loading…
Reference in New Issue
Block a user