# Switch to External Drag And Drop issue on Mac + suggested fix

**URL:** <https://forum.juce.com/t/switch-to-external-drag-and-drop-issue-on-mac-suggested-fix/34120>\
**Category:** General JUCE discussion\
**Created:** [June 27, 2019, 8:06am UTC](https://forum.juce.com/t/switch-to-external-drag-and-drop-issue-on-mac-suggested-fix/34120 "2019-06-27T08:06:10Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dave-elton](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/dave-elton/32/7869_2.png) [@dave-elton](https://forum.juce.com/u/dave-elton)\
**Post date:** [June 27, 2019, 8:06am UTC](https://forum.juce.com/t/switch-to-external-drag-and-drop-issue-on-mac-suggested-fix/34120/1 "2019-06-27T08:06:10Z")

</div>

Our testers hit an issue when dragging from a JUCE app to another app on the Mac and think I’ve found a solution as per the change to juce\_DragAndDropContainer.cpp below.

Can anyone spot any unwanted side effects from this change?

The specific case is when the user uses cmd+tab to switch to another app that then renders on top of the JUCE application. (e.g. cmd+tab to a Finder window which now appears above our app), and the app does not switch to an external drag and drop.

Note that we are using `DragAndDropContainer::shouldDropFilesWhenDraggedExternally()` to switch from an internal drag to an external drag, however this does not get called.

Triggering the `checkForExternalDrag` when `Process::isForegroundProcess ()` is false as per the change below appears to address this.

> <https://github.com/daveelton/JUCE/commit/5dc9f59697d14b2adfabb98a8edb502ac181d874>

Thanks for any insights!  
Dave
