Swift 2 addObserver for specific textField with the object parameter
问题 To my understanding the object parameter of the addObserver method is the object you want to receive notifications from. Most of the time I see it as nil (I assume this is because notifications of the specified type are wanted from all objects). In my particular case I have a text field at the top of the screen and at the bottom of the screen and I want the view to move up only when the user taps the bottom text field, not the top one. So I call the following method in viewWillAppear func