mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-23 18:56:38 +00:00
Merge pull request #16852 from s-hadinger/lvgl_fix_get_text
LVGL fix get text
This commit is contained in:
commit
329f0e6b1c
@ -899,7 +899,7 @@ const be_ntv_func_def_t lv_label_func[] = {
|
||||
{ "get_letter_pos", { (const void*) &lv_label_get_letter_pos, "", "(lv.lv_obj)i(lv.lv_point)" } },
|
||||
{ "get_long_mode", { (const void*) &lv_label_get_long_mode, "i", "(lv.lv_obj)" } },
|
||||
{ "get_recolor", { (const void*) &lv_label_get_recolor, "b", "(lv.lv_obj)" } },
|
||||
{ "get_text", { (const void*) &lv_label_get_text, "c", "(lv.lv_obj)" } },
|
||||
{ "get_text", { (const void*) &lv_label_get_text, "s", "(lv.lv_obj)" } },
|
||||
{ "get_text_selection_end", { (const void*) &lv_label_get_text_selection_end, "i", "(lv.lv_obj)" } },
|
||||
{ "get_text_selection_start", { (const void*) &lv_label_get_text_selection_start, "i", "(lv.lv_obj)" } },
|
||||
{ "ins_text", { (const void*) &lv_label_ins_text, "", "(lv.lv_obj)is" } },
|
||||
|
@ -38,6 +38,7 @@ return_types = {
|
||||
"char *": "c",
|
||||
"uint8_t *": "c",
|
||||
"const char *": "s",
|
||||
"retchar *": "s",
|
||||
"constchar *": "s", # special construct
|
||||
"lv_obj_user_data_t": "i",
|
||||
|
||||
@ -245,6 +246,7 @@ with open(lv_widgets_file) as f:
|
||||
l_raw = re.sub('static ', '', l_raw)
|
||||
l_raw = re.sub('inline ', '', l_raw)
|
||||
l_raw = re.sub('const\s+char\s*\*', 'constchar *', l_raw)
|
||||
l_raw = re.sub('^char\s*\*', 'retchar *', l_raw) # special case for returning a char*
|
||||
l_raw = re.sub('const ', '', l_raw)
|
||||
l_raw = re.sub('struct ', '', l_raw)
|
||||
if (len(l_raw) == 0): continue
|
||||
|
@ -36,6 +36,7 @@ extern "C" {
|
||||
4, /* number of elements */
|
||||
nullptr,
|
||||
(const be_ctypes_structure_item_t[4]) {
|
||||
// Warning: fields below need to be in alphabetical order
|
||||
{ "devices_present", offsetof(TasmotaGlobal_t, devices_present), 0, 0, ctypes_u8, 0 },
|
||||
{ "fast_loop_enabled", offsetof(TasmotaGlobal_t, berry_fast_loop_enabled), 0, 0, ctypes_u8, 0 },
|
||||
{ "restart_flag", offsetof(TasmotaGlobal_t, restart_flag), 0, 0, ctypes_u8, 0 },
|
||||
@ -47,10 +48,11 @@ extern "C" {
|
||||
2, /* number of elements */
|
||||
nullptr,
|
||||
(const be_ctypes_structure_item_t[2]) {
|
||||
// Warning: fields below need to be in alphabetical order
|
||||
{ "bootcount", offsetof(TSettings, bootcount), 0, 0, ctypes_u16, 0 },
|
||||
{ "sleep", offsetof(TSettings, sleep), 0, 0, ctypes_u8, 0 },
|
||||
}};
|
||||
|
||||
}
|
||||
|
||||
#endif // USE_BERRY
|
||||
#endif // USE_BERRY
|
||||
|
Loading…
x
Reference in New Issue
Block a user