Fix compilation with C++20

Fixes #428
This commit is contained in:
Olivier Goffart 2021-08-20 18:43:52 +02:00
parent b42c187ed1
commit 59e1361388
2 changed files with 15 additions and 2 deletions

View file

@ -45,7 +45,7 @@ private:
sixtyfps::Timer clock_update_timer;
};
ClockWidget::ClockWidget() : clock_update_timer(std::chrono::seconds(1), [=]() { update_clock(); })
ClockWidget::ClockWidget() : clock_update_timer(std::chrono::seconds(1), [this] { update_clock(); })
{
}
@ -72,7 +72,7 @@ private:
};
HumidityWidget::HumidityWidget()
: fake_humidity_update_timer(std::chrono::seconds(5), [=]() { update_fake_humidity(); }),
: fake_humidity_update_timer(std::chrono::seconds(5), [this] { update_fake_humidity(); }),
rng(std::chrono::system_clock::now().time_since_epoch().count())
{
}