|
| 1 | +// |
| 2 | +// SubSubViewController.m |
| 3 | +// ViewControllerMemorySample |
| 4 | +// |
| 5 | +// Created by Hiroshi Hashiguchi on 10/10/19. |
| 6 | +// Copyright 2010 . All rights reserved. |
| 7 | +// |
| 8 | + |
| 9 | +#import "SubSubViewController.h" |
| 10 | + |
| 11 | + |
| 12 | +@implementation SubSubViewController |
| 13 | +@synthesize parentImageView; |
| 14 | + |
| 15 | +/* |
| 16 | + // The designated initializer. Override if you create the controller programmatically and want to perform customization that is not appropriate for viewDidLoad. |
| 17 | +- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil { |
| 18 | + if ((self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil])) { |
| 19 | + // Custom initialization |
| 20 | + } |
| 21 | + return self; |
| 22 | +} |
| 23 | +*/ |
| 24 | + |
| 25 | +// Implement viewDidLoad to do additional setup after loading the view, typically from a nib. |
| 26 | +- (void)viewDidLoad { |
| 27 | + [super viewDidLoad]; |
| 28 | + NSLog(@"[SubSub] viewDidLoad|retainCount=%d", [self.parentImageView retainCount]-1); |
| 29 | + |
| 30 | +} |
| 31 | + |
| 32 | +- (void)viewWillAppear:(BOOL)animated { |
| 33 | + NSLog(@"[SubSub] viewWillAppear|retainCount=%d", [self.parentImageView retainCount]-1); |
| 34 | + |
| 35 | +} |
| 36 | +- (void)viewDidAppear:(BOOL)animated { |
| 37 | + NSLog(@"[SubSub] viewDidAppear|retainCount=%d", [self.parentImageView retainCount]-1); |
| 38 | + |
| 39 | +} |
| 40 | +/* |
| 41 | +// Override to allow orientations other than the default portrait orientation. |
| 42 | +- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { |
| 43 | + // Return YES for supported orientations |
| 44 | + return (interfaceOrientation == UIInterfaceOrientationPortrait); |
| 45 | +} |
| 46 | +*/ |
| 47 | + |
| 48 | +- (void)didReceiveMemoryWarning { |
| 49 | + // Releases the view if it doesn't have a superview. |
| 50 | + [super didReceiveMemoryWarning]; |
| 51 | + |
| 52 | + // Release any cached data, images, etc that aren't in use. |
| 53 | +} |
| 54 | + |
| 55 | +- (void)viewDidUnload { |
| 56 | + [super viewDidUnload]; |
| 57 | + // Release any retained subviews of the main view. |
| 58 | + // e.g. self.myOutlet = nil; |
| 59 | +} |
| 60 | + |
| 61 | + |
| 62 | +- (void)dealloc { |
| 63 | + [super dealloc]; |
| 64 | +} |
| 65 | + |
| 66 | + |
| 67 | +@end |
0 commit comments