2

Does anyone know how to mimic the map curl in the Google Map application without using the undocumented mapCurl and mapUncurl API?

Ideally I would like to do the same thing as the Google Map application. If this is not possible, is there any way to 'slide' the map image up to show the options?

Jimbalaya
  • 150
  • 8
  • I've got a way to do that, to pause the animation. Check the FDCurlViewControl for the code, or the FDCatalog for a sample: https://github.com/FairfaxMobile – vfn Mar 24 '11 at 22:48

2 Answers2

4
SampleViewController *sampleView = [[[SampleViewController alloc] init] autorelease];
[sampleView setModalTransitionStyle:UIModalTransitionStylePartialCurl];
[self presentModalViewController:sampleView animated:YES];
DShah
  • 9,768
  • 11
  • 71
  • 127
Chris Pemberton
  • 146
  • 1
  • 3
  • This works, but doesn't allow for a static toolbar that doesn't curl, like Apple's Maps app. [Here](http://stackoverflow.com/a/11406056/1148702) is an answer that does. – Tim Arnold Jul 10 '12 at 14:57
0
[UIView transitionFromView:self.view toView:overlayView duration:1 options:UIViewAnimationOptionTransitionCurlUp completion:nil];

Will do the animation of the page curl up if thats what you mean. I haven't found a way to pause it half way like the google maps app does, but in theory if you implement the UIView animation delegate methods you might be able to pause it half way or something.

EDIT:

[UIView transitionFromView:overlayView toView:self.view duration:1 options:UIViewAnimationOptionTransitionCurlDown completion:nil];

is the curl down implementation of it.

Just so you are aware overlayView is UIView, not a UIViewController, not that it should matter but thats how I implemented it.

Rudiger
  • 6,749
  • 13
  • 51
  • 102
  • I've got a way to do that, to pause the animation. Check the FDCurlViewControl for the code, or the FDCatalog for a sample: https://github.com/FairfaxMobile – vfn Mar 24 '11 at 22:48