|
oveRTOS C++ API
C++20 RAII wrappers for the oveRTOS C API
|
RAII wrapper for an LVGL input focus group (lv_group_t).
More...
#include <lvgl.hpp>
Public Member Functions | |
| Group (lv_group_t *g) | |
Takes ownership of an existing lv_group_t *. | |
| Group (const Group &)=delete | |
| Group & | operator= (const Group &)=delete |
| Group (Group &&other) noexcept | |
| Move constructor — transfers ownership; source becomes empty. | |
| Group & | operator= (Group &&other) noexcept |
Move-assignment — releases current group, then takes other's. | |
| lv_group_t * | get () const |
Raw lv_group_t * for FFI interop. | |
| Group & | set_as_default () |
| Marks this group as the default — new focusable widgets will auto-join it at creation time. | |
| Group & | add (ObjectView obj) |
| Adds a widget to the group's focusable list. | |
| Group & | remove_all () |
| Removes all widgets from this group. | |
| Group & | focus_next () |
| Moves focus to the next member. | |
| Group & | focus_prev () |
| Moves focus to the previous member. | |
| Group & | focus_freeze (bool freeze) |
| Freezes/unfreezes focus movement. | |
| ObjectView | focused () const |
| Returns the currently focused widget, or a null view. | |
| Group & | edit_mode (bool enable) |
| Enables/disables edit mode (relevant for encoder input). | |
| bool | is_editing () const |
| Returns the current edit-mode flag. | |
| uint32_t | obj_count () const |
| Returns the number of widgets in the group. | |
Static Public Member Functions | |
| static Group | create () |
| Creates a fresh focus group. | |
| static lv_group_t * | get_default () |
Returns the default group (set via set_as_default()). | |
| static void | focus_obj (ObjectView obj) |
| Static helper: focus a specific widget regardless of its group membership. | |
| static void | remove_obj (ObjectView obj) |
| Static helper: remove a widget from whatever group it's in. | |
RAII wrapper for an LVGL input focus group (lv_group_t).
Groups route keyboard / encoder / button events to a focused member widget. Essential for non-touch targets where pointer input isn't available. Create a group, add widgets with add(), then connect your input device to the group (outside the scope of this wrapper — see backend-specific input device registration).
lv_group_t *.