mirror of
https://github.com/ByteWelder/Tactility.git
synced 2026-02-18 19:03:16 +00:00
- Refactored `TouchDevice`: it can now start/stop LVGL separately, and it has an optional `TouchDriver` interface - Refactored `DisplayDevice`: it can now start/stop LVGL separately, and it has an optional `DisplayDriver` interface - Updated all boards and drivers for above changes - LVGL can now be stopped and (re)started on the fly - Fixed issues with restarting Gui and Statusbar services - Refactored `Gui` service to be class and renamed `Gui` to `GuiService` - Fixed `Statusbar` service: forgot to deregister one of the icons - Updated `esp_lcd_st7701` to v1.1.3 - `lv_textarea_create()` now automatically registers the hardware keyboard hooks (by wrapping the function) - Fixed and updated `tactility.py` - Cleanup of a lot of code - `BootInitLvglBegin` and `BootInitLvglEnd` are replaced by `LvglStarted` and `LvglStopped`. - Introduced `tt::service::State` which is accessible via `tt::service::getState()` (and internally via `ServiceInstance`) - Started replacing `#define TAG` with `constexpr auto TAG = "..";`
55 lines
1.3 KiB
C
55 lines
1.3 KiB
C
#pragma once
|
|
|
|
#include <lvgl.h>
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
/**
|
|
* Show the on-screen keyboard.
|
|
* @param[in] textarea the textarea to focus the input for
|
|
*/
|
|
void tt_lvgl_software_keyboard_show(lv_obj_t* textarea);
|
|
|
|
/**
|
|
* Hide the on-screen keyboard.
|
|
* Has no effect when the keyboard is not visible.
|
|
*/
|
|
void tt_lvgl_software_keyboard_hide();
|
|
|
|
/**
|
|
* The on-screen keyboard is only shown when both of these conditions are true:
|
|
* - there is no hardware keyboard
|
|
* - TT_CONFIG_FORCE_ONSCREEN_KEYBOARD is set to true in tactility_config.h
|
|
* @return if we should show a on-screen keyboard for text input inside our apps
|
|
*/
|
|
bool tt_lvgl_software_keyboard_is_enabled();
|
|
|
|
/**
|
|
* Activate the keypad for a widget group.
|
|
* @param group
|
|
*/
|
|
void tt_lvgl_software_keyboard_activate(lv_group_t* group);
|
|
|
|
/**
|
|
* Deactivate the keypad for the current widget group (if any).
|
|
* You don't have to call this after calling _activate() because widget
|
|
* cleanup automatically removes itself from the group it belongs to.
|
|
*/
|
|
void tt_lvgl_software_keyboard_deactivate();
|
|
|
|
/**
|
|
* @return true if LVGL is configured with a keypad
|
|
*/
|
|
bool tt_lvgl_hardware_keyboard_is_available();
|
|
|
|
/**
|
|
* Set the keypad.
|
|
* @param device the keypad device
|
|
*/
|
|
void tt_lvgl_hardware_keyboard_set_indev(lv_indev_t* device);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif |