react-native-maps 2.0.0-beta.5 → 2.0.0-beta.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/src/main/java/com/rnmaps/maps/MapCalloutManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapCircleManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapGradientPolyline.java +4 -4
- package/android/src/main/java/com/rnmaps/maps/MapGradientPolylineManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapHeatmapManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapLiteManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapLocalTile.java +4 -4
- package/android/src/main/java/com/rnmaps/maps/MapLocalTileManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapManager.java +1 -56
- package/android/src/main/java/com/rnmaps/maps/MapMarker.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapMarkerManager.java +9 -26
- package/android/src/main/java/com/rnmaps/maps/MapOverlayManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapPolygonManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapPolylineManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapTileProvider.java +4 -4
- package/android/src/main/java/com/rnmaps/maps/MapUrlTileManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapView.java +24 -131
- package/android/src/main/java/com/rnmaps/maps/MapViewModule.java +598 -0
- package/android/src/main/java/com/rnmaps/maps/MapWMSTile.java +6 -6
- package/android/src/main/java/com/rnmaps/maps/MapWMSTileManager.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapsPackage.java +1 -1
- package/android/src/main/java/com/rnmaps/maps/SizeReportingShadowNode.java +1 -1
- package/ios/{AirGoogleMaps/AIRDummyView.h → GoogleMaps/RNMDummyView.h} +3 -3
- package/ios/{AirGoogleMaps/AIRDummyView.m → GoogleMaps/RNMDummyView.m} +4 -4
- package/ios/{AirGoogleMaps/AIRGMSMarker.h → GoogleMaps/RNMGMSMarker.h} +6 -6
- package/ios/{AirGoogleMaps/AIRGMSMarker.m → GoogleMaps/RNMGMSMarker.m} +4 -4
- package/ios/{AirGoogleMaps/AIRGMSPolygon.h → GoogleMaps/RNMGMSPolygon.h} +4 -4
- package/ios/{AirGoogleMaps/AIRGMSPolygon.m → GoogleMaps/RNMGMSPolygon.m} +4 -4
- package/ios/{AirGoogleMaps/AIRGMSPolyline.h → GoogleMaps/RNMGMSPolyline.h} +4 -4
- package/ios/{AirGoogleMaps/AIRGMSPolyline.m → GoogleMaps/RNMGMSPolyline.m} +4 -4
- package/ios/{AirGoogleMaps/AIRGoogleMap.h → GoogleMaps/RNMGoogleMap.h} +5 -5
- package/ios/{AirGoogleMaps/AIRGoogleMap.m → GoogleMaps/RNMGoogleMap.m} +77 -77
- package/ios/{AirGoogleMaps/AIRGoogleMapCallout.h → GoogleMaps/RNMGoogleMapCallout.h} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapCallout.m → GoogleMaps/RNMGoogleMapCallout.m} +4 -4
- package/ios/{AirGoogleMaps/AIRGoogleMapCalloutManager.h → GoogleMaps/RNMGoogleMapCalloutManager.h} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapCalloutManager.m → GoogleMaps/RNMGoogleMapCalloutManager.m} +7 -7
- package/ios/{AirGoogleMaps/AIRGoogleMapCalloutSubview.h → GoogleMaps/RNMGoogleMapCalloutSubview.h} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapCalloutSubview.m → GoogleMaps/RNMGoogleMapCalloutSubview.m} +4 -4
- package/ios/{AirGoogleMaps/AIRGoogleMapCalloutSubviewManager.h → GoogleMaps/RNMGoogleMapCalloutSubviewManager.h} +3 -3
- package/ios/GoogleMaps/RNMGoogleMapCalloutSubviewManager.m +28 -0
- package/ios/{AirGoogleMaps/AIRGoogleMapCircle.h → GoogleMaps/RNMGoogleMapCircle.h} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapCircle.m → GoogleMaps/RNMGoogleMapCircle.m} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapCircleManager.h → GoogleMaps/RNMGoogleMapCircleManager.h} +2 -2
- package/ios/{AirGoogleMaps/AIRGoogleMapCircleManager.m → GoogleMaps/RNMGoogleMapCircleManager.m} +7 -7
- package/ios/{AirGoogleMaps/AIRGoogleMapHeatmap.h → GoogleMaps/RNMGoogleMapHeatmap.h} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapHeatmap.m → GoogleMaps/RNMGoogleMapHeatmap.m} +4 -4
- package/ios/GoogleMaps/RNMGoogleMapHeatmapManager.h +11 -0
- package/ios/{AirGoogleMaps/AIRGoogleMapHeatmapManager.m → GoogleMaps/RNMGoogleMapHeatmapManager.m} +9 -9
- package/ios/{AirGoogleMaps/AIRGoogleMapManager.h → GoogleMaps/RNMGoogleMapManager.h} +3 -3
- package/ios/GoogleMaps/RNMGoogleMapManager.m +274 -0
- package/ios/{AirGoogleMaps/AIRGoogleMapMarker.h → GoogleMaps/RNMGoogleMapMarker.h} +15 -15
- package/ios/{AirGoogleMaps/AIRGoogleMapMarker.m → GoogleMaps/RNMGoogleMapMarker.m} +22 -22
- package/ios/{AirGoogleMaps/AIRGoogleMapMarkerManager.h → GoogleMaps/RNMGoogleMapMarkerManager.h} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapMarkerManager.m → GoogleMaps/RNMGoogleMapMarkerManager.m} +20 -20
- package/ios/{AirGoogleMaps/AIRGoogleMapOverlay.h → GoogleMaps/RNMGoogleMapOverlay.h} +4 -4
- package/ios/{AirGoogleMaps/AIRGoogleMapOverlay.m → GoogleMaps/RNMGoogleMapOverlay.m} +4 -4
- package/ios/{AirGoogleMaps/AIRGoogleMapOverlayManager.h → GoogleMaps/RNMGoogleMapOverlayManager.h} +2 -2
- package/ios/{AirGoogleMaps/AIRGoogleMapOverlayManager.m → GoogleMaps/RNMGoogleMapOverlayManager.m} +6 -6
- package/ios/{AirGoogleMaps/AIRGoogleMapPolygon.h → GoogleMaps/RNMGoogleMapPolygon.h} +7 -7
- package/ios/{AirGoogleMaps/AIRGoogleMapPolygon.m → GoogleMaps/RNMGoogleMapPolygon.m} +7 -7
- package/ios/{AirGoogleMaps/AIRGoogleMapPolylineManager.h → GoogleMaps/RNMGoogleMapPolygonManager.h} +2 -2
- package/ios/{AirGoogleMaps/AIRGoogleMapPolygonManager.m → GoogleMaps/RNMGoogleMapPolygonManager.m} +10 -10
- package/ios/{AirGoogleMaps/AIRGoogleMapPolyline.h → GoogleMaps/RNMGoogleMapPolyline.h} +7 -7
- package/ios/{AirGoogleMaps/AIRGoogleMapPolyline.m → GoogleMaps/RNMGoogleMapPolyline.m} +9 -9
- package/ios/{AirGoogleMaps/AIRGoogleMapPolygonManager.h → GoogleMaps/RNMGoogleMapPolylineManager.h} +2 -2
- package/ios/{AirGoogleMaps/AIRGoogleMapPolylineManager.m → GoogleMaps/RNMGoogleMapPolylineManager.m} +9 -9
- package/ios/{AirGoogleMaps/AIRGoogleMapUrlTile.h → GoogleMaps/RNMGoogleMapUrlTile.h} +2 -2
- package/ios/{AirGoogleMaps/AIRGoogleMapUrlTile.m → GoogleMaps/RNMGoogleMapUrlTile.m} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapUrlTileManager.h → GoogleMaps/RNMGoogleMapUrlTileManager.h} +2 -2
- package/ios/{AirGoogleMaps/AIRGoogleMapURLTileManager.m → GoogleMaps/RNMGoogleMapUrlTileManager.m} +7 -7
- package/ios/GoogleMaps/RNMGoogleMapViewModule.h +5 -0
- package/ios/GoogleMaps/RNMGoogleMapViewModule.m +380 -0
- package/ios/{AirGoogleMaps/AIRGoogleMapWMSTile.h → GoogleMaps/RNMGoogleMapWMSTile.h} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapWMSTile.m → GoogleMaps/RNMGoogleMapWMSTile.m} +4 -4
- package/ios/{AirGoogleMaps/AIRGoogleMapWMSTileManager.h → GoogleMaps/RNMGoogleMapWMSTileManager.h} +3 -3
- package/ios/{AirGoogleMaps/AIRGoogleMapWMSTileManager.m → GoogleMaps/RNMGoogleMapWMSTileManager.m} +8 -8
- package/ios/{AirMaps → Maps}/Callout/SMCalloutView.h +4 -4
- package/ios/{AirMaps/RCTConvert+AirMap.h → Maps/RCTConvert+RNMMap.h} +1 -1
- package/ios/{AirMaps/RCTConvert+AirMap.m → Maps/RCTConvert+RNMMap.m} +8 -8
- package/ios/{AirMaps/AIRMap.h → Maps/RNMMap.h} +8 -8
- package/ios/{AirMaps/AIRMap.m → Maps/RNMMap.m} +56 -56
- package/ios/{AirMaps/AIRMapCallout.h → Maps/RNMMapCallout.h} +1 -1
- package/ios/{AirMaps/AIRMapCallout.m → Maps/RNMMapCallout.m} +2 -2
- package/ios/{AirMaps/AIRMapCircleManager.h → Maps/RNMMapCalloutManager.h} +2 -2
- package/ios/{AirMaps/AIRMapCalloutManager.m → Maps/RNMMapCalloutManager.m} +7 -7
- package/ios/{AirMaps/AIRMapCalloutSubview.h → Maps/RNMMapCalloutSubview.h} +3 -3
- package/ios/{AirMaps/AIRMapCalloutSubview.m → Maps/RNMMapCalloutSubview.m} +4 -4
- package/ios/Maps/RNMMapCalloutSubviewManager.h +14 -0
- package/ios/Maps/RNMMapCalloutSubviewManager.m +24 -0
- package/ios/{AirMaps/AIRMapCircle.h → Maps/RNMMapCircle.h} +5 -5
- package/ios/{AirMaps/AIRMapCircle.m → Maps/RNMMapCircle.m} +3 -3
- package/ios/{AirMaps/AIRMapCalloutManager.h → Maps/RNMMapCircleManager.h} +2 -2
- package/ios/{AirMaps/AIRMapCircleManager.m → Maps/RNMMapCircleManager.m} +7 -7
- package/ios/{AirMaps/AIRMapCoordinate.h → Maps/RNMMapCoordinate.h} +2 -2
- package/ios/{AirMaps/AIRMapCoordinate.m → Maps/RNMMapCoordinate.m} +3 -3
- package/ios/{AirMaps/AIRMapLocalTile.h → Maps/RNMMapLocalTile.h} +7 -7
- package/ios/{AirMaps/AIRMapLocalTile.m → Maps/RNMMapLocalTile.m} +6 -6
- package/ios/{AirMaps/AIRMapLocalTileManager.h → Maps/RNMMapLocalTileManager.h} +3 -3
- package/ios/{AirMaps/AIRMapLocalTileManager.m → Maps/RNMMapLocalTileManager.m} +9 -9
- package/ios/{AirMaps/AIRMapLocalTileOverlay.h → Maps/RNMMapLocalTileOverlay.h} +2 -2
- package/ios/{AirMaps/AIRMapLocalTileOverlay.m → Maps/RNMMapLocalTileOverlay.m} +5 -5
- package/ios/{AirMaps/AIRMapManager.h → Maps/RNMMapManager.h} +6 -6
- package/ios/Maps/RNMMapManager.m +857 -0
- package/ios/{AirMaps/AIRMapMarker.h → Maps/RNMMapMarker.h} +8 -8
- package/ios/{AirMaps/AIRMapMarker.m → Maps/RNMMapMarker.m} +13 -13
- package/ios/{AirMaps/AIRMapMarkerManager.h → Maps/RNMMapMarkerManager.h} +1 -1
- package/ios/{AirMaps/AIRMapMarkerManager.m → Maps/RNMMapMarkerManager.m} +14 -14
- package/ios/{AirMaps/AIRMapOverlay.h → Maps/RNMMapOverlay.h} +7 -7
- package/ios/{AirMaps/AIRMapOverlay.m → Maps/RNMMapOverlay.m} +4 -4
- package/ios/Maps/RNMMapOverlayManager.h +5 -0
- package/ios/{AirMaps/AIRMapOverlayManager.m → Maps/RNMMapOverlayManager.m} +6 -6
- package/ios/{AirMaps/AIRMapOverlayRenderer.h → Maps/RNMMapOverlayRenderer.h} +1 -1
- package/ios/{AirMaps/AIRMapOverlayRenderer.m → Maps/RNMMapOverlayRenderer.m} +5 -5
- package/ios/{AirMaps/AIRMapPolygon.h → Maps/RNMMapPolygon.h} +7 -7
- package/ios/{AirMaps/AIRMapPolygon.m → Maps/RNMMapPolygon.m} +4 -4
- package/ios/{AirMaps/AIRMapPolygonManager.h → Maps/RNMMapPolygonManager.h} +2 -2
- package/ios/{AirMaps/AIRMapPolygonManager.m → Maps/RNMMapPolygonManager.m} +10 -10
- package/ios/{AirMaps/AIRMapPolyline.h → Maps/RNMMapPolyline.h} +6 -6
- package/ios/{AirMaps/AIRMapPolyline.m → Maps/RNMMapPolyline.m} +11 -11
- package/ios/{AirMaps/AIRMapPolylineManager.h → Maps/RNMMapPolylineManager.h} +2 -2
- package/ios/{AirMaps/AIRMapPolylineManager.m → Maps/RNMMapPolylineManager.m} +9 -9
- package/ios/{AirMaps/AIRMapPolylineRenderer.h → Maps/RNMMapPolylineRenderer.h} +2 -2
- package/ios/{AirMaps/AIRMapPolylineRenderer.m → Maps/RNMMapPolylineRenderer.m} +10 -10
- package/ios/{AirMaps/AIRMapSnapshot.h → Maps/RNMMapSnapshot.h} +6 -6
- package/ios/{AirMaps/AIRMapUrlTile.h → Maps/RNMMapUrlTile.h} +18 -18
- package/ios/{AirMaps/AIRMapUrlTile.m → Maps/RNMMapUrlTile.m} +7 -7
- package/ios/{AirMaps/AIRMapUrlTileCachedOverlay.h → Maps/RNMMapUrlTileCachedOverlay.h} +3 -3
- package/ios/{AirMaps/AIRMapUrlTileCachedOverlay.m → Maps/RNMMapUrlTileCachedOverlay.m} +10 -10
- package/ios/{AirMaps/AIRMapUrlTileManager.h → Maps/RNMMapUrlTileManager.h} +3 -3
- package/ios/{AirMaps/AIRMapUrlTileManager.m → Maps/RNMMapUrlTileManager.m} +9 -9
- package/ios/Maps/RNMMapViewModule.h +5 -0
- package/ios/Maps/RNMMapViewModule.m +459 -0
- package/ios/{AirMaps/AIRMapWMSTile.h → Maps/RNMMapWMSTile.h} +11 -11
- package/ios/{AirMaps/AIRMapWMSTile.m → Maps/RNMMapWMSTile.m} +15 -15
- package/ios/{AirMaps/AIRMapWMSTileManager.h → Maps/RNMMapWMSTileManager.h} +3 -3
- package/ios/{AirMaps/AIRMapWMSTileManager.m → Maps/RNMMapWMSTileManager.m} +9 -9
- package/ios/RNMaps.xcodeproj/project.pbxproj +647 -0
- package/lib/MapCallout.js +2 -2
- package/lib/MapCalloutSubview.js +2 -2
- package/lib/MapCircle.js +2 -2
- package/lib/MapHeatmap.js +2 -2
- package/lib/MapLocalTile.js +2 -2
- package/lib/MapMarker.js +2 -2
- package/lib/MapOverlay.js +2 -2
- package/lib/MapPolygon.js +2 -2
- package/lib/MapPolyline.js +2 -2
- package/lib/MapUrlTile.js +2 -2
- package/lib/MapView.d.ts +7 -8
- package/lib/MapView.js +89 -97
- package/lib/MapView.types.d.ts +8 -2
- package/lib/MapViewNativeComponent.d.ts +2 -7
- package/lib/MapViewNativeComponent.js +0 -5
- package/lib/MapWMSTile.js +2 -2
- package/lib/NativeGoogleMapViewModule.d.ts +25 -0
- package/lib/NativeGoogleMapViewModule.js +4 -0
- package/lib/NativeMapViewModule.d.ts +29 -0
- package/lib/NativeMapViewModule.js +4 -0
- package/lib/decorateMapComponent.d.ts +1 -1
- package/lib/decorateMapComponent.js +3 -3
- package/package.json +1 -1
- package/react-native-google-maps.podspec +1 -1
- package/react-native-maps.podspec +1 -1
- package/android/src/main/java/com/rnmaps/maps/MapModule.java +0 -380
- package/ios/AirGoogleMaps/AIRGoogleMapCalloutSubviewManager.m +0 -28
- package/ios/AirGoogleMaps/AIRGoogleMapHeatmapManager.h +0 -11
- package/ios/AirGoogleMaps/AIRGoogleMapManager.m +0 -597
- package/ios/AirMaps/AIRMapCalloutSubviewManager.h +0 -14
- package/ios/AirMaps/AIRMapCalloutSubviewManager.m +0 -24
- package/ios/AirMaps/AIRMapManager.m +0 -1253
- package/ios/AirMaps/AIRMapOverlayManager.h +0 -5
- package/ios/AirMaps/AIRWeakMapReference.h +0 -24
- package/ios/AirMaps/AIRWeakMapReference.m +0 -23
- package/ios/AirMaps/AIRWeakTimerReference.h +0 -21
- package/ios/AirMaps/AIRWeakTimerReference.m +0 -42
- package/ios/AirMaps.xcodeproj/project.pbxproj +0 -587
- /package/ios/{AirGoogleMaps → GoogleMaps}/RCTConvert+GMSMapViewType.h +0 -0
- /package/ios/{AirGoogleMaps → GoogleMaps}/RCTConvert+GMSMapViewType.m +0 -0
- /package/ios/{AirMaps → Maps}/Callout/SMCalloutView.m +0 -0
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
3
|
-
//
|
|
2
|
+
// RNMGoogleMapMarker.m
|
|
3
|
+
// RNMaps
|
|
4
4
|
//
|
|
5
5
|
// Created by Gil Birman on 9/2/16.
|
|
6
6
|
//
|
|
7
7
|
|
|
8
8
|
#ifdef HAVE_GOOGLE_MAPS
|
|
9
9
|
|
|
10
|
-
#import "
|
|
10
|
+
#import "RNMGoogleMapMarker.h"
|
|
11
11
|
#import <GoogleMaps/GoogleMaps.h>
|
|
12
12
|
#import <React/RCTImageLoaderProtocol.h>
|
|
13
13
|
#import <React/RCTUtils.h>
|
|
14
|
-
#import "
|
|
15
|
-
#import "
|
|
16
|
-
#import "
|
|
14
|
+
#import "RNMGMSMarker.h"
|
|
15
|
+
#import "RNMGoogleMapCallout.h"
|
|
16
|
+
#import "RNMDummyView.h"
|
|
17
17
|
|
|
18
18
|
CGRect unionRect(CGRect a, CGRect b) {
|
|
19
19
|
return CGRectMake(
|
|
@@ -23,11 +23,11 @@ CGRect unionRect(CGRect a, CGRect b) {
|
|
|
23
23
|
MAX(a.size.height, b.size.height));
|
|
24
24
|
}
|
|
25
25
|
|
|
26
|
-
@interface
|
|
27
|
-
- (id)eventFromMarker:(
|
|
26
|
+
@interface RNMGoogleMapMarker ()
|
|
27
|
+
- (id)eventFromMarker:(RNMGMSMarker*)marker;
|
|
28
28
|
@end
|
|
29
29
|
|
|
30
|
-
@implementation
|
|
30
|
+
@implementation RNMGoogleMapMarker {
|
|
31
31
|
RCTImageLoaderCancellationBlock _reloadImageCancellationBlock;
|
|
32
32
|
__weak UIImageView *_iconImageView;
|
|
33
33
|
UIView *_iconView;
|
|
@@ -36,7 +36,7 @@ CGRect unionRect(CGRect a, CGRect b) {
|
|
|
36
36
|
- (instancetype)init
|
|
37
37
|
{
|
|
38
38
|
if ((self = [super init])) {
|
|
39
|
-
_realMarker = [[
|
|
39
|
+
_realMarker = [[RNMGMSMarker alloc] init];
|
|
40
40
|
_realMarker.fakeMarker = self;
|
|
41
41
|
_realMarker.tracksViewChanges = false;
|
|
42
42
|
_realMarker.tracksInfoWindowChanges = false;
|
|
@@ -60,7 +60,7 @@ CGRect unionRect(CGRect a, CGRect b) {
|
|
|
60
60
|
[_iconView setFrame:CGRectMake(0, 0, width, height)];
|
|
61
61
|
}
|
|
62
62
|
|
|
63
|
-
- (id)eventFromMarker:(
|
|
63
|
+
- (id)eventFromMarker:(RNMGMSMarker*)marker {
|
|
64
64
|
|
|
65
65
|
CLLocationCoordinate2D coordinate = marker.position;
|
|
66
66
|
CGPoint position = [self.realMarker.map.projection pointForCoordinate:coordinate];
|
|
@@ -87,19 +87,19 @@ CGRect unionRect(CGRect a, CGRect b) {
|
|
|
87
87
|
}
|
|
88
88
|
|
|
89
89
|
- (void)insertReactSubview:(id<RCTComponent>)subview atIndex:(NSInteger)atIndex {
|
|
90
|
-
if ([subview isKindOfClass:[
|
|
91
|
-
self.calloutView = (
|
|
90
|
+
if ([subview isKindOfClass:[RNMGoogleMapCallout class]]) {
|
|
91
|
+
self.calloutView = (RNMGoogleMapCallout *)subview;
|
|
92
92
|
} else { // a child view of the marker
|
|
93
93
|
[self iconViewInsertSubview:(UIView*)subview atIndex:atIndex+1];
|
|
94
94
|
}
|
|
95
|
-
|
|
95
|
+
RNMDummyView *dummySubview = [[RNMDummyView alloc] initWithView:(UIView *)subview];
|
|
96
96
|
[super insertReactSubview:(UIView*)dummySubview atIndex:atIndex];
|
|
97
97
|
}
|
|
98
98
|
|
|
99
99
|
- (void)removeReactSubview:(id<RCTComponent>)dummySubview {
|
|
100
|
-
UIView* subview = ((
|
|
100
|
+
UIView* subview = ((RNMDummyView*)dummySubview).view;
|
|
101
101
|
|
|
102
|
-
if ([subview isKindOfClass:[
|
|
102
|
+
if ([subview isKindOfClass:[RNMGoogleMapCallout class]]) {
|
|
103
103
|
self.calloutView = nil;
|
|
104
104
|
} else {
|
|
105
105
|
[(UIView*)subview removeFromSuperview];
|
|
@@ -149,7 +149,7 @@ CGRect unionRect(CGRect a, CGRect b) {
|
|
|
149
149
|
return nil;
|
|
150
150
|
}
|
|
151
151
|
|
|
152
|
-
- (void)didTapInfoWindowOfMarker:(
|
|
152
|
+
- (void)didTapInfoWindowOfMarker:(RNMGMSMarker *)marker point:(CGPoint)point frame:(CGRect)frame {
|
|
153
153
|
if (self.calloutView && self.calloutView.onPress) {
|
|
154
154
|
//todo: why not 'callout-press' ?
|
|
155
155
|
id event = @{
|
|
@@ -170,11 +170,11 @@ CGRect unionRect(CGRect a, CGRect b) {
|
|
|
170
170
|
}
|
|
171
171
|
}
|
|
172
172
|
|
|
173
|
-
- (void)didTapInfoWindowOfMarker:(
|
|
173
|
+
- (void)didTapInfoWindowOfMarker:(RNMGMSMarker *)marker {
|
|
174
174
|
[self didTapInfoWindowOfMarker:marker point:CGPointMake(-1, -1) frame:CGRectZero];
|
|
175
175
|
}
|
|
176
176
|
|
|
177
|
-
- (void)didTapInfoWindowOfMarker:(
|
|
177
|
+
- (void)didTapInfoWindowOfMarker:(RNMGMSMarker *)marker subview:(RNMGoogleMapCalloutSubview*)subview point:(CGPoint)point frame:(CGRect)frame {
|
|
178
178
|
if (subview && subview.onPress) {
|
|
179
179
|
//todo: why not 'callout-inside-press' ?
|
|
180
180
|
id event = @{
|
|
@@ -197,17 +197,17 @@ CGRect unionRect(CGRect a, CGRect b) {
|
|
|
197
197
|
}
|
|
198
198
|
}
|
|
199
199
|
|
|
200
|
-
- (void)didBeginDraggingMarker:(
|
|
200
|
+
- (void)didBeginDraggingMarker:(RNMGMSMarker *)marker {
|
|
201
201
|
if (!self.onDragStart) return;
|
|
202
202
|
self.onDragStart([self eventFromMarker:marker]);
|
|
203
203
|
}
|
|
204
204
|
|
|
205
|
-
- (void)didEndDraggingMarker:(
|
|
205
|
+
- (void)didEndDraggingMarker:(RNMGMSMarker *)marker {
|
|
206
206
|
if (!self.onDragEnd) return;
|
|
207
207
|
self.onDragEnd([self eventFromMarker:marker]);
|
|
208
208
|
}
|
|
209
209
|
|
|
210
|
-
- (void)didDragMarker:(
|
|
210
|
+
- (void)didDragMarker:(RNMGMSMarker *)marker {
|
|
211
211
|
if (!self.onDrag) return;
|
|
212
212
|
self.onDrag([self eventFromMarker:marker]);
|
|
213
213
|
}
|
package/ios/{AirGoogleMaps/AIRGoogleMapMarkerManager.h → GoogleMaps/RNMGoogleMapMarkerManager.h}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
3
|
-
//
|
|
2
|
+
// RNMGoogleMapMarkerManager.h
|
|
3
|
+
// RNMaps
|
|
4
4
|
//
|
|
5
5
|
// Created by Gil Birman on 9/2/16.
|
|
6
6
|
//
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
|
|
10
10
|
#import <React/RCTViewManager.h>
|
|
11
11
|
|
|
12
|
-
@interface
|
|
12
|
+
@interface RNMGoogleMapMarkerManager : RCTViewManager
|
|
13
13
|
|
|
14
14
|
@end
|
|
15
15
|
|
package/ios/{AirGoogleMaps/AIRGoogleMapMarkerManager.m → GoogleMaps/RNMGoogleMapMarkerManager.m}
RENAMED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
3
|
-
//
|
|
2
|
+
// RNMGoogleMapMarkerManager.m
|
|
3
|
+
// RNMaps
|
|
4
4
|
//
|
|
5
5
|
// Created by Gil Birman on 9/2/16.
|
|
6
6
|
//
|
|
7
7
|
|
|
8
8
|
#ifdef HAVE_GOOGLE_MAPS
|
|
9
9
|
|
|
10
|
-
#import "
|
|
11
|
-
#import "
|
|
10
|
+
#import "RNMGoogleMapMarkerManager.h"
|
|
11
|
+
#import "RNMGoogleMapMarker.h"
|
|
12
12
|
#import <MapKit/MapKit.h>
|
|
13
13
|
#import <React/RCTUIManager.h>
|
|
14
|
-
#import "RCTConvert+
|
|
14
|
+
#import "RCTConvert+RNMMap.h"
|
|
15
15
|
|
|
16
|
-
@implementation
|
|
16
|
+
@implementation RNMGoogleMapMarkerManager
|
|
17
17
|
|
|
18
|
-
RCT_EXPORT_MODULE()
|
|
18
|
+
RCT_EXPORT_MODULE(RNMGoogleMapMarker)
|
|
19
19
|
|
|
20
20
|
- (UIView *)view
|
|
21
21
|
{
|
|
22
|
-
|
|
22
|
+
RNMGoogleMapMarker *marker = [RNMGoogleMapMarker new];
|
|
23
23
|
// UITapGestureRecognizer *tapGestureRecognizer = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(_handleTap:)];
|
|
24
24
|
// // setting this to NO allows the parent MapView to continue receiving marker selection events
|
|
25
25
|
// tapGestureRecognizer.cancelsTouchesInView = NO;
|
|
@@ -57,10 +57,10 @@ RCT_EXPORT_METHOD(showCallout:(nonnull NSNumber *)reactTag)
|
|
|
57
57
|
{
|
|
58
58
|
[self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *uiManager, NSDictionary<NSNumber *, UIView *> *viewRegistry) {
|
|
59
59
|
id view = viewRegistry[reactTag];
|
|
60
|
-
if (![view isKindOfClass:[
|
|
61
|
-
RCTLogError(@"Invalid view returned from registry, expecting
|
|
60
|
+
if (![view isKindOfClass:[RNMGoogleMapMarker class]]) {
|
|
61
|
+
RCTLogError(@"Invalid view returned from registry, expecting RNMMap, got: %@", view);
|
|
62
62
|
} else {
|
|
63
|
-
[(
|
|
63
|
+
[(RNMGoogleMapMarker *) view showCalloutView];
|
|
64
64
|
}
|
|
65
65
|
}];
|
|
66
66
|
}
|
|
@@ -69,10 +69,10 @@ RCT_EXPORT_METHOD(hideCallout:(nonnull NSNumber *)reactTag)
|
|
|
69
69
|
{
|
|
70
70
|
[self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *uiManager, NSDictionary<NSNumber *, UIView *> *viewRegistry) {
|
|
71
71
|
id view = viewRegistry[reactTag];
|
|
72
|
-
if (![view isKindOfClass:[
|
|
73
|
-
RCTLogError(@"Invalid view returned from registry, expecting
|
|
72
|
+
if (![view isKindOfClass:[RNMGoogleMapMarker class]]) {
|
|
73
|
+
RCTLogError(@"Invalid view returned from registry, expecting RNMMap, got: %@", view);
|
|
74
74
|
} else {
|
|
75
|
-
[(
|
|
75
|
+
[(RNMGoogleMapMarker *) view hideCalloutView];
|
|
76
76
|
}
|
|
77
77
|
}];
|
|
78
78
|
}
|
|
@@ -81,10 +81,10 @@ RCT_EXPORT_METHOD(redrawCallout:(nonnull NSNumber *)reactTag)
|
|
|
81
81
|
{
|
|
82
82
|
[self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *uiManager, NSDictionary<NSNumber *, UIView *> *viewRegistry) {
|
|
83
83
|
id view = viewRegistry[reactTag];
|
|
84
|
-
if (![view isKindOfClass:[
|
|
85
|
-
RCTLogError(@"Invalid view returned from registry, expecting
|
|
84
|
+
if (![view isKindOfClass:[RNMGoogleMapMarker class]]) {
|
|
85
|
+
RCTLogError(@"Invalid view returned from registry, expecting RNMMap, got: %@", view);
|
|
86
86
|
} else {
|
|
87
|
-
|
|
87
|
+
RNMGoogleMapMarker* marker = (RNMGoogleMapMarker *) view;
|
|
88
88
|
|
|
89
89
|
[NSTimer scheduledTimerWithTimeInterval:0.0
|
|
90
90
|
target:[NSBlockOperation blockOperationWithBlock:^{
|
|
@@ -103,10 +103,10 @@ RCT_EXPORT_METHOD(redraw:(nonnull NSNumber *)reactTag)
|
|
|
103
103
|
{
|
|
104
104
|
[self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *uiManager, NSDictionary<NSNumber *, UIView *> *viewRegistry) {
|
|
105
105
|
id view = viewRegistry[reactTag];
|
|
106
|
-
if (![view isKindOfClass:[
|
|
107
|
-
RCTLogError(@"Invalid view returned from registry, expecting
|
|
106
|
+
if (![view isKindOfClass:[RNMGoogleMapMarker class]]) {
|
|
107
|
+
RCTLogError(@"Invalid view returned from registry, expecting RNMMap, got: %@", view);
|
|
108
108
|
} else {
|
|
109
|
-
[(
|
|
109
|
+
[(RNMGoogleMapMarker *) view redraw];
|
|
110
110
|
}
|
|
111
111
|
}];
|
|
112
112
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapOverlay.h
|
|
3
3
|
//
|
|
4
4
|
// Created by Taro Matsuzawa on 5/3/17.
|
|
5
5
|
//
|
|
@@ -9,10 +9,10 @@
|
|
|
9
9
|
#import <Foundation/Foundation.h>
|
|
10
10
|
#import <GoogleMaps/GoogleMaps.h>
|
|
11
11
|
#import <React/RCTBridge.h>
|
|
12
|
-
#import "
|
|
13
|
-
#import "
|
|
12
|
+
#import "RNMMapCoordinate.h"
|
|
13
|
+
#import "RNMGoogleMap.h"
|
|
14
14
|
|
|
15
|
-
@interface
|
|
15
|
+
@interface RNMGoogleMapOverlay : UIView
|
|
16
16
|
|
|
17
17
|
@property (nonatomic, strong) GMSGroundOverlay *overlay;
|
|
18
18
|
@property (nonatomic, copy) NSString *imageSrc;
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapOverlay.m
|
|
3
3
|
// Created by Nick Italiano on 3/5/17.
|
|
4
4
|
//
|
|
5
5
|
|
|
6
6
|
#ifdef HAVE_GOOGLE_MAPS
|
|
7
7
|
|
|
8
|
-
#import "
|
|
8
|
+
#import "RNMGoogleMapOverlay.h"
|
|
9
9
|
|
|
10
10
|
#import <React/RCTEventDispatcher.h>
|
|
11
11
|
#import <React/RCTImageLoaderProtocol.h>
|
|
12
12
|
#import <React/RCTUtils.h>
|
|
13
13
|
#import <React/UIView+React.h>
|
|
14
14
|
|
|
15
|
-
@interface
|
|
15
|
+
@interface RNMGoogleMapOverlay()
|
|
16
16
|
@property (nonatomic, strong, readwrite) UIImage *overlayImage;
|
|
17
17
|
@property (nonatomic, readwrite) GMSCoordinateBounds *overlayBounds;
|
|
18
18
|
@property (nonatomic) CLLocationDirection bearing;
|
|
19
19
|
@end
|
|
20
20
|
|
|
21
|
-
@implementation
|
|
21
|
+
@implementation RNMGoogleMapOverlay {
|
|
22
22
|
RCTImageLoaderCancellationBlock _reloadImageCancellationBlock;
|
|
23
23
|
CLLocationCoordinate2D _southWest;
|
|
24
24
|
CLLocationCoordinate2D _northEast;
|
package/ios/{AirGoogleMaps/AIRGoogleMapOverlayManager.h → GoogleMaps/RNMGoogleMapOverlayManager.h}
RENAMED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapOverlayManager.h
|
|
3
3
|
// Created by Taro Matsuzawa on 3/5/17.
|
|
4
4
|
//
|
|
5
5
|
|
|
6
6
|
#import <Foundation/Foundation.h>
|
|
7
7
|
#import <React/RCTViewManager.h>
|
|
8
8
|
|
|
9
|
-
@interface
|
|
9
|
+
@interface RNMGoogleMapOverlayManager : RCTViewManager
|
|
10
10
|
@end
|
package/ios/{AirGoogleMaps/AIRGoogleMapOverlayManager.m → GoogleMaps/RNMGoogleMapOverlayManager.m}
RENAMED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
#import "
|
|
2
|
-
#import "
|
|
1
|
+
#import "RNMGoogleMapOverlayManager.h"
|
|
2
|
+
#import "RNMGoogleMapOverlay.h"
|
|
3
3
|
|
|
4
|
-
@interface
|
|
4
|
+
@interface RNMGoogleMapOverlayManager()
|
|
5
5
|
|
|
6
6
|
@end
|
|
7
7
|
|
|
8
|
-
@implementation
|
|
8
|
+
@implementation RNMGoogleMapOverlayManager
|
|
9
9
|
|
|
10
|
-
RCT_EXPORT_MODULE()
|
|
10
|
+
RCT_EXPORT_MODULE(RNMGoogleMapOverlay)
|
|
11
11
|
|
|
12
12
|
- (UIView *)view
|
|
13
13
|
{
|
|
14
|
-
|
|
14
|
+
RNMGoogleMapOverlay *overlay = [RNMGoogleMapOverlay new];
|
|
15
15
|
overlay.bridge = self.bridge;
|
|
16
16
|
return overlay;
|
|
17
17
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapPolygon.h
|
|
3
3
|
//
|
|
4
4
|
// Created by Nick Italiano on 10/22/16.
|
|
5
5
|
//
|
|
@@ -8,16 +8,16 @@
|
|
|
8
8
|
|
|
9
9
|
#import <GoogleMaps/GoogleMaps.h>
|
|
10
10
|
#import <React/RCTBridge.h>
|
|
11
|
-
#import "
|
|
12
|
-
#import "
|
|
11
|
+
#import "RNMGMSPolygon.h"
|
|
12
|
+
#import "RNMMapCoordinate.h"
|
|
13
13
|
|
|
14
|
-
@interface
|
|
14
|
+
@interface RNMGoogleMapPolygon : UIView
|
|
15
15
|
|
|
16
16
|
@property (nonatomic, weak) RCTBridge *bridge;
|
|
17
17
|
@property (nonatomic, strong) NSString *identifier;
|
|
18
|
-
@property (nonatomic, strong)
|
|
19
|
-
@property (nonatomic, strong) NSArray<
|
|
20
|
-
@property (nonatomic, strong) NSArray<NSArray<
|
|
18
|
+
@property (nonatomic, strong) RNMGMSPolygon *polygon;
|
|
19
|
+
@property (nonatomic, strong) NSArray<RNMMapCoordinate *> *coordinates;
|
|
20
|
+
@property (nonatomic, strong) NSArray<NSArray<RNMMapCoordinate *> *> *holes;
|
|
21
21
|
@property (nonatomic, copy) RCTBubblingEventBlock onPress;
|
|
22
22
|
|
|
23
23
|
@property (nonatomic, strong) UIColor *fillColor;
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapPolygon.m
|
|
3
3
|
//
|
|
4
4
|
// Created by Nick Italiano on 10/22/16.
|
|
5
5
|
//
|
|
6
6
|
|
|
7
7
|
#ifdef HAVE_GOOGLE_MAPS
|
|
8
8
|
|
|
9
|
-
#import "
|
|
10
|
-
#import "
|
|
9
|
+
#import "RNMGoogleMapPolygon.h"
|
|
10
|
+
#import "RNMGMSPolygon.h"
|
|
11
11
|
#import <GoogleMaps/GoogleMaps.h>
|
|
12
12
|
|
|
13
|
-
@implementation
|
|
13
|
+
@implementation RNMGoogleMapPolygon
|
|
14
14
|
{
|
|
15
15
|
BOOL _didMoveToWindow;
|
|
16
16
|
}
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
{
|
|
20
20
|
if (self = [super init]) {
|
|
21
21
|
_didMoveToWindow = false;
|
|
22
|
-
_polygon = [[
|
|
22
|
+
_polygon = [[RNMGMSPolygon alloc] init];
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
return self;
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
- (void)setCoordinates:(NSArray<
|
|
43
|
+
- (void)setCoordinates:(NSArray<RNMMapCoordinate *> *)coordinates
|
|
44
44
|
{
|
|
45
45
|
_coordinates = coordinates;
|
|
46
46
|
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
_polygon.path = path;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
-
- (void)setHoles:(NSArray<NSArray<
|
|
56
|
+
- (void)setHoles:(NSArray<NSArray<RNMMapCoordinate *> *> *)holes
|
|
57
57
|
{
|
|
58
58
|
_holes = holes;
|
|
59
59
|
|
package/ios/{AirGoogleMaps/AIRGoogleMapPolylineManager.h → GoogleMaps/RNMGoogleMapPolygonManager.h}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapPolylgoneManager.h
|
|
3
3
|
//
|
|
4
4
|
// Created by Nick Italiano on 10/22/16.
|
|
5
5
|
//
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
#import <React/RCTViewManager.h>
|
|
10
10
|
|
|
11
|
-
@interface
|
|
11
|
+
@interface RNMGoogleMapPolygonManager : RCTViewManager
|
|
12
12
|
|
|
13
13
|
@end
|
|
14
14
|
|
package/ios/{AirGoogleMaps/AIRGoogleMapPolygonManager.m → GoogleMaps/RNMGoogleMapPolygonManager.m}
RENAMED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapPolylgoneManager.m
|
|
3
3
|
//
|
|
4
4
|
// Created by Nick Italiano on 10/22/16.
|
|
5
5
|
//
|
|
6
6
|
|
|
7
7
|
#ifdef HAVE_GOOGLE_MAPS
|
|
8
|
-
#import "
|
|
8
|
+
#import "RNMGoogleMapPolygonManager.h"
|
|
9
9
|
|
|
10
10
|
#import <React/RCTBridge.h>
|
|
11
11
|
#import <React/RCTConvert.h>
|
|
@@ -13,26 +13,26 @@
|
|
|
13
13
|
#import <React/RCTEventDispatcher.h>
|
|
14
14
|
#import <React/RCTViewManager.h>
|
|
15
15
|
#import <React/UIView+React.h>
|
|
16
|
-
#import "RCTConvert+
|
|
17
|
-
#import "
|
|
16
|
+
#import "RCTConvert+RNMMap.h"
|
|
17
|
+
#import "RNMGoogleMapPolygon.h"
|
|
18
18
|
|
|
19
|
-
@interface
|
|
19
|
+
@interface RNMGoogleMapPolygonManager()
|
|
20
20
|
|
|
21
21
|
@end
|
|
22
22
|
|
|
23
|
-
@implementation
|
|
23
|
+
@implementation RNMGoogleMapPolygonManager
|
|
24
24
|
|
|
25
|
-
RCT_EXPORT_MODULE()
|
|
25
|
+
RCT_EXPORT_MODULE(RNMGoogleMapPolygon)
|
|
26
26
|
|
|
27
27
|
- (UIView *)view
|
|
28
28
|
{
|
|
29
|
-
|
|
29
|
+
RNMGoogleMapPolygon *polygon = [RNMGoogleMapPolygon new];
|
|
30
30
|
polygon.bridge = self.bridge;
|
|
31
31
|
return polygon;
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
-
RCT_EXPORT_VIEW_PROPERTY(coordinates,
|
|
35
|
-
RCT_EXPORT_VIEW_PROPERTY(holes,
|
|
34
|
+
RCT_EXPORT_VIEW_PROPERTY(coordinates, RNMMapCoordinateArray)
|
|
35
|
+
RCT_EXPORT_VIEW_PROPERTY(holes, RNMMapCoordinateArrayArray)
|
|
36
36
|
RCT_EXPORT_VIEW_PROPERTY(fillColor, UIColor)
|
|
37
37
|
RCT_EXPORT_VIEW_PROPERTY(strokeWidth, double)
|
|
38
38
|
RCT_EXPORT_VIEW_PROPERTY(strokeColor, UIColor)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapPolyline.h
|
|
3
3
|
//
|
|
4
4
|
// Created by Nick Italiano on 10/22/16.
|
|
5
5
|
//
|
|
@@ -8,16 +8,16 @@
|
|
|
8
8
|
#import <UIKit/UIKit.h>
|
|
9
9
|
#import <GoogleMaps/GoogleMaps.h>
|
|
10
10
|
#import <React/RCTBridge.h>
|
|
11
|
-
#import "
|
|
12
|
-
#import "
|
|
13
|
-
#import "
|
|
11
|
+
#import "RNMGMSPolyline.h"
|
|
12
|
+
#import "RNMMapCoordinate.h"
|
|
13
|
+
#import "RNMGoogleMapMarker.h"
|
|
14
14
|
|
|
15
|
-
@interface
|
|
15
|
+
@interface RNMGoogleMapPolyline : UIView
|
|
16
16
|
|
|
17
17
|
@property (nonatomic, weak) RCTBridge *bridge;
|
|
18
18
|
@property (nonatomic, strong) NSString *identifier;
|
|
19
|
-
@property (nonatomic, strong)
|
|
20
|
-
@property (nonatomic, strong) NSArray<
|
|
19
|
+
@property (nonatomic, strong) RNMGMSPolyline *polyline;
|
|
20
|
+
@property (nonatomic, strong) NSArray<RNMMapCoordinate *> *coordinates;
|
|
21
21
|
@property (nonatomic, copy) RCTBubblingEventBlock onPress;
|
|
22
22
|
|
|
23
23
|
@property (nonatomic, strong) UIColor *strokeColor;
|
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapPolyline.m
|
|
3
3
|
//
|
|
4
4
|
// Created by Nick Italiano on 10/22/16.
|
|
5
5
|
//
|
|
6
6
|
|
|
7
7
|
#ifdef HAVE_GOOGLE_MAPS
|
|
8
8
|
#import <UIKit/UIKit.h>
|
|
9
|
-
#import "
|
|
10
|
-
#import "
|
|
11
|
-
#import "
|
|
12
|
-
#import "
|
|
13
|
-
#import "
|
|
9
|
+
#import "RNMGoogleMapPolyline.h"
|
|
10
|
+
#import "RNMGMSPolyline.h"
|
|
11
|
+
#import "RNMMapCoordinate.h"
|
|
12
|
+
#import "RNMGoogleMapMarker.h"
|
|
13
|
+
#import "RNMGoogleMapMarkerManager.h"
|
|
14
14
|
#import <GoogleMaps/GoogleMaps.h>
|
|
15
15
|
#import <React/RCTUtils.h>
|
|
16
16
|
|
|
17
|
-
@implementation
|
|
17
|
+
@implementation RNMGoogleMapPolyline
|
|
18
18
|
|
|
19
19
|
- (instancetype)init
|
|
20
20
|
{
|
|
21
21
|
if (self = [super init]) {
|
|
22
|
-
_polyline = [[
|
|
22
|
+
_polyline = [[RNMGMSPolyline alloc] init];
|
|
23
23
|
}
|
|
24
24
|
return self;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
|
-
-(void)setCoordinates:(NSArray<
|
|
27
|
+
-(void)setCoordinates:(NSArray<RNMMapCoordinate *> *)coordinates
|
|
28
28
|
{
|
|
29
29
|
_coordinates = coordinates;
|
|
30
30
|
|
package/ios/{AirGoogleMaps/AIRGoogleMapPolygonManager.h → GoogleMaps/RNMGoogleMapPolylineManager.h}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapPolylineManager.h
|
|
3
3
|
//
|
|
4
4
|
// Created by Nick Italiano on 10/22/16.
|
|
5
5
|
//
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
#import <React/RCTViewManager.h>
|
|
10
10
|
|
|
11
|
-
@interface
|
|
11
|
+
@interface RNMGoogleMapPolylineManager : RCTViewManager
|
|
12
12
|
|
|
13
13
|
@end
|
|
14
14
|
|
package/ios/{AirGoogleMaps/AIRGoogleMapPolylineManager.m → GoogleMaps/RNMGoogleMapPolylineManager.m}
RENAMED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapPolylineManager.m
|
|
3
3
|
//
|
|
4
4
|
// Created by Nick Italiano on 10/22/16.
|
|
5
5
|
//
|
|
6
6
|
|
|
7
7
|
#ifdef HAVE_GOOGLE_MAPS
|
|
8
8
|
|
|
9
|
-
#import "
|
|
9
|
+
#import "RNMGoogleMapPolylineManager.h"
|
|
10
10
|
|
|
11
11
|
#import <React/RCTBridge.h>
|
|
12
12
|
#import <React/RCTConvert.h>
|
|
@@ -14,25 +14,25 @@
|
|
|
14
14
|
#import <React/RCTEventDispatcher.h>
|
|
15
15
|
#import <React/RCTViewManager.h>
|
|
16
16
|
#import <React/UIView+React.h>
|
|
17
|
-
#import "RCTConvert+
|
|
18
|
-
#import "
|
|
17
|
+
#import "RCTConvert+RNMMap.h"
|
|
18
|
+
#import "RNMGoogleMapPolyline.h"
|
|
19
19
|
|
|
20
|
-
@interface
|
|
20
|
+
@interface RNMGoogleMapPolylineManager()
|
|
21
21
|
|
|
22
22
|
@end
|
|
23
23
|
|
|
24
|
-
@implementation
|
|
24
|
+
@implementation RNMGoogleMapPolylineManager
|
|
25
25
|
|
|
26
|
-
RCT_EXPORT_MODULE()
|
|
26
|
+
RCT_EXPORT_MODULE(RNMGoogleMapPolyline)
|
|
27
27
|
|
|
28
28
|
- (UIView *)view
|
|
29
29
|
{
|
|
30
|
-
|
|
30
|
+
RNMGoogleMapPolyline *polyline = [RNMGoogleMapPolyline new];
|
|
31
31
|
polyline.bridge = self.bridge;
|
|
32
32
|
return polyline;
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
-
RCT_EXPORT_VIEW_PROPERTY(coordinates,
|
|
35
|
+
RCT_EXPORT_VIEW_PROPERTY(coordinates, RNMMapCoordinateArray)
|
|
36
36
|
RCT_EXPORT_VIEW_PROPERTY(fillColor, UIColor)
|
|
37
37
|
RCT_EXPORT_VIEW_PROPERTY(strokeColor, UIColor)
|
|
38
38
|
RCT_EXPORT_VIEW_PROPERTY(strokeColors, UIColorArray)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapURLTile.h
|
|
3
3
|
// Created by Nick Italiano on 11/5/16.
|
|
4
4
|
//
|
|
5
5
|
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
#import <Foundation/Foundation.h>
|
|
9
9
|
#import <GoogleMaps/GoogleMaps.h>
|
|
10
10
|
|
|
11
|
-
@interface
|
|
11
|
+
@interface RNMGoogleMapUrlTile : UIView
|
|
12
12
|
|
|
13
13
|
@property (nonatomic, strong) GMSURLTileLayer *tileLayer;
|
|
14
14
|
@property (nonatomic, assign) NSString *urlTemplate;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapURLTile.m
|
|
3
3
|
// Created by Nick Italiano on 11/5/16.
|
|
4
4
|
//
|
|
5
5
|
|
|
6
6
|
#ifdef HAVE_GOOGLE_MAPS
|
|
7
7
|
|
|
8
|
-
#import "
|
|
8
|
+
#import "RNMGoogleMapUrlTile.h"
|
|
9
9
|
|
|
10
|
-
@implementation
|
|
10
|
+
@implementation RNMGoogleMapUrlTile
|
|
11
11
|
|
|
12
12
|
- (void)setZIndex:(int)zIndex
|
|
13
13
|
{
|
package/ios/{AirGoogleMaps/AIRGoogleMapUrlTileManager.h → GoogleMaps/RNMGoogleMapUrlTileManager.h}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//
|
|
2
|
-
//
|
|
2
|
+
// RNMGoogleMapURLTileManager.h
|
|
3
3
|
// Created by Nick Italiano on 11/5/16.
|
|
4
4
|
//
|
|
5
5
|
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
#import <Foundation/Foundation.h>
|
|
9
9
|
#import <React/RCTViewManager.h>
|
|
10
10
|
|
|
11
|
-
@interface
|
|
11
|
+
@interface RNMGoogleMapUrlTileManager : RCTViewManager
|
|
12
12
|
@end
|
|
13
13
|
|
|
14
14
|
#endif
|