mirror of
https://projects.vdr-developer.org/git/vdr-plugin-tvguide.git
synced 2023-10-05 15:01:48 +02:00
Fixes for <VDR-2.3.1 compatibility
This commit is contained in:
parent
240cbe87e0
commit
8335ab0e41
@ -231,12 +231,18 @@ eOSState cRecMenuView::StateMachine(eRecMenuState nextState) {
|
|||||||
if (cRecMenuTimerConflict *menu = dynamic_cast<cRecMenuTimerConflict*>(activeMenu)) {
|
if (cRecMenuTimerConflict *menu = dynamic_cast<cRecMenuTimerConflict*>(activeMenu)) {
|
||||||
timerIndex = menu->GetTimerConflictIndex();
|
timerIndex = menu->GetTimerConflictIndex();
|
||||||
} else break;
|
} else break;
|
||||||
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex) + 1;
|
const cTimers* timers;
|
||||||
#if VDRVERSNUM >= 20301
|
#if VDRVERSNUM >= 20301
|
||||||
|
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex) + 1;
|
||||||
|
{
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *t = Timers->GetById(timerID);
|
timers = Timers;
|
||||||
|
}
|
||||||
|
const cTimer *t = timers->GetById(timerID);
|
||||||
#else
|
#else
|
||||||
const cTimer *t = Timers.Get(timerID);
|
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex);
|
||||||
|
timers = &Timers;
|
||||||
|
const cTimer *t = timers->Get(timerID);
|
||||||
#endif
|
#endif
|
||||||
if (t) {
|
if (t) {
|
||||||
const cEvent *ev = t->Event();
|
const cEvent *ev = t->Event();
|
||||||
@ -266,7 +272,7 @@ eOSState cRecMenuView::StateMachine(eRecMenuState nextState) {
|
|||||||
timers = &Timers;
|
timers = &Timers;
|
||||||
event = timers->Get(timerID)->Event();
|
event = timers->Get(timerID)->Event();
|
||||||
#endif
|
#endif
|
||||||
recManager->DeleteTimer(event); // (timerID);
|
recManager->DeleteTimer(event);
|
||||||
delete activeMenu;
|
delete activeMenu;
|
||||||
if (!DisplayTimerConflict(timerID)) {
|
if (!DisplayTimerConflict(timerID)) {
|
||||||
activeMenu = new cRecMenuConfirmDeleteTimer(event);
|
activeMenu = new cRecMenuConfirmDeleteTimer(event);
|
||||||
@ -280,12 +286,18 @@ eOSState cRecMenuView::StateMachine(eRecMenuState nextState) {
|
|||||||
if (cRecMenuTimerConflict *menu = dynamic_cast<cRecMenuTimerConflict*>(activeMenu)) {
|
if (cRecMenuTimerConflict *menu = dynamic_cast<cRecMenuTimerConflict*>(activeMenu)) {
|
||||||
timerIndex = menu->GetTimerConflictIndex();
|
timerIndex = menu->GetTimerConflictIndex();
|
||||||
} else break;
|
} else break;
|
||||||
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex) + 1;
|
const cTimers* timers;
|
||||||
#if VDRVERSNUM >= 20301
|
#if VDRVERSNUM >= 20301
|
||||||
|
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex) + 1;
|
||||||
|
{
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timer = Timers->GetById(timerID);
|
timers = Timers;
|
||||||
|
}
|
||||||
|
const cTimer *timer = timers->GetById(timerID);
|
||||||
#else
|
#else
|
||||||
const cTimer *timer = Timers.Get(timerID);
|
int timerID = timerConflicts->GetCurrentConflictTimerID(timerIndex);
|
||||||
|
timers = &Timers;
|
||||||
|
const cTimer *timer = timers->Get(timerID);
|
||||||
#endif
|
#endif
|
||||||
if (timer) {
|
if (timer) {
|
||||||
delete activeMenu;
|
delete activeMenu;
|
||||||
@ -666,12 +678,18 @@ eOSState cRecMenuView::StateMachine(eRecMenuState nextState) {
|
|||||||
if (cRecMenuTimerConflict *menu = dynamic_cast<cRecMenuTimerConflict*>(activeMenu)) {
|
if (cRecMenuTimerConflict *menu = dynamic_cast<cRecMenuTimerConflict*>(activeMenu)) {
|
||||||
timerConflict = menu->GetTimerConflictIndex();
|
timerConflict = menu->GetTimerConflictIndex();
|
||||||
} else break;
|
} else break;
|
||||||
int timerID = timerConflicts->GetCurrentConflictTimerID(timerConflict) + 1;
|
const cTimers* timers;
|
||||||
#if VDRVERSNUM >= 20301
|
#if VDRVERSNUM >= 20301
|
||||||
|
int timerID = timerConflicts->GetCurrentConflictTimerID(timerConflict) + 1;
|
||||||
|
{
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timer = Timers->GetById(timerID);
|
timers = Timers;
|
||||||
|
}
|
||||||
|
const cTimer *timer = timers->GetById(timerID);
|
||||||
#else
|
#else
|
||||||
cTimer *timer = Timers.Get(timerID);
|
int timerID = timerConflicts->GetCurrentConflictTimerID(timerConflict);
|
||||||
|
timers = &Timers;
|
||||||
|
const cTimer *timer = timers->Get(timerID);
|
||||||
#endif
|
#endif
|
||||||
if (timer) {
|
if (timer) {
|
||||||
const cEvent *event = timer->Event();
|
const cEvent *event = timer->Event();
|
||||||
@ -713,12 +731,16 @@ eOSState cRecMenuView::StateMachine(eRecMenuState nextState) {
|
|||||||
originalConflictIndex = menu->GetTimerConflictIndex();
|
originalConflictIndex = menu->GetTimerConflictIndex();
|
||||||
} else break;
|
} else break;
|
||||||
int originalTimerID = timerConflicts->GetCurrentConflictTimerID(originalConflictIndex);
|
int originalTimerID = timerConflicts->GetCurrentConflictTimerID(originalConflictIndex);
|
||||||
|
const cTimers* timers;
|
||||||
#if VDRVERSNUM >= 20301
|
#if VDRVERSNUM >= 20301
|
||||||
|
{
|
||||||
LOCK_TIMERS_READ;
|
LOCK_TIMERS_READ;
|
||||||
const cTimer *timerOriginal = Timers->Get(originalTimerID);
|
timers = Timers;
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
cTimer *timerOriginal = Timers.Get(originalTimerID);
|
timers = &Timers;
|
||||||
#endif
|
#endif
|
||||||
|
const cTimer *timerOriginal = timers->Get(originalTimerID);
|
||||||
if (replace && timerOriginal) {
|
if (replace && timerOriginal) {
|
||||||
recManager->DeleteTimer(timerOriginal->Event());
|
recManager->DeleteTimer(timerOriginal->Event());
|
||||||
recManager->createTimer(replace);
|
recManager->createTimer(replace);
|
||||||
|
Loading…
Reference in New Issue
Block a user