0

I have developing project in iOS 6.0 sdk which should work on iOS4.3+ devices, in my project i am using the page curl to navigate betwwen pages , but the page curl happening in LandscapeLeft is not as same as Pagecurl in Landscape Right.
I want the same page curl that is happening in Landscape Left to be in Landscape right.
Please take a look at the link for better understanding. Video Demo Link

The code i have used is shown below

    -(IBAction)nextBtnTapped {

    UIDeviceOrientation deviceOrientation=[UIDevice currentDevice].orientation;

    page2 *Obj=[[page2 alloc]init];

    [UIView beginAnimations:nil context:NULL];

    [UIView setAnimationDuration:1];

    if (deviceOrientation==UIDeviceOrientationLandscapeLeft) 

        [UIView setAnimationTransition:UIViewAnimationTransitionCurlUp forView:self.navigationController.view cache:NO];

    else if(deviceOrientation==UIDeviceOrientationLandscapeRight) 

        [UIView setAnimationTransition:UIViewAnimationTransitionCurlDown forView:self.navigationController.view cache:NO];

    [self.navigationController pushViewController:Obj animated:NO];

    [UIView commitAnimations];
}


-(IBAction)prevBtnTapped {

    UIDeviceOrientation deviceOrientation=[UIDevice currentDevice].orientation;

    [UIView beginAnimations:nil context:NULL];

    [UIView setAnimationDuration:0.8];

    if (deviceOrientation==UIDeviceOrientationLandscapeLeft) 

        [UIView setAnimationTransition:UIViewAnimationTransitionCurlDown forView:self.navigationController.view cache:NO];

    else if(deviceOrientation==UIDeviceOrientationLandscapeRight) 

        [UIView setAnimationTransition:UIViewAnimationTransitionCurlUp forView:self.navigationController.view cache:NO];

    [self.navigationController popViewControllerAnimated:YES];

    [UIView commitAnimations];
}

Can any one please tell me what wrong have i done in this code. Any help will be appreciated.

Buzz
  • 6,030
  • 4
  • 33
  • 47
Yuva
  • 125
  • 3
  • 11

1 Answers1

0

UIDeviceOrientationLandscapeLeft with page curl is bugged. You won't get it to work correctly.

elp
  • 8,021
  • 7
  • 61
  • 120
Sulthan
  • 128,090
  • 22
  • 218
  • 270
  • That is horrible to hear...Can you tell me the alternative for this. – Yuva Dec 19 '12 at 11:50
  • Didn't find any (I am using Core Animation transitions directly). The only possibility is to use non-standard animations, e.g. https://github.com/xissburg/XBPageCurl – Sulthan Dec 19 '12 at 11:56