On 2010 Feb 03, at 21:06, Trygve Inda wrote:
> Do I just need to keep a temporary array of paths that I have processed and
> search it for each file.
That's one way that would work. Another way would be to, before processing
each item, iterate through its lineage, somethling like this:
parent = theItem ;
BOOL processThisItem = YES ;
do {
parent = [theItem parent] ;
if ([parent isInTheDroppedArray]) {
processThisItem = NO ;
break ;
}
} while (parent != nil) ;
if (processThisItem) {
...
}
I don't know if it would be any more or less efficient than your original idea.
Probably depends on the "dimensions" of the typical drop.
> Could be a lot of searching if the user drops the
> entire Documents folder.
Yup. No matter how you do it.
_______________________________________________
Cocoa-dev mailing list ([email protected])
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com
This email sent to [email protected]