The following succeeds in performing the external file drag but uses the standard os drag icon. I was hoping the component image would display in place of the standard icon but this is only true when I comment out the line DOING the external file drag, which is no good.
Is it possible to do both?
class MyDraggableComp : public juce::TextButton,
public juce::DragAndDropContainer
{
public:
MyDraggableComp() {}
juce::ComponentDragger myDragger;
juce::File outf = juce::File::getSpecialLocation(juce::File::SpecialLocationType::userDesktopDirectory ).getChildFile( "file.mid" );
void mouseDown (const juce::MouseEvent& e) override
{
myDragger.startDraggingComponent (this, e);
}
void mouseDrag (const juce::MouseEvent& e) override
{
performExternalDragDropOfFiles(outf.getFullPathName(),true,this, [this] ( void ) {});
DragAndDropContainer::startDragging("asdf",this,juce::Image(),true);
}
};