diff --git a/photohunt.xcodeproj/project.xcworkspace/xcuserdata/seanmcgary.xcuserdatad/UserInterfaceState.xcuserstate b/photohunt.xcodeproj/project.xcworkspace/xcuserdata/seanmcgary.xcuserdatad/UserInterfaceState.xcuserstate index e51ce4a..ef90ded 100644 Binary files a/photohunt.xcodeproj/project.xcworkspace/xcuserdata/seanmcgary.xcuserdatad/UserInterfaceState.xcuserstate and b/photohunt.xcodeproj/project.xcworkspace/xcuserdata/seanmcgary.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/photohunt/CameraViewController.m b/photohunt/CameraViewController.m index b38fc1b..7ff00b2 100644 --- a/photohunt/CameraViewController.m +++ b/photohunt/CameraViewController.m @@ -38,8 +38,7 @@ - (id) init self.delegate = self; self.locMgr = [[CLLocationManager alloc] init]; - self.locMgr.delegate = self; - + self.locMgr.delegate = self; } @@ -128,6 +127,9 @@ - (void) imagePickerController:(UIImagePickerController *)picker didFinishPickin [photoContainer setObject:image forKey:@"image"]; EditPhotoViewController *editPhoto = [[EditPhotoViewController alloc] initWithPhoto:photoContainer]; + [[UIApplication sharedApplication] setStatusBarHidden:NO animated:NO]; + [[UIApplication sharedApplication] setStatusBarStyle:UIStatusBarStyleDefault animated:YES]; + [self pushViewController:editPhoto animated:YES]; } diff --git a/photohunt/EditPhotoViewController.m b/photohunt/EditPhotoViewController.m index 75a7c60..6434810 100644 --- a/photohunt/EditPhotoViewController.m +++ b/photohunt/EditPhotoViewController.m @@ -122,24 +122,21 @@ - (void)viewDidLoad int yOffset = 0; + + if(self.navigationController.navigationBarHidden){ NSLog(@"navbar hidden"); [self.navigationController setNavigationBarHidden:NO animated:YES]; - //scrollView.frame.origin = CGPointMake(0, 50); - - yOffset = 30; + if([self.parentViewController isKindOfClass:[UIImagePickerController class]]) + { + yOffset = 50; + } } - scrollView.frame = self.view.frame; + scrollView.frame = CGRectMake(self.view.frame.origin.x, yOffset, self.view.frame.size.width, self.view.frame.size.height); - if(self.navigationController.toolbarHidden){ - NSLog(@"toolbar hidden"); - //yOffset = 0; - } - - scrollView.frame = CGRectMake(0, yOffset, (self.view.frame.size.width), self.view.frame.size.height); scrollView.contentSize = CGSizeMake(self.view.frame.size.width, 700); @@ -252,8 +249,6 @@ - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interface - (void)viewDidAppear:(BOOL)animated { [super viewDidAppear:animated]; - - //[self.navigationController setNavigationBarHidden:YES animated:YES]; } - (void) viewWillAppear:(BOOL)animated @@ -262,9 +257,6 @@ - (void) viewWillAppear:(BOOL)animated self.photoWithMetaData = [[NSMutableDictionary alloc] initWithDictionary:[AppHelper getPhotoDataForPhotoName:[self.photoWithMetaData objectForKey:@"photoName"]]]; - self.view.frame = [[UIScreen mainScreen] applicationFrame]; - self.scrollView.frame = self.view.frame; - } - (IBAction)doneButtonPressed:(id)sender