• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
NSTimer and NSLock
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSTimer and NSLock


  • Subject: NSTimer and NSLock
  • From: Lorenzo <email@hidden>
  • Date: Sun, 13 Jul 2008 12:13:45 +0200

Hi,
I need to execute a method only after a thread has been executed.
I guess I have to lock that thread but I don't know how.
The thread I should lock comes from a timer

    timer = [[NSTimer scheduledTimerWithTimeInterval:timeInterval
                target:self selector:@selector(UpdateWindow:)
                userInfo:nil repeats:YES] retain];
    [[NSRunLoop currentRunLoop] addTimer:timer
                forMode:NSEventTrackingRunLoopMode];
    [[NSRunLoop currentRunLoop] addTimer:timer
                forMode:NSModalPanelRunLoopMode];


So only when UpdateWindow as been executed I have to delete an object and
prevent to work with a null pointer. Any suggestion?


Best Regards
--
Lorenzo
email: email@hidden

_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden

  • Follow-Ups:
    • Re: NSTimer and NSLock
      • From: "Michael Ash" <email@hidden>
    • Re: NSTimer and NSLock
      • From: Simone Tellini <email@hidden>
  • Prev by Date: Google map view in my iPhone application
  • Next by Date: Re: NSTimer and NSLock
  • Previous by thread: Google map view in my iPhone application
  • Next by thread: Re: NSTimer and NSLock
  • Index(es):
    • Date
    • Thread