From 9be6f7b186f363fc323116a74b013c1981a2fd5d Mon Sep 17 00:00:00 2001 From: Sander Speetjens Date: Wed, 27 Nov 2024 19:01:30 +0100 Subject: [PATCH] update test sim --- tools/simulators/test_sim.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/simulators/test_sim.cpp b/tools/simulators/test_sim.cpp index 39ad73b..09de6ee 100644 --- a/tools/simulators/test_sim.cpp +++ b/tools/simulators/test_sim.cpp @@ -27,13 +27,12 @@ m_led("Led", Color(Color::White), Color(Color::Black), Color(Color::Red)) this->add_UI_item(&this->m_led); this->add_UI_item(&this->m_checkbox); - QObject::connect(&m_button, &UI_button::on_click, [this] { button_clicked(&m_button); }); - QObject::connect(&m_slider, &UI_slider::on_change, [this](double value) { slider_changed(&m_slider, value); }); + QObject::connect(&m_button, &UI_button::on_click, this, [=, this] { button_clicked(&m_button); }); + QObject::connect(&m_slider, &UI_slider::on_change, this, [=, this](double value) { slider_changed(&m_slider, value); }); } void Test_Sim::timer() { - // Timer function this->m_button.click(); if (this->m_slider.value() == this->m_slider.max()) {