plugin.h
1.66 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
#ifndef __PLUGIN_H__
#define __PLUGIN_H__
#ifdef __cplusplus
extern "C" {
#endif
extern const char* PLUG_IN_INFO /*= "pluginame"*/;
extern const char* PLUGIN_NAME_MTE /*= "mte"*/;
extern const char* PLUGIN_EVENT_MTE /*= "mte_event"*/;
#define MAX_PLUG_IN_NAME_LENGTH 32
#define MIN_PLUG_IN_NAME_LENGTH 1
#define MAX_PLUG_IN_CMD_LENGTH 32
#define MIN_PLUG_IN_CMD_LENGTH 1
/*****************************************************************************
* Enum
*****************************************************************************/
/* Plug-in type */
typedef enum
{
PLUG_IN_TYPE_MMI, /* MMI plug-in */
PLUG_IN_TYPE_PS, /* Protocal stack plug-in */
//Add more here...
PLUG_IN_TYPE_END
} plugin_type_enum;
/* MMI plug-in message*/
typedef enum
{
PLUG_IN_MSG_MTE, /* MTE */
//Add more here...
PLUG_IN_MSG_END
} plugin_msg_enum;
/*****************************************************************************
* Structure
*****************************************************************************/
/* Plug-in information which triggering a interrupt */
typedef struct
{
char name[32];
plugin_type_enum emType;
plugin_msg_enum emMsgID;
} plugin_information;
/* data structure for MSG_ID_PLUG_IN_IND */
typedef struct
{
plugin_information info;
} mmi_plug_in_msg_struct;
/* data structure for MMI_PLUG_IN_MSG_MTE */
typedef enum _MTE_CMD
{
MTE_CMD_NONE,
MTE_CMD_GET_LCD_SIZE,
MTE_CMD_GET_MAUI_VERSION,
MTE_CMD_GET_API,
MTE_CMD_GET_MMI_CLOSE_FLAG,
MTE_CMD_IS_DISABLED,
} MTE_CMD;
typedef struct _mte_data_struct
{
MTE_CMD cmd;
int nDataLength;
char data[1024];
} mte_data_struct;
/*Add more structures here...*/
//...
#ifdef __cplusplus
}
#endif
#endif