The buttons on the UIView jump to a controller UIViewController, And the uiviewcontroller jumps
I now have a UIControllerView in which addView has a UIView. When I click UIView, I go to another UIControllerView and press the return button above the navigation bar to return the first UIControllerView, how to Use pushViewController in that UIView
Send messages in UIView
[[Nsicationcenter center defacenter center] postNotificationName: @ "push" object: nil];
Receive messages in the parent class controller and
[[Nsicationcenter center defacenter center] addObserver: self selector: @ selector (pushOne) name: @ "push" object: nil];
-(Void) pushOne
{
YYCSettingController * setting = [[YYCSettingController alloc] init];
[Self. navigationController pushViewController: setting animated: YES];
}
Send message
[[Nsicationicationcenter defacenter center]
PostNotificationName: @ "chuandi" object: self];
The action of writing an action to receive a message
[[Nsicationcenter center defacenter center] addObserver: self
Selector: @ selector (action)
Name: @ "chuandi" object: nil];
For example, if you trigger an event in a subclass and send the message to the parent class, the action in the parent class is pushed to another subclass.