Update to ESP-IDF v5.4 and fix warnings (#193)
- Update to ESP-IDF v5.4 - Fixed a lot of new and existing warnings - Fix issue with incorrect `EventFlag` usage in Dispatcher
This commit is contained in:
committed by
GitHub
parent
fa54eaa58a
commit
1bb1260ea0
@@ -120,11 +120,8 @@ static int32_t guiMain(TT_UNUSED void* p) {
|
||||
Gui* local_gui = gui;
|
||||
|
||||
while (true) {
|
||||
uint32_t flags = Thread::awaitFlags(
|
||||
GUI_THREAD_FLAG_ALL,
|
||||
EventFlag::WaitAny,
|
||||
portMAX_DELAY
|
||||
);
|
||||
uint32_t flags = Thread::awaitFlags(GUI_THREAD_FLAG_ALL, EventFlag::WaitAny, portMAX_DELAY);
|
||||
|
||||
// Process and dispatch draw call
|
||||
if (flags & GUI_THREAD_FLAG_DRAW) {
|
||||
Thread::clearFlags(GUI_THREAD_FLAG_DRAW);
|
||||
|
||||
@@ -64,13 +64,10 @@ void stopApp() {
|
||||
|
||||
std::shared_ptr<app::AppContext> _Nullable getCurrentAppContext() {
|
||||
assert(loader_singleton);
|
||||
if (loader_singleton->mutex.lock(10 / portTICK_PERIOD_MS)) {
|
||||
auto app = loader_singleton->appStack.top();
|
||||
loader_singleton->mutex.unlock();
|
||||
return std::move(app);
|
||||
} else {
|
||||
return nullptr;
|
||||
}
|
||||
loader_singleton->mutex.lock();
|
||||
auto app = loader_singleton->appStack.top();
|
||||
loader_singleton->mutex.unlock();
|
||||
return app;
|
||||
}
|
||||
|
||||
std::shared_ptr<app::App> _Nullable getCurrentApp() {
|
||||
|
||||
Reference in New Issue
Block a user