semilimes mcu sdk 0.1
semilimes Software Development Kit for microcontrollers
Loading...
Searching...
No Matches
fc_button_list.h
1#ifndef _fc_button_list_
2#define _fc_button_list_
3
4#include "../defines.h"
5
7{
8private:
9 SmeJson json_data;
10 char** pjson;
11 char** pjsonArray;
12
13public:
14// Function: FcSingleChoice
15
16// A group of user-clickable buttons with a label
17
18// Prototype:
19// void FcMultipleChoice(char* json, char* jsonArray);
20
21// Parameters:
24
25// Returns:
27 FcButtonList(char* json, char* jsonArray)
28 {
29 pjson = &json;
30 pjsonArray = &jsonArray;
31 json_data.initJson(*pjson);
32 json_data.initJsonArray(*pjsonArray);
33 json_data.addPair2JsonStr(*pjson,"formComponentType","buttonlist");
34 }
35
36// Function: FcButtonList.setObj
37
38// Initialize a group of user-clickable buttons with a label
39
40// Prototype:
41// void FcButtonList::setObj(char* refname,char* title,bool reqSel,char* value,bool vertList);
42
43// Parameters:
49
50// Returns:
52 void setObj(char* refname,char* title,bool reqSel,char* value,bool vertList);
53
54// Function: FcButtonList.addOptions
55
56// add an array of options where name is the option identifier and value is the text displayed to the user
57
58// Prototype:
59// void FcButtonList::addOptions(char* data);
60
61// Parameters:
64
65// Returns:
67 void addOptions(char* name,char* value);
68
69// Function: FcButtonList.appendOptions
70
71// Append the selected options
72
73// Prototype:
74// void FcButtonList::appendOptions();
75
76// Parameters:
77
78// Returns:
80 void appendOptions();
81};
82
83#endif
Definition fc_button_list.h:7
void appendOptions()
Definition fc_button_list.cpp:66
void setObj(char *refname, char *title, bool reqSel, char *value, bool vertList)
Definition fc_button_list.cpp:20
FcButtonList(char *json, char *jsonArray)
Definition fc_button_list.h:27
void addOptions(char *name, char *value)
Definition fc_button_list.cpp:46