mirror of
https://projects.vdr-developer.org/git/vdr-plugin-tvguide.git
synced 2023-10-05 15:01:48 +02:00
Refactor cRecMenuSwitchTimerConfirm
This commit is contained in:
parent
97c8bc23fd
commit
403af35519
12
recmenus.c
12
recmenus.c
@ -1119,17 +1119,13 @@ cSwitchTimer cRecMenuSwitchTimer::GetSwitchTimer(void) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// --- cRecMenuSwitchTimerConfirm ---------------------------------------------------------
|
// --- cRecMenuSwitchTimerConfirm ---------------------------------------------------------
|
||||||
cRecMenuSwitchTimerConfirm::cRecMenuSwitchTimerConfirm(bool success) {
|
cRecMenuSwitchTimerConfirm::cRecMenuSwitchTimerConfirm(bool success) { // OK
|
||||||
SetWidthPercent(50);
|
SetWidthPercent(50);
|
||||||
|
|
||||||
cString message1 = tr("Switch Timer sucessfully created");
|
const cString line1 = (success) ? tr("Switch Timer sucessfully created") : tr("Switch Timer NOT sucessfully created");
|
||||||
cString message2 = tr("Switch Timer NOT sucessfully created");
|
|
||||||
cString infoText = success?message1:message2;
|
|
||||||
cRecMenuItemInfo *infoItem = new cRecMenuItemInfo(*infoText);
|
|
||||||
infoItem->CalculateHeight(width - 2 * border);
|
|
||||||
AddMenuItem(infoItem);
|
|
||||||
|
|
||||||
AddMenuItem(new cRecMenuItemButton(tr("OK"), rmsClose, true));
|
AddHeader(new cRecMenuItemInfo(*line1, 1, "", "", "", width - 2 * border));
|
||||||
|
AddFooter(new cRecMenuItemButton(tr("OK"), rmsClose, true));
|
||||||
|
|
||||||
CalculateHeight();
|
CalculateHeight();
|
||||||
CreatePixmap();
|
CreatePixmap();
|
||||||
|
Loading…
Reference in New Issue
Block a user