summaryrefslogtreecommitdiff
path: root/menuitemtext.c
blob: e09308611daa274a459f105c79552bfc16e3bba1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
/*
 * undelete: A plugin for the Video Disk Recorder
 *
 * See the README file for copyright information and how to reach the author.
 *
 * $Id: menuitemtext.c 0.1 2004/10/08 02:03:31 hflor Exp $
 */

#include "menuitemtext.h"
#include <vdr/menuitems.h>

// --- cMenuText -------------------------------------------------------------

cMenuItemText::cMenuItemText(const char *Title, const char *Text, eDvbFont Font)
:cOsdMenu(Title)
{
  Add(new cMenuTextItem(Text, 1, 2, Setup.OSDwidth - 2, MAXOSDITEMS, clrWhite, clrBackground, Font));
}

eOSState cMenuItemText::ProcessKey(eKeys Key)
{
  eOSState state = cOsdMenu::ProcessKey(Key);

  switch (state)
  {
    case osUnknown:  switch (NORMALKEY(Key))
                     {
                       case kOk:     state = osBack;
                                     break;
                       default: break;
                     }
                     break;
    default:         break;
  }
  return state;
}