Re: Interrupt copyItemAtPath

2010-11-08 Thread Kyle Sluder
On Mon, Nov 8, 2010 at 8:36 AM, gMail.com wrote: > Something like >    if(stage == kFSOperationStageComplete){ >        go and copy the next file >    } > > would make me redesign all of my code... > So it doesn't sound as the best solution for me. Sometimes you have to realize that the design yo

Re: Interrupt copyItemAtPath

2010-11-08 Thread gMail.com
the best solution for me. -- Leo > Da: Sherm Pendley > Data: Sun, 7 Nov 2010 19:33:26 -0500 > A: "gMail.com" > Cc: Ken Thomases , > Oggetto: Re: Interrupt copyItemAtPath > > On Sun, Nov 7, 2010 at 6:06 PM, gMail.com wrote: >> >> A quick que

Re: Interrupt copyItemAtPath

2010-11-08 Thread gMail.com
Sherm, I verified, if I quit, the file being copied gets properly deleted, because before quitting, in the metho ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the mod

Re: Interrupt copyItemAtPath

2010-11-07 Thread Sherm Pendley
On Sun, Nov 7, 2010 at 6:06 PM, gMail.com wrote: > > A quick question more please. > As I have seen on the Apple sample code "FSFileOperation", > I can wait until FSCopyObjectAsync is done, using CFRunLoopRunInMode. > >        while(!gFileCopiedDone && !mUserPressedStop){ >            CFRunLoopRun

Re: Interrupt copyItemAtPath

2010-11-07 Thread Kyle Sluder
On Sun, Nov 7, 2010 at 3:06 PM, gMail.com wrote: > As I have seen on the Apple sample code "FSFileOperation", > I can wait until FSCopyObjectAsync is done, using CFRunLoopRunInMode. This isn't a good idea. Just let the runloop run normally. Do the cancel button checking in your callback. --Kyle

Re: Interrupt copyItemAtPath

2010-11-07 Thread gMail.com
ks, the other apps work... Could this waiting loop cause some problem? -- Leo > Da: Sherm Pendley > Data: Sun, 7 Nov 2010 16:37:19 -0500 > A: "gMail.com" > Cc: Ken Thomases , > Oggetto: Re: Interrupt copyItemAtPath > > On Sun, Nov 7, 2010 at 4:09 PM, gMail.com

Re: Interrupt copyItemAtPath

2010-11-07 Thread Sherm Pendley
On Sun, Nov 7, 2010 at 4:09 PM, gMail.com wrote: > I have checked FSCopyObjectAsync and the copy works well. > I can get my callback function called so I can observe the working progress > as the kFSOperationBytesCompleteKey and kFSOperationTotalBytesKey and get > the kFSOperationStageComplete st

Re: Interrupt copyItemAtPath

2010-11-07 Thread gMail.com
ot;gMail.com" > Cc: > Oggetto: Re: Interrupt copyItemAtPath > > On Nov 6, 2010, at 5:27 PM, gMail.com wrote: > >> I copy a 14GB file with > >> Since the copy could take several minutes, I would grant the user the >> opportunity to interrupt the copy pressing a

Re: Interrupt copyItemAtPath

2010-11-06 Thread Ken Thomases
On Nov 6, 2010, at 5:27 PM, gMail.com wrote: > I copy a 14GB file with > Since the copy could take several minutes, I would grant the user the > opportunity to interrupt the copy pressing a given button. > Or should I use the latest methods from FSCopyObject.c ? FSCopyObject.c? From Apple's sa

Re: Interrupt copyItemAtPath

2010-11-06 Thread James Bucanek
gMail.com wrote (Saturday, November 6, 2010 3:27 PM +0100): I copy a 14GB file with - (BOOL)copyItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath error:(NSError **)error Since the copy could take several minutes, I would grant the user the opportunity t

Interrupt copyItemAtPath

2010-11-06 Thread gMail.com
I copy a 14GB file with - (BOOL)copyItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath error:(NSError **)error Since the copy could take several minutes, I would grant the user the opportunity to interrupt the copy pressing a given button. Is a way to tell copyItemAtPath to break the job and