diff --git a/Libraries/LibGUI/MessageBox.cpp b/Libraries/LibGUI/MessageBox.cpp index 3bec6bbd82..5a2c2f6f9c 100644 --- a/Libraries/LibGUI/MessageBox.cpp +++ b/Libraries/LibGUI/MessageBox.cpp @@ -129,7 +129,7 @@ void MessageBox::build() button->set_size_policy(SizePolicy::Fill, SizePolicy::Fixed); button->set_preferred_size(0, 20); button->set_text(label); - button->on_click = [=](auto&) { + button->on_click = [this, label, result](auto&) { dbg() << "GUI::MessageBox: '" << label << "' button clicked"; done(result); }; diff --git a/Libraries/LibHTML/HtmlView.cpp b/Libraries/LibHTML/HtmlView.cpp index 259fae0231..8d491d4e62 100644 --- a/Libraries/LibHTML/HtmlView.cpp +++ b/Libraries/LibHTML/HtmlView.cpp @@ -332,7 +332,7 @@ void HtmlView::load(const URL& url) if (on_load_start) on_load_start(url); - ResourceLoader::the().load(url, [=](auto data) { + ResourceLoader::the().load(url, [this, url](auto data) { if (data.is_null()) { dbg() << "Load failed!"; ASSERT_NOT_REACHED(); diff --git a/Servers/WindowServer/Compositor.cpp b/Servers/WindowServer/Compositor.cpp index 8af877ec4c..a4dc00a818 100644 --- a/Servers/WindowServer/Compositor.cpp +++ b/Servers/WindowServer/Compositor.cpp @@ -75,7 +75,7 @@ Compositor::Compositor() }; m_compose_timer->set_single_shot(true); m_compose_timer->set_interval(1000 / 60); - m_immediate_compose_timer->on_timeout = [=]() { + m_immediate_compose_timer->on_timeout = [this]() { #if defined(COMPOSITOR_DEBUG) dbgprintf("Compositor: immediate frame callback: %d rects\n", m_dirty_rects.size()); #endif