From acee397e4c5db67188951578cea9f786c210ddbd Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 13 Feb 2024 01:31:07 +0100 Subject: [PATCH] Avoid implicit "this" capture in a lambda to avoid C++20 warning Implicitly capturing "this" is deprecated in C++20, so do it explicitly, even if it also requires explicitly capturing everything else as combining implicit capture with explicitly capturing "this" is not allowed in the previous C++ versions. --- src/aui/framemanager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/aui/framemanager.cpp b/src/aui/framemanager.cpp index 901a47835d..939de7b4d3 100644 --- a/src/aui/framemanager.cpp +++ b/src/aui/framemanager.cpp @@ -3054,7 +3054,7 @@ void wxAuiManager::ShowHint(const wxRect& rect) const unsigned char b = hintCol.GetBlue(); const unsigned char a = m_hintFadeAmt; - const auto makeBrush = [=]() + const auto makeBrush = [this, r, g, b, a]() { return (m_flags & wxAUI_MGR_VENETIAN_BLINDS_HINT) != 0 ? wxCreateVenetianBlindsBitmap(r, g, b, a)