mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Use C++14 lambda capture initialisers for initialising deletion checkers
This commit is contained in:
parent
5a78b06f5c
commit
a5c3b81f82
33 changed files with 159 additions and 193 deletions
|
|
@ -482,14 +482,11 @@ void ComboBox::showPopupIfNotActive()
|
|||
{
|
||||
menuActive = true;
|
||||
|
||||
SafePointer<ComboBox> safePointer (this);
|
||||
|
||||
// as this method was triggered by a mouse event, the same mouse event may have
|
||||
// exited the modal state of other popups currently on the screen. By calling
|
||||
// showPopup asynchronously, we are giving the other popups a chance to properly
|
||||
// close themselves
|
||||
MessageManager::callAsync ([safePointer]() mutable { if (safePointer != nullptr) safePointer->showPopup(); });
|
||||
|
||||
MessageManager::callAsync ([safePointer = SafePointer<ComboBox> { this }]() mutable { if (safePointer != nullptr) safePointer->showPopup(); });
|
||||
repaint();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue