1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-02-03 03:30:06 +00:00

added FileDragAndDropTarget class and rewrote all the drag handling code

This commit is contained in:
jules 2007-09-26 14:43:50 +00:00
parent 6d2d246768
commit 60e1be176e
44 changed files with 1182 additions and 829 deletions

View file

@ -3502,38 +3502,6 @@ void Component::internalModifierKeysChanged()
}
//==============================================================================
bool Component::filesDropped (const StringArray&, int, int)
{
// base class returns false to let the message get passed up to its parent
return false;
}
void Component::internalFilesDropped (const int x,
const int y,
const StringArray& files)
{
if (isCurrentlyBlockedByAnotherModalComponent())
{
internalModalInputAttempt();
if (isCurrentlyBlockedByAnotherModalComponent())
return;
}
Component* c = getComponentAt (x, y);
while (c->isValidComponent())
{
int rx = x, ry = y;
relativePositionToOtherComponent (c, rx, ry);
if (c->filesDropped (files, rx, ry))
break;
c = c->getParentComponent();
}
}
ComponentPeer* Component::getPeer() const throw()
{
if (flags.hasHeavyweightPeerFlag)