Files
tactility_apps/Apps/M5UnitTest/main/Source/M5UnitTest.h
Shadowtrance dbf850c434 Fixes and new apps (#30)
- M5 Unit Modules library + M5 Unit Test app
- Minor fixes for TodoList, TwoEleven, Snake, Brainfuck and Breakout
- Fixed SerialConsole to use the uart controller as it was broken in one of the many updates
- Fixed keyboard input in TwoEleven, Breakout, Magic8Ball and Snake
- Bluetooth Media Keys app, supports pressing physical keys to trigger the corresponding buttonmatrix button
- Epub Reader app
2026-06-07 15:56:32 +02:00

35 lines
1009 B
C++

#pragma once
#include <tt_app.h>
#include <lvgl.h>
#include <TactilityCpp/App.h>
// Forward declarations for test views
class TestListView;
class TestViewBase;
class M5UnitTest final : public App {
public:
void onShow(AppHandle handle, lv_obj_t* parent) override;
void onHide(AppHandle handle) override;
// Called by TestListView when user selects a unit to test
void showTest(int unitIndex);
// Called by test views when user presses back
void showList();
// Called by the Back button path after the view has already been deleted
void clearActiveTestView() { activeTestView_ = nullptr; }
AppHandle getAppHandle() const { return appHandle_; }
private:
AppHandle appHandle_ = nullptr;
lv_obj_t* wrapper_ = nullptr; // full-screen container, cleaned between views
TestListView* listView_ = nullptr;
TestViewBase* activeTestView_ = nullptr;
static M5UnitTest* s_instance;
void createWrapper(lv_obj_t* parent);
};