uiinterfaceorientation

iPad iOS7 - UIImagePickerController in UIPopoverController has wrong preview image

拥有回忆 提交于 2019-11-28 06:20:18
I am using an UIImagePickerController within an UIPopoverController which is working perfectly with iOS6. With iOS 7 the "preview" image which is shown to capture the image is rotated, but if I take a picture it is saved correctly. This is how I get my picker: UIImagePickerController *imagePicker = [[UIImagePickerController alloc] init]; imagePicker.delegate = self; imagePicker.sourceType = UIImagePickerControllerSourceTypeCamera; imagePicker.mediaTypes = [NSArray arrayWithObjects: (NSString *) kUTTypeImage, nil]; imagePicker.allowsEditing = NO; And add it to a popover controller: self

how to set Orientation after launch on iPhone

南楼画角 提交于 2019-11-27 22:49:53
问题 i Will like to know how to auto rotate iphone after launch. my launch image is in portraits but the app itself are in landscape. after launch the orientation are still in portraits instead of auto rotate to landscape. this is my info.plist in my root view controller - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { // Return YES for supported orientations return ((interfaceOrientation == UIInterfaceOrientationLandscapeLeft) || (interfaceOrientation

Understanding iOS 6 Interface orientation change

假如想象 提交于 2019-11-27 21:56:43
ADDED: I see that my question is viewed often without upvotes so I decided that you guys do not get what you search. Redirecting you to question that has really nice answer about How to handle orientation changes in iOS6 Specific demands to orientation changes: Restricted rotation Upvotes are welcome :) I've created a new project from Master Detail template and trying to start it with landscape orientation. As you know the - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation method is deprecated and we must use - (NSUInteger)supportedInterfaceOrientations

Forcing landscape orientation on fullscreen MPMoviePlayerController prevents correct rotation when exiting fullscreen

淺唱寂寞╮ 提交于 2019-11-27 21:24:57
I have an iPhone application (iOS6+) that supports all interface orientations. However, only landscape orientation should be supported when an MPMoviePlayerController is playing a video fullscreen. I found the following solution on Stack Overflow and it works. [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(moviePlayerWillEnterFullscreenNotification:) name:MPMoviePlayerWillEnterFullscreenNotification object:nil]; [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(moviePlayerWillExitFullscreenNotification:) name

Unable to handle orientation in iOS 6?

为君一笑 提交于 2019-11-27 20:05:39
问题 I am using - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation delegate to change the frame of my view based on the orientation type i.e., if(UIInterfaceOrientationIsLandscape(interfaceOrientation)) { self.view.frame=CGRectMake(0,0,500,300); } else { self.view.frame=CGRectMake(0,0,300,400); } How to handle the same situation in iOS 6 as -(BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation has been deprecated in iOS6

setStatusBarOrientation:animated: not working in iOS 6

南楼画角 提交于 2019-11-27 19:56:11
I've used this code to force an orientation change back to portrait when the user is finished watching the video (it allows viewing in landscape mode), before popping the video view controller off the navigation controller: //set statusbar to the desired rotation position [[UIApplication sharedApplication] setStatusBarOrientation:UIDeviceOrientationPortrait animated:NO]; //present/dismiss viewcontroller in order to activate rotating. UIViewController *mVC = [[[UIViewController alloc] init] autorelease]; [self presentModalViewController:mVC animated:NO]; [self dismissModalViewControllerAnimated

How do I restrict orientation per view controller in iOS7 in a navigation controller hierarchy

一曲冷凌霜 提交于 2019-11-27 18:38:58
问题 My app is a UITabBarController --> UINavigationController --> UITableViewController --> UIViewController. I want to do 2 things: Prevent my tableview from rotating, I want it to always stay portrait. FORCE & Allow my UIViewcontroller to rotate landscapeleft. What I know: I understand that the viewcontroller at the top of the hierarchy controls rotation. This would be my UITabBarController? Or rather its only viewcontroller which would be at objectIndex:0? My project settings allow for

How do I detect orientation on app launch for splash screen animation on iPad!

前提是你 提交于 2019-11-27 12:59:12
问题 Hi I have an app and I have two *.pngs for default splash screen: Default-Landscape.png Default-Portrait.png What I want is to animate this default splash screen away when my app is loaded and ready to go. To achieve this I would normally present an UIImageView with either default-landscape or default-portrait (depending on the device orientation), keep it on screen for a certain time and then animate it away. My problem is that if I call [[UIDevice currentDevice] orientation] in - (BOOL

Status bar is Landscape, but [[UIApplication sharedApplication] statusBarOrientation] returns portrait

独自空忆成欢 提交于 2019-11-27 10:35:18
问题 This problem appears to be intermittent, but I am not sure why exactly. When running my application on the device (iPad), I have some code to load a scroll view with some image views according to the current device orientation. Even though the device is landscape before loading, the views are being loaded as if it were portrait. The orientation is found by calling [[UIApplication sharedApplication] statusBarOrientation] . The views are set up to adjust their positions when the device is

disable autorotate on a single UIViewController in iOS6

不羁的心 提交于 2019-11-27 07:28:02
I have a project using UINavigationController and segues working properly good, all of them rotate correctly, the thing is... I just want to disable autorotation on a specific UIViewController . I tried this: - (BOOL)shouldAutorotateToInterfaceOrientation: (UIInterfaceOrientation)interfaceOrientation { return NO; } // New Autorotation support for iOS 6. - (BOOL)shouldAutorotate NS_AVAILABLE_IOS(6_0){ return NO; } - (NSUInteger)supportedInterfaceOrientations { return UIInterfaceOrientationMaskPortrait; } but it's not working, my UIViewController keeps rotating automatically, any help will be