FireBirdLib - Topfield TMS PVR TAP Programming Library
OSDMenuItemModifyValue.c
Go to the documentation of this file.
1
#include <string.h>
2
#include "
FBLib_TMSOSDMenu.h
"
3
4
bool
OSDMenuItemModifyValue
(
int
ItemIndex,
const
char
*Text)
5
{
6
TRACEENTER
();
7
8
tMenu
*pMenu;
9
10
pMenu = &
Menu
[
CurrentMenuLevel
];
11
12
if
((ItemIndex < 0) || (ItemIndex >= pMenu->
NrItems
))
13
{
14
TRACEEXIT
();
15
return
FALSE;
16
}
17
18
if
(!Text)
19
{
20
TRACEEXIT
();
21
return
FALSE;
22
}
23
24
strncpy(pMenu->
Item
[ItemIndex].
Value
, Text,
ITEMNAMESIZE
);
25
pMenu->
Item
[ItemIndex].
Value
[
ITEMNAMESIZE
- 1] =
'\0'
;
26
27
ListDirty
= TRUE;
28
29
TRACEEXIT
();
30
return
TRUE;
31
}
FBLib_TMSOSDMenu.h
ITEMNAMESIZE
#define ITEMNAMESIZE
Definition:
FBLib_TMSOSDMenu.h:6
Menu
tMenu Menu[NRMENULEVELS]
Definition:
OSDMenuInit.c:6
CurrentMenuLevel
dword CurrentMenuLevel
Definition:
OSDMenuInit.c:7
ListDirty
bool ListDirty
Definition:
FBLib_TMSOSDMenu.h:223
OSDMenuItemModifyValue
bool OSDMenuItemModifyValue(int ItemIndex, const char *Text)
Definition:
OSDMenuItemModifyValue.c:4
TRACEEXIT
#define TRACEEXIT()
Definition:
libFireBird.h:1244
TRACEENTER
#define TRACEENTER()
Definition:
libFireBird.h:1243
tItem::Value
char Value[ITEMVALUESIZE]
Definition:
FBLib_TMSOSDMenu.h:34
tMenu
Definition:
FBLib_TMSOSDMenu.h:67
tMenu::Item
tItem * Item
Definition:
FBLib_TMSOSDMenu.h:71
tMenu::NrItems
int NrItems
Definition:
FBLib_TMSOSDMenu.h:72
TMSOSDMenu
OSDMenuItemModifyValue.c
Generated on Fri Apr 29 2022 13:34:01 for FireBirdLib - Topfield TMS PVR TAP Programming Library by
1.9.3