From b657472d7fa6dfd6c17b3e9e8d1c4cb50f7c3ce2 Mon Sep 17 00:00:00 2001 From: Sander Speetjens Date: Fri, 23 Aug 2024 15:23:22 +0200 Subject: [PATCH] test_sim implement run at startup function --- tools/simulators/test_sim.cpp | 9 +++++---- tools/simulators/test_sim.hpp | 1 + 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/tools/simulators/test_sim.cpp b/tools/simulators/test_sim.cpp index de70bf7..4b1a436 100644 --- a/tools/simulators/test_sim.cpp +++ b/tools/simulators/test_sim.cpp @@ -19,9 +19,10 @@ p_slider("slider", "Slider", Color(Color::White), Color(Color::Black), 0, 100, 5 void Test_Sim::timer() { // Timer function - // p_button.click(); - // p_combobox.set_selected(1); - // p_checkbox.toggle_selected("Option 2"); - // p_slider.set_value(75); } +void Test_Sim::run_at_startup() +{ + // Run at startup + std::cout << "Test_Sim started" << std::endl; +} diff --git a/tools/simulators/test_sim.hpp b/tools/simulators/test_sim.hpp index 844d6db..8b286ca 100644 --- a/tools/simulators/test_sim.hpp +++ b/tools/simulators/test_sim.hpp @@ -5,6 +5,7 @@ class Test_Sim : public Simulator_base { public: Test_Sim(); void timer() override; + void run_at_startup() override; private: UI_button p_button; UI_combobox p_combobox;