mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
ScopedMessageBox: Add new helper type to bound alert window lifetimes
The biggest new feature in this commit is the addition of NativeMessageBox::scopedAsync and AlertWindow::scopedAsync, both of which return an instance of ScopedMessageBox that will hide the message box in its destructor. The code for displaying modal dialogs on Windows has also been updated. Now, the dialog itself is run from a new thread with its own message loop. This means that when the dialog is dismissed, the background thread can be joined safely. In plugins, this means that there's no danger of the plugin view being destroyed from within the message box runloop, for example.
This commit is contained in:
parent
d14761c523
commit
79ed81c24a
20 changed files with 1438 additions and 1154 deletions
|
|
@ -254,7 +254,10 @@ namespace juce
|
|||
#include "widgets/juce_Toolbar.cpp"
|
||||
#include "widgets/juce_ToolbarItemPalette.cpp"
|
||||
#include "widgets/juce_TreeView.cpp"
|
||||
#include "windows/juce_MessageBoxOptions.cpp"
|
||||
#include "windows/juce_ScopedMessageBox.cpp"
|
||||
#include "windows/juce_AlertWindow.cpp"
|
||||
#include "windows/juce_NativeMessageBox.cpp"
|
||||
#include "windows/juce_CallOutBox.cpp"
|
||||
#include "windows/juce_ComponentPeer.cpp"
|
||||
#include "windows/juce_DialogWindow.cpp"
|
||||
|
|
@ -293,6 +296,7 @@ namespace juce
|
|||
#include "native/juce_ios_UIViewComponentPeer.mm"
|
||||
#include "native/accessibility/juce_ios_Accessibility.mm"
|
||||
#include "native/juce_ios_Windowing.mm"
|
||||
#include "native/juce_ios_NativeMessageBox.mm"
|
||||
#include "native/juce_ios_FileChooser.mm"
|
||||
|
||||
#if JUCE_CONTENT_SHARING
|
||||
|
|
@ -304,6 +308,7 @@ namespace juce
|
|||
#include "native/juce_mac_PerScreenDisplayLinks.h"
|
||||
#include "native/juce_mac_NSViewComponentPeer.mm"
|
||||
#include "native/juce_mac_Windowing.mm"
|
||||
#include "native/juce_mac_NativeMessageBox.mm"
|
||||
#include "native/juce_mac_MainMenu.mm"
|
||||
#include "native/juce_mac_FileChooser.mm"
|
||||
#endif
|
||||
|
|
@ -319,6 +324,7 @@ namespace juce
|
|||
#include "native/accessibility/juce_win32_AccessibilityElement.cpp"
|
||||
#include "native/accessibility/juce_win32_Accessibility.cpp"
|
||||
#include "native/juce_win32_Windowing.cpp"
|
||||
#include "native/juce_win32_NativeMessageBox.cpp"
|
||||
#include "native/juce_win32_DragAndDrop.cpp"
|
||||
#include "native/juce_win32_FileChooser.cpp"
|
||||
|
||||
|
|
@ -330,6 +336,7 @@ namespace juce
|
|||
|
||||
#include "native/x11/juce_linux_ScopedWindowAssociation.h"
|
||||
#include "native/juce_linux_Windowing.cpp"
|
||||
#include "native/juce_linux_NativeMessageBox.cpp"
|
||||
#include "native/x11/juce_linux_XWindowSystem.cpp"
|
||||
|
||||
JUCE_END_IGNORE_WARNINGS_GCC_LIKE
|
||||
|
|
@ -362,6 +369,7 @@ static jobject makeAndroidPoint (Point<int> p)
|
|||
#include "juce_core/files/juce_common_MimeTypes.h"
|
||||
#include "native/accessibility/juce_android_Accessibility.cpp"
|
||||
#include "native/juce_android_Windowing.cpp"
|
||||
#include "native/juce_android_NativeMessageBox.cpp"
|
||||
#include "native/juce_android_FileChooser.cpp"
|
||||
|
||||
#if JUCE_CONTENT_SHARING
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue