Top "Nsnotificationcenter" questions

NSNotificationCenter allows to send and register for notifications in the Foundation framework, which is provided by Apple.

Why is my NSNotification its observer called multiple times?

Within an App I make use of several viewcontrollers. On one viewcontroller an observer is initialized as follows: [[NSNotificationCenter defaultCenter] …

ios iphone uiviewcontroller nsnotificationcenter nsnotifications
Android equivalent to NSNotificationCenter

In the process of porting an iPhone application over to android, I am looking for the best way to communicate …

android iphone ios events nsnotificationcenter
Swift 3 NSNotificationCenter Keyboardwillshow/hide

I have a piece of code that worked in Swift 2 and I tried using Xcode to update the code to …

ios swift nsnotificationcenter swift3
OS X: Detect system-wide keyDown events?

I'm working on a typing-tutor application for Mac OS X that needs to have keystrokes forwarded to it, even when …

macos keyboard keydown nsnotificationcenter
Detect rotation changes in iOS

I am making an iOS app that needs to do a little interface rearrangement upon rotation. I am trying to …

ios interface nsnotificationcenter screen-rotation autorotate
Add 'addObserver' (NSNotificationCenter ) in a 1st view controller, handle in 2nd

I saw a few examples about adding observer and handle in the same class, but what I want to know …

ios objective-c nsnotificationcenter nsnotification observers
Adding and removing observers to NSNotificationCenter in a UIViewController

Looking at various Apple examples (for example Add Music) in which I see they add observers to the default NSNotificationCenter …

objective-c ios dealloc nsnotificationcenter addobserver
iOS 11 - Keyboard Height is returning 0 in keyboard notification

I have been using Keyboard notifications without any problem and getting exact height of Keyboard. - (void)keyboardDidShow:(NSNotification *) notification{ …

ios objective-c nsnotificationcenter
Post of NSNotificationCenter causing "EXC_BAD_ACCESS" exception

A UIViewController adds itself to the default center: [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(editFood) name:@"editFood" object:nil]; Then …

ios objective-c iphone exc-bad-access nsnotificationcenter
Does removeObserver() remove all observers?

Does the following remove all NSNotificationCenter.defaultCenter there were added by name a view? NotificationCenter.default.removeObserver(self) If I …

swift nsnotificationcenter