From 63f280bbfe0aa7eedd16cc81ecfaebb476cd809b Mon Sep 17 00:00:00 2001 From: owenpkent <20529132+owenpkent@users.noreply.github.com> Date: Sun, 2 Aug 2026 12:57:46 -0600 Subject: [PATCH] DragAndDropContainer: Document support for dragging between windows --- modules/juce_gui_basics/mouse/juce_DragAndDropContainer.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/modules/juce_gui_basics/mouse/juce_DragAndDropContainer.h b/modules/juce_gui_basics/mouse/juce_DragAndDropContainer.h index edc77b445ea..b010e94f0d8 100644 --- a/modules/juce_gui_basics/mouse/juce_DragAndDropContainer.h +++ b/modules/juce_gui_basics/mouse/juce_DragAndDropContainer.h @@ -48,6 +48,12 @@ namespace juce callbacks to any child components derived from DragAndDropTarget which the mouse moves over. + By default, a drop can only be received by DragAndDropTargets inside this container. To + allow targets in the application's other windows to receive it too, pass true for + startDragging()'s allowDraggingToOtherJuceWindows parameter. The drag image then becomes a + desktop window of its own, and targets are found by hit-testing the desktop, so a drag can + be dropped onto a target in any window belonging to the same application. + Note: If all that you need to do is to respond to files being drag-and-dropped from the operating system onto your component, you don't need any of these classes: you can do this simply by overriding FileDragAndDropTarget::filesDropped().