• 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
Foundation Tool and NSDistributedNotificationCenter
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Foundation Tool and NSDistributedNotificationCenter


  • Subject: Foundation Tool and NSDistributedNotificationCenter
  • From: Zephyroth Akash <email@hidden>
  • Date: Fri, 23 Oct 2009 17:37:28 +0200

Hi,

I'm writing a Foundation Tool which detect some hardware components and launch an application.

Once the application is running it ask the user to make a choice and then post a notification to the "daemon".

It works fine, the tool get the notification and do its work ... but I'm unable to notify the application that the work is done.

Nothing happens.

At the end of my "main.m":

NSDistributedNotificationCenter *dnc = [NSDistributedNotificationCenter defaultCenter];
[dnc addObserver:hardDetect selector:@selector(getBootInfo:) name:@"getBootInfo" object:nil];

[[NSRunLoop currentRunLoop] run];


hardDetect is an instance of "HardwareController.m" in which I've used another NSDistributedNotificationCenter but it don't seem to be the right way.

I think I need to use the Distributed Notification Center defined in "main.m" but I don't know how to access it from "HardwareController.m".

Zephyroth.
_______________________________________________

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: Foundation Tool and NSDistributedNotificationCenter
      • From: Jerry Krinock <email@hidden>
    • Re: Foundation Tool and NSDistributedNotificationCenter
      • From: Jens Alfke <email@hidden>
  • Prev by Date: Re: is GC not available on 10.5.8?
  • Next by Date: Re: is GC not available on 10.5.8?
  • Previous by thread: New AquaticPrime home on github
  • Next by thread: Re: Foundation Tool and NSDistributedNotificationCenter
  • Index(es):
    • Date
    • Thread