Windows based iPad application orientation
I want to create iPad windows based application which support orientation by defau开发者_开发技巧lt windows application is not supporting orientation how to enable orientation support in windows based application in iPad.
Thank you
The window has no rotation functionality. It is allays in portrait mode. If you want something to rotate with the device, you should use UIViewController. It has to implement the method shouldAutorotateToInterfaceOrientation and return true for your orientations or remove it for all orientations.
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
// Return YES for supported orientations
return (interfaceOrientation == UIInterfaceOrientationLandscapeRight);
}
You should also change it in the project settings (ProjectName-Info.plist).
精彩评论