I am trying to convert the list example from the lvgl documentation to python.
I defined an event handler as follows:
def event_handler(obj, event):
if event == lv.EVENT.CLICKED:
print(“Clicked: %s” % list_btn.get_btn_text(obj))
and I set it to the buttons:
list_btn.set_event_cb(event_handler)
Unfortunately this does not work because an lv.obj is passed into the event handler instead of lv.list and list_btn.get_btn_text(obj) complains
How do I do this correctly?