fix(obj) add lv_obj_class_t * as first parameter of constructors and destructors

It's required for compatibility with the MicroPython binding.
This commit is contained in:
Gabor Kiss-Vamosi
2021-04-13 14:31:21 +02:00
parent 04f0ffc775
commit 834e2177e7
31 changed files with 179 additions and 127 deletions

View File

@@ -34,8 +34,8 @@
/**********************
* STATIC PROTOTYPES
**********************/
static void lv_label_constructor(lv_obj_t * obj);
static void lv_label_destructor(lv_obj_t * obj);
static void lv_label_constructor(const lv_obj_class_t * class_p, lv_obj_t * obj);
static void lv_label_destructor(const lv_obj_class_t * class_p, lv_obj_t * obj);
static void lv_label_event_cb(lv_obj_t * obj, lv_event_t e);
static void draw_main(lv_obj_t * obj);
@@ -692,8 +692,9 @@ void lv_label_cut_text(lv_obj_t * obj, uint32_t pos, uint32_t cnt)
* STATIC FUNCTIONS
**********************/
static void lv_label_constructor(lv_obj_t * obj)
static void lv_label_constructor(const lv_obj_class_t * class_p, lv_obj_t * obj)
{
LV_UNUSED(class_p);
LV_TRACE_OBJ_CREATE("begin");
lv_label_t * label = (lv_label_t *)obj;
@@ -727,8 +728,9 @@ static void lv_label_constructor(lv_obj_t * obj)
LV_TRACE_OBJ_CREATE("finished");
}
static void lv_label_destructor(lv_obj_t * obj)
static void lv_label_destructor(const lv_obj_class_t * class_p, lv_obj_t * obj)
{
LV_UNUSED(class_p);
lv_label_t * label = (lv_label_t *)obj;
lv_label_dot_tmp_free(obj);