title: My Map Annotations in iOS 6 do not stay rotated when the user pans the map
body: <p>In the answer to a similar question the user said to do the following:</p>
  
  <p>The fix for this is to do the following in the viewForAnnotation method:</p>
  
  <pre><code>// iOS6 BUG WORKAROUND !!!!!!!
  if (is6orMore) {
       [annotationView setTransform:CGAffineTransformMakeRotation(.001)]; //any small positive rotation
  }
  </code></pre>
  
  <p>I have tried putting this code all over the place and my annotations still rotate when the map is panned.  Here is my code.</p>
  
  <p>I call this method anytime the map is rotated</p>
  
  <pre><code>-(void)rotateAnnotations {
  
      for (id&lt;MKAnnotation&gt; annotation in self.mapView.annotations)
      {
          MKAnnotationView* annotationView = [self.mapView viewForAnnotation:annotation];
  
          [annotationView setTransform:CGAffineTransformMakeRotation(- self.mapRotationRadians)];
          if ([annotation isKindOfClass:[FlagAnnotation class]]) {
              [annotationView setSelected:YES animated:NO];
          }
           [annotationView setNeedsDisplay];  //ios6
      }
  }
  </code></pre>
  
  <p>The original answer said to put the bug work around code in the viewForAnnotation method.  Here is that code.</p>
  
  <pre><code>- (MKAnnotationView *)mapView:(MKMapView *)theMapView viewForAnnotation:(id &lt;MKAnnotation&gt;)annotation
  {
      if ([annotation isKindOfClass:[MKUserLocation class]])
          return nil;
  
     if ([annotation isKindOfClass:[FlagAnnotation class]]) {
  
          // once flag is set allow for doubleTap zoom
          [self.mapView addGestureRecognizer:doubleTap];
  
          static NSString *AnnotationViewID = @"annotationViewID";
          MKAnnotationView *annotationView = (MKAnnotationView *)[mapView dequeueReusableAnnotationViewWithIdentifier:AnnotationViewID];
  
          if (!annotationView)
          {
              annotationView = [[MKAnnotationView alloc] initWithAnnotation:annotation reuseIdentifier:AnnotationViewID];
              annotationView.image = [UIImage imageNamed:@"FlagRed"];
              annotationView.draggable = YES;
              [self updateFlagCoordinate:(MKPlacemark *)annotationView.annotation];
              return annotationView;
  
          }
          else {
              [self updateFlagCoordinate:(MKPlacemark *)annotationView.annotation];
              annotationView.annotation = annotation;
          }
  
          // iOS6 BUG WORKAROUND !!!!!!!
          if (osVersion() &gt;= 6) {
              [annotationView setTransform:CGAffineTransformMakeRotation(.001)];
          }
  
          return annotationView;
      }
      return nil;
  }
  </code></pre>
  
  <p>I would appreciate your help.</p>
  
  <p>Thanks,
  Matt</p>