mirror of
https://github.com/78/xiaozhi-esp32.git
synced 2026-01-14 09:17:20 +08:00
* feat: Add lvgl display theme control * fix: compiling errors * move light/dark themes to lcd display * fix compile errors --------- Co-authored-by: Xiaoxia <terrence.huang@tenclass.com>
61 lines
1.3 KiB
C++
61 lines
1.3 KiB
C++
#include <esp_log.h>
|
|
#include <esp_err.h>
|
|
#include <string>
|
|
#include <cstdlib>
|
|
#include <cstring>
|
|
#include <font_awesome.h>
|
|
|
|
#include "display.h"
|
|
#include "board.h"
|
|
#include "application.h"
|
|
#include "audio_codec.h"
|
|
#include "settings.h"
|
|
#include "assets/lang_config.h"
|
|
|
|
#define TAG "Display"
|
|
|
|
Display::Display() {
|
|
}
|
|
|
|
Display::~Display() {
|
|
}
|
|
|
|
void Display::SetStatus(const char* status) {
|
|
ESP_LOGW(TAG, "SetStatus: %s", status);
|
|
}
|
|
|
|
void Display::ShowNotification(const std::string ¬ification, int duration_ms) {
|
|
ShowNotification(notification.c_str(), duration_ms);
|
|
}
|
|
|
|
void Display::ShowNotification(const char* notification, int duration_ms) {
|
|
ESP_LOGW(TAG, "ShowNotification: %s", notification);
|
|
}
|
|
|
|
void Display::UpdateStatusBar(bool update_all) {
|
|
}
|
|
|
|
|
|
void Display::SetEmotion(const char* emotion) {
|
|
ESP_LOGW(TAG, "SetEmotion: %s", emotion);
|
|
}
|
|
|
|
void Display::SetPreviewImage(const lv_img_dsc_t* image) {
|
|
// Do nothing but free the image
|
|
if (image != nullptr) {
|
|
heap_caps_free((void*)image->data);
|
|
heap_caps_free((void*)image);
|
|
}
|
|
}
|
|
|
|
void Display::SetChatMessage(const char* role, const char* content) {
|
|
ESP_LOGW(TAG, "Role:%s", role);
|
|
ESP_LOGW(TAG, " %s", content);
|
|
}
|
|
|
|
void Display::SetTheme(Theme* theme) {
|
|
}
|
|
|
|
void Display::SetPowerSaveMode(bool on) {
|
|
}
|