aboutsummaryrefslogtreecommitdiff
path: root/src/widgets/buttonmatrix/lv_buttonmatrix.c
diff options
context:
space:
mode:
authorterry.rong <rongyichang@xiaomi.com>2024-01-17 21:38:05 +0800
committerGitHub <noreply@github.com>2024-01-17 14:38:05 +0100
commit122acbd00f2d209ddb25f637bfe72c06428a43cc (patch)
treec0da3af8efe4e1e30d34252b4a4df1c60729404c /src/widgets/buttonmatrix/lv_buttonmatrix.c
parent0379088110631f9d60d3d01b295efe47d46bdefc (diff)
downloadlvgl-122acbd00f2d209ddb25f637bfe72c06428a43cc.tar.gz
lvgl-122acbd00f2d209ddb25f637bfe72c06428a43cc.zip
fix(event): fix assert in event bubble mode. (#5357)
Signed-off-by: rongyichang <rongyichang@xiaomi.com>
Diffstat (limited to 'src/widgets/buttonmatrix/lv_buttonmatrix.c')
-rw-r--r--src/widgets/buttonmatrix/lv_buttonmatrix.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/widgets/buttonmatrix/lv_buttonmatrix.c b/src/widgets/buttonmatrix/lv_buttonmatrix.c
index 904ffbb6d..291d69a78 100644
--- a/src/widgets/buttonmatrix/lv_buttonmatrix.c
+++ b/src/widgets/buttonmatrix/lv_buttonmatrix.c
@@ -399,7 +399,7 @@ static void lv_buttonmatrix_event(const lv_obj_class_t * class_p, lv_event_t * e
if(res != LV_RESULT_OK) return;
lv_event_code_t code = lv_event_get_code(e);
- lv_obj_t * obj = lv_event_get_target(e);
+ lv_obj_t * obj = lv_event_get_current_target(e);
lv_buttonmatrix_t * btnm = (lv_buttonmatrix_t *)obj;
lv_point_t p;
@@ -661,7 +661,7 @@ static void lv_buttonmatrix_event(const lv_obj_class_t * class_p, lv_event_t * e
static void draw_main(lv_event_t * e)
{
- lv_obj_t * obj = lv_event_get_target(e);
+ lv_obj_t * obj = lv_event_get_current_target(e);
lv_buttonmatrix_t * btnm = (lv_buttonmatrix_t *)obj;
if(btnm->btn_cnt == 0) return;