Authored by Denis Zamataev

Merge remote-tracking branch 'origin/feature/calloutContentView' into release

Conflicts resolved:
	MapView/Map/RMGreatCircleAnnotation.h
	Mapbox.podspec
... ... @@ -99,6 +99,13 @@
* If the view you specify is also a descendant of the UIControl class, you can use the map view’s delegate to receive notifications when your control is tapped. If it does not descend from UIControl, your view is responsible for handling any touch events within its bounds. */
@property (nonatomic, strong) UIView *rightCalloutAccessoryView;
/**
* Custom "content" view that can be any width/height.
*
* If this is set, title/subtitle/titleView/subtitleView are all ignored.
*/
@property (nonatomic, strong) UIView *calloutContentView;
/** Set the screen position of the layer.
* @param position The desired screen position.
* @param animated If set to `YES`, any position change is animated. */
... ...
... ... @@ -1923,6 +1923,13 @@
_currentCallout.rightAccessoryView = anAnnotation.layer.rightCalloutAccessoryView;
}
if (anAnnotation.layer.calloutContentView) {
if ([anAnnotation.layer.calloutContentView isKindOfClass:[UIControl class]])
[anAnnotation.layer.calloutContentView addGestureRecognizer:[[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(tapOnCalloutAccessoryWithGestureRecognizer:)]];
_currentCallout.contentView = anAnnotation.layer.calloutContentView;
}
_currentCallout.delegate = self;
... ...
Pod::Spec.new do |m|
m.name = 'Mapbox'
m.version = '1.1.0'
m.summary = 'Open source alternative to MapKit.'
m.description = 'Open source alternative to MapKit supporting custom tile sources, offline use, and complete cache control.'
m.homepage = 'http://mapbox.com/mobile'
m.license = 'BSD'
m.author = { 'Mapbox' => 'mobile@mapbox.com' }
m.screenshot = 'https://raw.github.com/mapbox/mapbox-ios-sdk/packaging/screenshot.png'
m.source = { :git => 'https://github.com/mapbox/mapbox-ios-sdk.git', :branch => 'develop' }
m.platform = :ios
m.ios.deployment_target = '5.0'
m.source_files = 'Proj4/*.h', 'MapView/Map/*.{h,c,m}'
m.requires_arc = true
m.prefix_header_file = 'MapView/MapView_Prefix.pch'
m.pre_install do |pod, target_definition|
Dir.chdir(pod.root) do
command = "xcodebuild -project MapView/MapView.xcodeproj -target Resources CONFIGURATION_BUILD_DIR=../Resources 2>&1 > /dev/null"
unless system(command)
raise ::Pod::Informative, "Failed to generate Mapbox resources bundle"
end
end
end
m.resource = 'Resources/Mapbox.bundle'
m.documentation_url = 'https://www.mapbox.com/mapbox-ios-sdk'
m.frameworks = 'CoreGraphics', 'CoreLocation', 'Foundation', 'QuartzCore', 'UIKit'
m.libraries = 'Proj4', 'sqlite3', 'z'
m.xcconfig = { 'OTHER_LDFLAGS' => '-ObjC', 'LIBRARY_SEARCH_PATHS' => '"${PODS_ROOT}/Mapbox/Proj4"' }
m.preserve_paths = 'MapView/MapView.xcodeproj', 'MapView/Map/Resources'
m.vendored_libraries = 'Proj4/libProj4.a'
m.dependency 'FMDB', '2.0'
m.dependency 'GRMustache', '6.8.3'
m.dependency 'SMCalloutView', '2.0'
end
... ...