ios - FirstViewController is not working when Second ViewController is removed from its superview -
I am using a UIStoryBoard so that first to view ViewController as a subview of another ViewController view.
- (IBAction) btnMoveTo: (ID) sender {UIStoryboard * storyboard = [UIStoryboard storyboardWithName: @ "Mainstoreboard" bundle: zero]; UIViewController * vc = [Storyboard Instant Viewer Identifier: @ "seconds"]; Vc.view.backgroundColor = [UIColor clear collar]; Self. Model Presentation Style = UIModal PresentationConfigurationSettings; [Self-Present Model Week Controller: Animated Vcc: No]; } second viewer. M
- (zero) viewDidoad {self.view.opaque = YES; Self.view.backgroundColor = [UIColor clear collar]; } - Draw with (IBAction): (ID) sender {[with self-view removal zoom animation: 2 options: zero]; } When I use with the Dre function, the second view controller's view is removed and the first viewer is back. However, when I use the button - (IBAction) the btnMoveTo: (id) sender function. It does not work, nothing really does happen. Any suggestions or help would be greatly appreciated.
You are confused with visual controllers. View Controllers are objects that control the sequences, so for your first line,
I am using a UIStoryBoard so that the ViewController first views the view of the other ViewController as a subview Can be added. When removing sub views using the following method, you can add a view controller as a subview of another view controller. You present a visual controller that manages your ideas. , And you can add UIViews as a UIViewController sub-view. A UIViewController management UIView s. There is a problem with the code you posted, that is, when you turn onDraw: function, you do not see the controller looking to delete view of the view controller You must dismiss the second view controller to recover the FirstViewController.
Comments
Post a Comment