3

I was looking for a list of Distributed Notifications that exists on mac like iTunes com.apple.iTunes.playerInfo but I couldn't find anything. I was wondering if other applications like Safari or QuickTime does have such notifications? And if they exists what are their notification names?

Regards

Abcd Efg
  • 2,146
  • 23
  • 41

1 Answers1

8

By adding an observer and setting it's name to nil it will show all the notifications.

[[NSDistributedNotificationCenter defaultCenter] addObserver:self selector:@selector(observerMethod:) name:nil object:nil];

I didn't find anything special.

Abcd Efg
  • 2,146
  • 23
  • 41
  • This seems like it stopped working at least on Xcode 13.2.1 and/or macOS 12.3.1. When I do specify "com.apple.iTunes.playerInfo", it does work. – Genki Apr 18 '22 at 17:55