Authored by Justin R. Miller

fixes #171: no longer allow callouts on cluster annotations

... ... @@ -27,6 +27,7 @@
#import "RMMapLayer.h"
#import "RMPixel.h"
#import "RMAnnotation.h"
@implementation RMMapLayer
... ... @@ -34,7 +35,7 @@
@synthesize projectedLocation;
@synthesize draggingEnabled;
@synthesize userInfo;
@synthesize canShowCallout;
@synthesize canShowCallout=_canShowCallout;
@synthesize calloutOffset;
@synthesize leftCalloutAccessoryView;
@synthesize rightCalloutAccessoryView;
... ... @@ -70,6 +71,12 @@
[super dealloc];
}
- (void)setCanShowCallout:(BOOL)canShowCallout
{
if ( ! self.annotation.isClusterAnnotation)
_canShowCallout = canShowCallout;
}
- (void)setPosition:(CGPoint)position animated:(BOOL)animated
{
[self setPosition:position];
... ...
... ... @@ -1548,7 +1548,7 @@
[self deselectAnnotation:_currentAnnotation animated:( ! [hit isKindOfClass:[RMMarker class]])];
}
if ( ! [hit isKindOfClass:[CALayer class]])
if ( ! hit)
{
[self singleTapAtPoint:[recognizer locationInView:self]];
return;
... ...