Figured this would be helpful for people.
In the UI Creator there are options for everything within LVGL (Boy is this a lot of tying to do, but in the end will make it complete).
For example Button Maps, each button has 6 options (No Repeat, Inactive, etc). Well in order to record the UI changes we need a call back.
In order to minimize the number of different call backs, what I did was:
- Create a single call back for all of the options.
- In the call back do this:
if (event != LV_EVENT_VALUE_CHANGED) return; std::string option = lv_cb_get_text(obj);
Since each cb option has different text, I can assign the value based on that, and have a single call back for all checkboxes.