1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-24 01:54:22 +00:00

Use C++14 lambda capture initialisers for initialising deletion checkers

This commit is contained in:
ed 2021-07-12 11:58:29 +01:00
parent 5a78b06f5c
commit a5c3b81f82
33 changed files with 159 additions and 193 deletions

View file

@ -667,8 +667,8 @@ void CppCodeEditorComponent::insertComponentClass()
asyncAlertWindow->addButton (TRANS ("Insert Code"), 1, KeyPress (KeyPress::returnKey));
asyncAlertWindow->addButton (TRANS ("Cancel"), 0, KeyPress (KeyPress::escapeKey));
SafePointer<CppCodeEditorComponent> parent { this };
asyncAlertWindow->enterModalState (true, ModalCallbackFunction::create ([parent, classNameField] (int result)
asyncAlertWindow->enterModalState (true,
ModalCallbackFunction::create ([parent = SafePointer<CppCodeEditorComponent> { this }, classNameField] (int result)
{
if (parent == nullptr)
return;