From 88b7fa00822412890ace6164c8b45bcc97f0cecd Mon Sep 17 00:00:00 2001 From: sjchristi Date: Thu, 9 May 2024 07:10:07 -0700 Subject: [PATCH] Maplibre native 6.4 (#370) * fix product name * renaming folders rctmgl -> rctmln * renaming android root rctmgl -> rctmln * renaming files * rctmgl -> rctmln * mgl -> mln * more renaming * android fixes * linter fixes * updating changelog and package with new version * fix xcode 15.2 issue * renaming mapbox folder to maplibre * rename com.mapbox to com.maplibre --- .gitignore | 3 +- .sonarcloud.properties | 2 +- CHANGELOG.md | 3 + __tests__/components/BackgroundLayer.test.js | 4 +- __tests__/components/Callout.test.js | 6 +- __tests__/components/CircleLayer.test.js | 4 +- __tests__/components/HeatmapLayer.test.js | 4 +- __tests__/components/Light.test.js | 4 +- .../modules/location/locationManager.test.js | 4 +- __tests__/modules/offline/OfflinePack.test.js | 6 +- .../modules/offline/offlineManager.test.js | 10 +- .../modules/snapshot/SnapshotOptions.test.js | 6 +- .../java/com/mapbox/rctmgl/RCTMGLPackage.java | 99 --- .../annotation/RCTMGLCalloutManager.java | 22 - .../styles/layers/RCTMGLBackgroundLayer.java | 27 - .../styles/layers/RCTMGLRasterLayer.java | 27 - .../rctmgl/src/main/res/values/strings.xml | 3 - android/{rctmgl => rctmln}/.gitignore | 0 android/{rctmgl => rctmln}/.npmignore | 0 .../org.eclipse.buildship.core.prefs | 0 android/{rctmgl => rctmln}/build.gradle | 0 android/{rctmgl => rctmln}/proguard-rules.pro | 0 .../src/main/AndroidManifest.xml | 2 +- .../com/maplibre/rctmln/RCTMLNPackage.java | 99 +++ .../rctmln}/components/AbstractEvent.java | 2 +- .../components/AbstractEventEmitter.java | 4 +- .../components/AbstractMapFeature.java | 8 +- .../components/annotation/MarkerView.java | 2 +- .../annotation/MarkerViewManager.java | 2 +- .../components/annotation/RCTMLNCallout.java} | 6 +- .../annotation/RCTMLNCalloutManager.java | 22 + .../annotation/RCTMLNMarkerView.java} | 26 +- .../annotation/RCTMLNMarkerViewManager.java} | 20 +- .../annotation/RCTMLNPointAnnotation.java} | 36 +- .../RCTMLNPointAnnotationManager.java} | 28 +- .../rctmln}/components/camera/CameraStop.java | 12 +- .../components/camera/CameraUpdateItem.java | 4 +- .../components/camera/CameraUpdateQueue.java | 6 +- .../components/camera/RCTMLNCamera.java} | 48 +- .../camera/RCTMLNCameraManager.java} | 36 +- .../camera/constants/CameraMode.java | 2 +- .../components/images/RCTMLNImages.java} | 30 +- .../images/RCTMLNImagesManager.java} | 34 +- .../location/LocationComponentManager.java | 14 +- .../location/RCTMLNNativeUserLocation.java} | 16 +- .../RCTMLNNativeUserLocationManager.java} | 12 +- .../components/mapview/LayerSourceInfo.java | 2 +- .../mapview/RCTMLNAndroidTextureMapView.java} | 8 +- .../RCTMLNAndroidTextureMapViewManager.java} | 14 +- .../components/mapview/RCTMLNMapView.java} | 132 +-- .../mapview/RCTMLNMapViewManager.java} | 80 +- .../mapview/helpers/CameraChangeTracker.java | 2 +- .../components/styles/RCTMLNStyle.java} | 20 +- .../styles/RCTMLNStyleFactory.java} | 814 +++++++++--------- .../styles/RCTMLNStyleFunctionParser.java} | 12 +- .../components/styles/RCTMLNStyleValue.java} | 14 +- .../components/styles/layers/RCTLayer.java | 18 +- .../styles/layers/RCTMLNBackgroundLayer.java | 27 + .../layers/RCTMLNBackgroundLayerManager.java} | 26 +- .../styles/layers/RCTMLNCircleLayer.java} | 16 +- .../layers/RCTMLNCircleLayerManager.java} | 30 +- .../layers/RCTMLNFillExtrusionLayer.java} | 16 +- .../RCTMLNFillExtrusionLayerManager.java} | 32 +- .../styles/layers/RCTMLNFillLayer.java} | 16 +- .../layers/RCTMLNFillLayerManager.java} | 32 +- .../styles/layers/RCTMLNHeatmapLayer.java} | 16 +- .../layers/RCTMLNHeatmapLayerManager.java} | 30 +- .../styles/layers/RCTMLNLineLayer.java} | 16 +- .../layers/RCTMLNLineLayerManager.java} | 34 +- .../styles/layers/RCTMLNRasterLayer.java | 27 + .../layers/RCTMLNRasterLayerManager.java} | 26 +- .../styles/layers/RCTMLNSymbolLayer.java} | 16 +- .../layers/RCTMLNSymbolLayerManager.java} | 30 +- .../components/styles/light/RCTMLNLight.java} | 20 +- .../styles/light/RCTMLNLightManager.java} | 12 +- .../styles/sources/RCTMLNImageSource.java} | 8 +- .../sources/RCTMLNImageSourceManager.java} | 28 +- .../styles/sources/RCTMLNRasterSource.java} | 6 +- .../sources/RCTMLNRasterSourceManager.java} | 14 +- .../styles/sources/RCTMLNShapeSource.java} | 26 +- .../sources/RCTMLNShapeSourceManager.java} | 68 +- .../styles/sources/RCTMLNTileSource.java} | 6 +- .../sources/RCTMLNTileSourceManager.java} | 8 +- .../styles/sources/RCTMLNVectorSource.java} | 12 +- .../sources/RCTMLNVectorSourceManager.java} | 24 +- .../components/styles/sources/RCTSource.java | 14 +- .../rctmln}/events/AbstractEvent.java | 2 +- .../rctmln}/events/AndroidCallbackEvent.java | 4 +- .../maplibre/rctmln}/events/EventEmitter.java | 2 +- .../rctmln}/events/FeatureClickEvent.java | 12 +- .../com/maplibre/rctmln}/events/IEvent.java | 2 +- .../rctmln}/events/ImageMissingEvent.java | 6 +- .../rctmln}/events/LocationEvent.java | 12 +- .../rctmln}/events/MapChangeEvent.java | 6 +- .../rctmln}/events/MapClickEvent.java | 8 +- .../events/MapUserTrackingModeEvent.java | 8 +- .../maplibre/rctmln}/events/OfflineEvent.java | 2 +- .../events/PointAnnotationClickEvent.java | 16 +- .../events/PointAnnotationDragEvent.java | 16 +- .../rctmln}/events/constants/EventKeys.java | 2 +- .../rctmln}/events/constants/EventTypes.java | 2 +- .../http/CustomHeadersInterceptor.java | 2 +- .../rctmln}/location/LocationManager.java | 2 +- .../rctmln}/location/UserLocation.java | 2 +- .../UserLocationVerticalAlignment.java | 2 +- .../rctmln}/location/UserTrackingMode.java | 2 +- .../rctmln}/location/UserTrackingState.java | 2 +- .../rctmln/modules/RCTMLNLocationModule.java} | 16 +- .../rctmln/modules/RCTMLNLogging.java} | 10 +- .../rctmln/modules/RCTMLNModule.java} | 44 +- .../rctmln/modules/RCTMLNOfflineModule.java} | 20 +- .../rctmln/modules/RCTMLNSnapshotModule.java} | 14 +- .../maplibre/rctmln}/utils/BitmapUtils.java | 2 +- .../rctmln}/utils/ClusterPropertyEntry.java | 2 +- .../maplibre/rctmln}/utils/ConvertUtils.java | 2 +- .../rctmln}/utils/DownloadMapImageTask.java | 2 +- .../rctmln}/utils/ExpressionParser.java | 2 +- .../maplibre/rctmln}/utils/GeoJSONUtils.java | 2 +- .../maplibre/rctmln}/utils/GeoViewport.java | 2 +- .../maplibre/rctmln}/utils/ImageEntry.java | 2 +- .../maplibre/rctmln}/utils/ResourceUtils.java | 2 +- .../rctmln}/utils/SimpleEventCallback.java | 6 +- .../rctmln}/utils/SphericalMercator.java | 2 +- .../main/res/drawable-xxhdpi/red_marker.png | Bin .../src/main/res/drawable/empty.xml | 0 .../src/main/res/drawable/empty_drawable.png | Bin .../src/main/res/layout/annotation.xml | 0 .../rctmln/src/main/res/values/strings.xml | 3 + android/settings.gradle | 2 +- docs/Annotations.md | 2 +- docs/Callout.md | 2 +- docs/CustomHttpHeaders.md | 8 +- docs/MapView.md | 2 +- docs/docs.json | 4 +- example/android/app/build.gradle | 2 +- .../rnmaplibreexample/MainApplication.java | 4 +- example/android/settings.gradle | 4 +- example/ios/Podfile | 7 +- .../project.pbxproj | 65 +- .../xcshareddata/swiftpm/Package.resolved | 5 +- example/ios/RNMaplibreExample/AppDelegate.m | 4 +- ios/RCTMGL.xcodeproj/project.pbxproj | 775 ----------------- .../MGLFaux3DUserLocationAnnotationView.h | 23 - ios/RCTMGL/MGLUserLocationHeadingBeamLayer.h | 11 - ios/RCTMGL/RCTMGLBackgroundLayer.h | 14 - ios/RCTMGL/RCTMGLBackgroundLayer.m | 27 - ios/RCTMGL/RCTMGLCalloutManager.m | 21 - ios/RCTMGL/RCTMGLCircleLayer.h | 13 - ios/RCTMGL/RCTMGLFillExtrusionLayer.h | 14 - ios/RCTMGL/RCTMGLFillLayer.h | 14 - ios/RCTMGL/RCTMGLHeatmapLayer.h | 12 - ios/RCTMGL/RCTMGLHeatmapLayer.m | 30 - ios/RCTMGL/RCTMGLHeatmapLayerManager.h | 12 - ios/RCTMGL/RCTMGLImagesManager.h | 5 - ios/RCTMGL/RCTMGLLineLayer.h | 14 - ios/RCTMGL/RCTMGLLocationManager.h | 30 - ios/RCTMGL/RCTMGLLocationManagerDelegate.h | 20 - ios/RCTMGL/RCTMGLLogging.h | 18 - ios/RCTMGL/RCTMGLNativeUserLocationManager.h | 5 - ios/RCTMGL/RCTMGLNativeUserLocationManager.m | 25 - ios/RCTMGL/RCTMGLRasterLayer.h | 14 - ios/RCTMGL/RCTMGLRasterLayer.m | 30 - ios/RCTMGL/RCTMGLStyle.h | 222 ----- ios/RCTMGL/RCTMGLTileSource.m | 31 - ios/RCTMGL/RCTMGLUserLocation.h | 15 - ios/RCTMLN.xcodeproj/project.pbxproj | 775 +++++++++++++++++ ios/{RCTMGL => RCTMLN}/CameraMode.h | 2 +- ios/{RCTMGL => RCTMLN}/CameraMode.m | 2 +- ios/{RCTMGL => RCTMLN}/CameraStop.h | 8 +- ios/{RCTMGL => RCTMLN}/CameraStop.m | 14 +- ios/{RCTMGL => RCTMLN}/CameraUpdateItem.h | 6 +- ios/{RCTMGL => RCTMLN}/CameraUpdateItem.m | 38 +- ios/{RCTMGL => RCTMLN}/CameraUpdateQueue.h | 6 +- ios/{RCTMGL => RCTMLN}/CameraUpdateQueue.m | 6 +- ios/{RCTMGL => RCTMLN}/FilterParser.h | 2 +- ios/{RCTMGL => RCTMLN}/FilterParser.m | 6 +- .../MLNCustomHeaders.h} | 6 +- .../MLNCustomHeaders.m} | 20 +- .../MLNFaux3DUserLocationAnnotationView.h | 23 + .../MLNFaux3DUserLocationAnnotationView.m} | 76 +- .../MGLModule.h => RCTMLN/MLNModule.h} | 6 +- .../MGLModule.m => RCTMLN/MLNModule.m} | 182 ++-- .../MLNOfflineModule.h} | 8 +- .../MLNOfflineModule.m} | 118 +-- .../MLNSnapshotModule.h} | 6 +- .../MLNSnapshotModule.m} | 28 +- .../MLNUserLocationHeadingArrowLayer.h} | 8 +- .../MLNUserLocationHeadingArrowLayer.m} | 14 +- ios/RCTMLN/MLNUserLocationHeadingBeamLayer.h | 11 + .../MLNUserLocationHeadingBeamLayer.m} | 20 +- .../MLNUserLocationHeadingIndicator.h} | 6 +- ios/{RCTMGL => RCTMLN}/RCTConvert+Mapbox.h | 2 +- ios/{RCTMGL => RCTMLN}/RCTConvert+Mapbox.m | 2 +- ios/{RCTMGL/RCTMGL.h => RCTMLN/RCTMLN.h} | 6 +- ios/{RCTMGL/RCTMGL.m => RCTMLN/RCTMLN.m} | 8 +- ios/RCTMLN/RCTMLNBackgroundLayer.h | 14 + ios/RCTMLN/RCTMLNBackgroundLayer.m | 27 + .../RCTMLNBackgroundLayerManager.h} | 6 +- .../RCTMLNBackgroundLayerManager.m} | 12 +- .../RCTMLNCallout.h} | 8 +- .../RCTMLNCallout.m} | 12 +- .../RCTMLNCalloutManager.h} | 6 +- ios/RCTMLN/RCTMLNCalloutManager.m | 21 + .../RCTMGLCamera.h => RCTMLN/RCTMLNCamera.h} | 12 +- .../RCTMGLCamera.m => RCTMLN/RCTMLNCamera.m} | 60 +- .../RCTMLNCameraManager.h} | 6 +- .../RCTMLNCameraManager.m} | 14 +- ios/RCTMLN/RCTMLNCircleLayer.h | 13 + .../RCTMLNCircleLayer.m} | 20 +- .../RCTMLNCircleLayerManager.h} | 6 +- .../RCTMLNCircleLayerManager.m} | 12 +- .../RCTMGLEvent.h => RCTMLN/RCTMLNEvent.h} | 12 +- .../RCTMGLEvent.m => RCTMLN/RCTMLNEvent.m} | 16 +- .../RCTMLNEventProtocol.h} | 6 +- .../RCTMLNEventTypes.h} | 6 +- .../RCTMLNEventTypes.m} | 8 +- ios/RCTMLN/RCTMLNFillExtrusionLayer.h | 14 + .../RCTMLNFillExtrusionLayer.m} | 20 +- .../RCTMLNFillExtrusionLayerManager.h} | 6 +- .../RCTMLNFillExtrusionLayerManager.m} | 12 +- ios/RCTMLN/RCTMLNFillLayer.h | 14 + .../RCTMLNFillLayer.m} | 20 +- .../RCTMLNFillLayerManager.h} | 6 +- .../RCTMLNFillLayerManager.m} | 12 +- ios/RCTMLN/RCTMLNHeatmapLayer.h | 12 + ios/RCTMLN/RCTMLNHeatmapLayer.m | 30 + ios/RCTMLN/RCTMLNHeatmapLayerManager.h | 12 + .../RCTMLNHeatmapLayerManager.m} | 12 +- .../RCTMLNImageQueue.h} | 6 +- .../RCTMLNImageQueue.m} | 20 +- .../RCTMLNImageQueueOperation.h} | 6 +- .../RCTMLNImageQueueOperation.m} | 24 +- .../RCTMLNImageSource.h} | 8 +- .../RCTMLNImageSource.m} | 22 +- .../RCTMLNImageSourceManager.h} | 6 +- .../RCTMLNImageSourceManager.m} | 12 +- .../RCTMGLImages.h => RCTMLN/RCTMLNImages.h} | 8 +- .../RCTMGLImages.m => RCTMLN/RCTMLNImages.m} | 20 +- ios/RCTMLN/RCTMLNImagesManager.h | 5 + .../RCTMLNImagesManager.m} | 8 +- .../RCTMGLLayer.h => RCTMLN/RCTMLNLayer.h} | 22 +- .../RCTMGLLayer.m => RCTMLN/RCTMLNLayer.m} | 34 +- .../RCTMGLLight.h => RCTMLN/RCTMLNLight.h} | 10 +- .../RCTMGLLight.m => RCTMLN/RCTMLNLight.m} | 18 +- .../RCTMLNLightManager.h} | 6 +- .../RCTMLNLightManager.m} | 12 +- ios/RCTMLN/RCTMLNLineLayer.h | 14 + .../RCTMLNLineLayer.m} | 20 +- .../RCTMLNLineLayerManager.h} | 6 +- .../RCTMLNLineLayerManager.m} | 12 +- .../RCTMLNLocation.h} | 6 +- .../RCTMLNLocation.m} | 8 +- ios/RCTMLN/RCTMLNLocationManager.h | 30 + .../RCTMLNLocationManager.m} | 32 +- ios/RCTMLN/RCTMLNLocationManagerDelegate.h | 20 + .../RCTMLNLocationModule.h} | 6 +- .../RCTMLNLocationModule.m} | 26 +- ios/RCTMLN/RCTMLNLogging.h | 18 + .../RCTMLNLogging.m} | 58 +- .../RCTMLNMapTouchEvent.h} | 20 +- .../RCTMLNMapTouchEvent.m} | 36 +- .../RCTMLNMapView.h} | 60 +- .../RCTMLNMapView.m} | 164 ++-- .../RCTMLNMapViewManager.h} | 8 +- .../RCTMLNMapViewManager.m} | 234 ++--- .../RCTMLNNativeUserLocation.h} | 10 +- .../RCTMLNNativeUserLocation.m} | 20 +- ios/RCTMLN/RCTMLNNativeUserLocationManager.h | 5 + ios/RCTMLN/RCTMLNNativeUserLocationManager.m | 25 + .../RCTMLNPointAnnotation.h} | 16 +- .../RCTMLNPointAnnotation.m} | 42 +- .../RCTMLNPointAnnotationManager.h} | 6 +- .../RCTMLNPointAnnotationManager.m} | 12 +- ios/RCTMLN/RCTMLNRasterLayer.h | 14 + ios/RCTMLN/RCTMLNRasterLayer.m | 30 + .../RCTMLNRasterLayerManager.h} | 6 +- .../RCTMLNRasterLayerManager.m} | 12 +- .../RCTMLNRasterSource.h} | 10 +- .../RCTMLNRasterSource.m} | 22 +- .../RCTMLNRasterSourceManager.h} | 6 +- .../RCTMLNRasterSourceManager.m} | 12 +- .../RCTMLNShapeSource.h} | 20 +- .../RCTMLNShapeSource.m} | 100 +-- .../RCTMLNShapeSourceManager.h} | 6 +- .../RCTMLNShapeSourceManager.m} | 50 +- .../RCTMGLSource.h => RCTMLN/RCTMLNSource.h} | 16 +- .../RCTMGLSource.m => RCTMLN/RCTMLNSource.m} | 30 +- ios/RCTMLN/RCTMLNStyle.h | 222 +++++ .../RCTMGLStyle.m => RCTMLN/RCTMLNStyle.m} | 690 +++++++-------- .../RCTMLNStyleValue.h} | 14 +- .../RCTMLNStyleValue.m} | 48 +- .../RCTMLNSymbolLayer.h} | 8 +- .../RCTMLNSymbolLayer.m} | 24 +- .../RCTMLNSymbolLayerManager.h} | 6 +- .../RCTMLNSymbolLayerManager.m} | 12 +- .../RCTMLNTileSource.h} | 12 +- ios/RCTMLN/RCTMLNTileSource.m | 31 + ios/RCTMLN/RCTMLNUserLocation.h | 15 + .../RCTMLNUserLocation.m} | 16 +- .../RCTMGLUtils.h => RCTMLN/RCTMLNUtils.h} | 14 +- .../RCTMGLUtils.m => RCTMLN/RCTMLNUtils.m} | 40 +- .../RCTMLNVectorLayer.h} | 8 +- .../RCTMLNVectorLayer.m} | 14 +- .../RCTMLNVectorSource.h} | 12 +- .../RCTMLNVectorSource.m} | 18 +- .../RCTMLNVectorSourceManager.h} | 6 +- .../RCTMLNVectorSourceManager.m} | 22 +- ios/{RCTMGL => RCTMLN}/RNMBImageUtils.h | 2 +- ios/{RCTMGL => RCTMLN}/RNMBImageUtils.m | 4 +- ios/{RCTMGL => RCTMLN}/ViewManager.h | 6 +- ios/{RCTMGL => RCTMLN}/ViewManager.m | 8 +- ios/{RCTMGL => RCTMLN}/index.d.ts | 0 ios/install.md | 8 +- javascript/{MGLModule.ts => MLNModule.ts} | 6 +- javascript/Maplibre.ts | 2 +- javascript/components/BackgroundLayer.tsx | 10 +- javascript/components/Callout.tsx | 10 +- javascript/components/Camera.tsx | 8 +- javascript/components/CircleLayer.tsx | 10 +- javascript/components/FillExtrusionLayer.tsx | 8 +- javascript/components/FillLayer.tsx | 8 +- javascript/components/HeatmapLayer.tsx | 8 +- javascript/components/ImageSource.tsx | 8 +- javascript/components/Images.tsx | 6 +- javascript/components/Light.tsx | 8 +- javascript/components/LineLayer.tsx | 8 +- javascript/components/MapView.tsx | 30 +- javascript/components/MarkerView.tsx | 6 +- javascript/components/NativeUserLocation.tsx | 6 +- javascript/components/PointAnnotation.tsx | 8 +- javascript/components/RasterLayer.tsx | 8 +- javascript/components/RasterSource.tsx | 10 +- javascript/components/ShapeSource.tsx | 10 +- javascript/components/SymbolLayer.tsx | 10 +- javascript/components/VectorSource.tsx | 10 +- .../modules/location/locationManager.ts | 4 +- javascript/modules/offline/OfflinePack.ts | 2 +- javascript/modules/offline/offlineManager.ts | 4 +- .../modules/snapshot/SnapshotOptions.ts | 2 +- .../modules/snapshot/snapshotManager.ts | 2 +- javascript/utils/Logger.ts | 6 +- javascript/utils/animated/AnimatedShape.ts | 2 +- maplibre-react-native.podspec | 6 +- package.json | 3 +- react-native.config.js | 2 +- scripts/autogenHelpers/globals.js | 20 +- scripts/autogenerate.js | 22 +- .../{RCTMGLStyle.h.ejs => RCTMLNStyle.h.ejs} | 16 +- .../{RCTMGLStyle.m.ejs => RCTMLNStyle.m.ejs} | 20 +- ...y.java.ejs => RCTMLNStyleFactory.java.ejs} | 20 +- setup-jest.js | 8 +- 351 files changed, 4590 insertions(+), 4592 deletions(-) delete mode 100644 android/rctmgl/src/main/java/com/mapbox/rctmgl/RCTMGLPackage.java delete mode 100644 android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLCalloutManager.java delete mode 100644 android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLBackgroundLayer.java delete mode 100644 android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLRasterLayer.java delete mode 100644 android/rctmgl/src/main/res/values/strings.xml rename android/{rctmgl => rctmln}/.gitignore (100%) rename android/{rctmgl => rctmln}/.npmignore (100%) rename android/{rctmgl => rctmln}/.settings/org.eclipse.buildship.core.prefs (100%) rename android/{rctmgl => rctmln}/build.gradle (100%) rename android/{rctmgl => rctmln}/proguard-rules.pro (100%) rename android/{rctmgl => rctmln}/src/main/AndroidManifest.xml (85%) create mode 100644 android/rctmln/src/main/java/com/maplibre/rctmln/RCTMLNPackage.java rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/AbstractEvent.java (92%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/AbstractEventEmitter.java (96%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/AbstractMapFeature.java (56%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/annotation/MarkerView.java (90%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/annotation/MarkerViewManager.java (97%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLCallout.java => rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNCallout.java} (53%) create mode 100644 android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNCalloutManager.java rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLMarkerView.java => rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNMarkerView.java} (82%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLMarkerViewManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNMarkerViewManager.java} (59%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLPointAnnotation.java => rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNPointAnnotation.java} (92%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLPointAnnotationManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNPointAnnotationManager.java} (71%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/camera/CameraStop.java (95%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/camera/CameraUpdateItem.java (96%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/camera/CameraUpdateQueue.java (90%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/RCTMGLCamera.java => rctmln/src/main/java/com/maplibre/rctmln/components/camera/RCTMLNCamera.java} (93%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/RCTMGLCameraManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/camera/RCTMLNCameraManager.java} (64%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/camera/constants/CameraMode.java (89%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/images/RCTMGLImages.java => rctmln/src/main/java/com/maplibre/rctmln/components/images/RCTMLNImages.java} (90%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/images/RCTMGLImagesManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/images/RCTMLNImagesManager.java} (73%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/location/LocationComponentManager.java (94%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/location/RCTMGLNativeUserLocation.java => rctmln/src/main/java/com/maplibre/rctmln/components/location/RCTMLNNativeUserLocation.java} (80%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/location/RCTMGLNativeUserLocationManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/location/RCTMLNNativeUserLocationManager.java} (66%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/mapview/LayerSourceInfo.java (98%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLAndroidTextureMapView.java => rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNAndroidTextureMapView.java} (55%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLAndroidTextureMapViewManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNAndroidTextureMapViewManager.java} (58%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLMapView.java => rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNMapView.java} (92%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLMapViewManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNMapViewManager.java} (80%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/mapview/helpers/CameraChangeTracker.java (94%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyle.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyle.java} (77%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleFactory.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleFactory.java} (75%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleFunctionParser.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleFunctionParser.java} (90%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleValue.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleValue.java} (94%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/styles/layers/RCTLayer.java (93%) create mode 100644 android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNBackgroundLayer.java rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLBackgroundLayerManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNBackgroundLayerManager.java} (58%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLCircleLayer.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNCircleLayer.java} (64%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLCircleLayerManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNCircleLayerManager.java} (59%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillExtrusionLayer.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillExtrusionLayer.java} (64%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillExtrusionLayerManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillExtrusionLayerManager.java} (60%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillLayer.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillLayer.java} (67%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillLayerManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillLayerManager.java} (59%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLHeatmapLayer.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNHeatmapLayer.java} (64%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLHeatmapLayerManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNHeatmapLayerManager.java} (57%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLLineLayer.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNLineLayer.java} (67%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLLineLayerManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNLineLayerManager.java} (56%) create mode 100644 android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNRasterLayer.java rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLRasterLayerManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNRasterLayerManager.java} (57%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLSymbolLayer.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNSymbolLayer.java} (64%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLSymbolLayerManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNSymbolLayerManager.java} (59%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/light/RCTMGLLight.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/light/RCTMLNLight.java} (67%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/light/RCTMGLLightManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/light/RCTMLNLightManager.java} (57%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLImageSource.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNImageSource.java} (89%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLImageSourceManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNImageSourceManager.java} (58%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLRasterSource.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNRasterSource.java} (85%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLRasterSourceManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNRasterSourceManager.java} (60%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLShapeSource.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNShapeSource.java} (93%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLShapeSourceManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNShapeSourceManager.java} (76%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLTileSource.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNTileSource.java} (93%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLTileSourceManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNTileSourceManager.java} (89%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLVectorSource.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNVectorSource.java} (85%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLVectorSourceManager.java => rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNVectorSourceManager.java} (72%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/components/styles/sources/RCTSource.java (94%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/AbstractEvent.java (97%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/AndroidCallbackEvent.java (91%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/EventEmitter.java (97%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/FeatureClickEvent.java (89%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/IEvent.java (90%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/ImageMissingEvent.java (87%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/LocationEvent.java (89%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/MapChangeEvent.java (85%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/MapClickEvent.java (87%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/MapUserTrackingModeEvent.java (81%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/OfflineEvent.java (94%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/PointAnnotationClickEvent.java (75%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/PointAnnotationDragEvent.java (77%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/constants/EventKeys.java (97%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/events/constants/EventTypes.java (98%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/http/CustomHeadersInterceptor.java (97%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/location/LocationManager.java (99%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/location/UserLocation.java (97%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/location/UserLocationVerticalAlignment.java (84%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/location/UserTrackingMode.java (97%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/location/UserTrackingState.java (92%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLLocationModule.java => rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNLocationModule.java} (91%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLLogging.java => rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNLogging.java} (93%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLModule.java => rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNModule.java} (92%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLOfflineModule.java => rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNOfflineModule.java} (97%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLSnapshotModule.java => rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNSnapshotModule.java} (92%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/BitmapUtils.java (99%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/ClusterPropertyEntry.java (89%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/ConvertUtils.java (99%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/DownloadMapImageTask.java (99%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/ExpressionParser.java (98%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/GeoJSONUtils.java (99%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/GeoViewport.java (97%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/ImageEntry.java (93%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/ResourceUtils.java (95%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/SimpleEventCallback.java (80%) rename android/{rctmgl/src/main/java/com/mapbox/rctmgl => rctmln/src/main/java/com/maplibre/rctmln}/utils/SphericalMercator.java (98%) rename android/{rctmgl => rctmln}/src/main/res/drawable-xxhdpi/red_marker.png (100%) rename android/{rctmgl => rctmln}/src/main/res/drawable/empty.xml (100%) rename android/{rctmgl => rctmln}/src/main/res/drawable/empty_drawable.png (100%) rename android/{rctmgl => rctmln}/src/main/res/layout/annotation.xml (100%) create mode 100644 android/rctmln/src/main/res/values/strings.xml delete mode 100644 ios/RCTMGL.xcodeproj/project.pbxproj delete mode 100644 ios/RCTMGL/MGLFaux3DUserLocationAnnotationView.h delete mode 100644 ios/RCTMGL/MGLUserLocationHeadingBeamLayer.h delete mode 100644 ios/RCTMGL/RCTMGLBackgroundLayer.h delete mode 100644 ios/RCTMGL/RCTMGLBackgroundLayer.m delete mode 100644 ios/RCTMGL/RCTMGLCalloutManager.m delete mode 100644 ios/RCTMGL/RCTMGLCircleLayer.h delete mode 100644 ios/RCTMGL/RCTMGLFillExtrusionLayer.h delete mode 100644 ios/RCTMGL/RCTMGLFillLayer.h delete mode 100644 ios/RCTMGL/RCTMGLHeatmapLayer.h delete mode 100644 ios/RCTMGL/RCTMGLHeatmapLayer.m delete mode 100644 ios/RCTMGL/RCTMGLHeatmapLayerManager.h delete mode 100644 ios/RCTMGL/RCTMGLImagesManager.h delete mode 100644 ios/RCTMGL/RCTMGLLineLayer.h delete mode 100644 ios/RCTMGL/RCTMGLLocationManager.h delete mode 100644 ios/RCTMGL/RCTMGLLocationManagerDelegate.h delete mode 100644 ios/RCTMGL/RCTMGLLogging.h delete mode 100644 ios/RCTMGL/RCTMGLNativeUserLocationManager.h delete mode 100644 ios/RCTMGL/RCTMGLNativeUserLocationManager.m delete mode 100644 ios/RCTMGL/RCTMGLRasterLayer.h delete mode 100644 ios/RCTMGL/RCTMGLRasterLayer.m delete mode 100644 ios/RCTMGL/RCTMGLStyle.h delete mode 100644 ios/RCTMGL/RCTMGLTileSource.m delete mode 100644 ios/RCTMGL/RCTMGLUserLocation.h create mode 100644 ios/RCTMLN.xcodeproj/project.pbxproj rename ios/{RCTMGL => RCTMLN}/CameraMode.h (97%) rename ios/{RCTMGL => RCTMLN}/CameraMode.m (97%) rename ios/{RCTMGL => RCTMLN}/CameraStop.h (83%) rename ios/{RCTMGL => RCTMLN}/CameraStop.m (86%) rename ios/{RCTMGL => RCTMLN}/CameraUpdateItem.h (75%) rename ios/{RCTMGL => RCTMLN}/CameraUpdateItem.m (84%) rename ios/{RCTMGL => RCTMLN}/CameraUpdateQueue.h (80%) rename ios/{RCTMGL => RCTMLN}/CameraUpdateQueue.m (92%) rename ios/{RCTMGL => RCTMLN}/FilterParser.h (95%) rename ios/{RCTMGL => RCTMLN}/FilterParser.m (74%) rename ios/{RCTMGL/MGLCustomHeaders.h => RCTMLN/MLNCustomHeaders.h} (82%) rename ios/{RCTMGL/MGLCustomHeaders.m => RCTMLN/MLNCustomHeaders.m} (86%) create mode 100644 ios/RCTMLN/MLNFaux3DUserLocationAnnotationView.h rename ios/{RCTMGL/MGLFaux3DUserLocationAnnotationView.m => RCTMLN/MLNFaux3DUserLocationAnnotationView.m} (85%) rename ios/{RCTMGL/MGLModule.h => RCTMLN/MLNModule.h} (70%) rename ios/{RCTMGL/MGLModule.m => RCTMLN/MLNModule.m} (61%) rename ios/{RCTMGL/MGLOfflineModule.h => RCTMLN/MLNOfflineModule.h} (72%) rename ios/{RCTMGL/MGLOfflineModule.m => RCTMLN/MLNOfflineModule.m} (80%) rename ios/{RCTMGL/MGLSnapshotModule.h => RCTMLN/MLNSnapshotModule.h} (61%) rename ios/{RCTMGL/MGLSnapshotModule.m => RCTMLN/MLNSnapshotModule.m} (74%) rename ios/{RCTMGL/MGLUserLocationHeadingArrowLayer.h => RCTMLN/MLNUserLocationHeadingArrowLayer.h} (52%) rename ios/{RCTMGL/MGLUserLocationHeadingArrowLayer.m => RCTMLN/MLNUserLocationHeadingArrowLayer.m} (79%) create mode 100644 ios/RCTMLN/MLNUserLocationHeadingBeamLayer.h rename ios/{RCTMGL/MGLUserLocationHeadingBeamLayer.m => RCTMLN/MLNUserLocationHeadingBeamLayer.m} (84%) rename ios/{RCTMGL/MGLUserLocationHeadingIndicator.h => RCTMLN/MLNUserLocationHeadingIndicator.h} (57%) rename ios/{RCTMGL => RCTMLN}/RCTConvert+Mapbox.h (96%) rename ios/{RCTMGL => RCTMLN}/RCTConvert+Mapbox.m (98%) rename ios/{RCTMGL/RCTMGL.h => RCTMLN/RCTMLN.h} (73%) rename ios/{RCTMGL/RCTMGL.m => RCTMLN/RCTMLN.m} (63%) create mode 100644 ios/RCTMLN/RCTMLNBackgroundLayer.h create mode 100644 ios/RCTMLN/RCTMLNBackgroundLayer.m rename ios/{RCTMGL/RCTMGLBackgroundLayerManager.h => RCTMLN/RCTMLNBackgroundLayerManager.h} (57%) rename ios/{RCTMGL/RCTMGLBackgroundLayerManager.m => RCTMLN/RCTMLNBackgroundLayerManager.m} (73%) rename ios/{RCTMGL/RCTMGLCallout.h => RCTMLN/RCTMLNCallout.h} (57%) rename ios/{RCTMGL/RCTMGLCallout.m => RCTMLN/RCTMLNCallout.m} (90%) rename ios/{RCTMGL/RCTMGLCalloutManager.h => RCTMLN/RCTMLNCalloutManager.h} (61%) create mode 100644 ios/RCTMLN/RCTMLNCalloutManager.m rename ios/{RCTMGL/RCTMGLCamera.h => RCTMLN/RCTMLNCamera.h} (85%) rename ios/{RCTMGL/RCTMGLCamera.m => RCTMLN/RCTMLNCamera.m} (78%) rename ios/{RCTMGL/RCTMGLCameraManager.h => RCTMLN/RCTMLNCameraManager.h} (62%) rename ios/{RCTMGL/RCTMGLCameraManager.m => RCTMLN/RCTMLNCameraManager.m} (82%) create mode 100644 ios/RCTMLN/RCTMLNCircleLayer.h rename ios/{RCTMGL/RCTMGLCircleLayer.m => RCTMLN/RCTMLNCircleLayer.m} (50%) rename ios/{RCTMGL/RCTMGLCircleLayerManager.h => RCTMLN/RCTMLNCircleLayerManager.h} (59%) rename ios/{RCTMGL/RCTMGLCircleLayerManager.m => RCTMLN/RCTMLNCircleLayerManager.m} (78%) rename ios/{RCTMGL/RCTMGLEvent.h => RCTMLN/RCTMLNEvent.h} (58%) rename ios/{RCTMGL/RCTMGLEvent.m => RCTMLN/RCTMLNEvent.m} (64%) rename ios/{RCTMGL/RCTMGLEventProtocol.h => RCTMLN/RCTMLNEventProtocol.h} (77%) rename ios/{RCTMGL/RCTMGLEventTypes.h => RCTMLN/RCTMLNEventTypes.h} (95%) rename ios/{RCTMGL/RCTMGLEventTypes.m => RCTMLN/RCTMLNEventTypes.m} (95%) create mode 100644 ios/RCTMLN/RCTMLNFillExtrusionLayer.h rename ios/{RCTMGL/RCTMGLFillExtrusionLayer.m => RCTMLN/RCTMLNFillExtrusionLayer.m} (50%) rename ios/{RCTMGL/RCTMGLFillExtrusionLayerManager.h => RCTMLN/RCTMLNFillExtrusionLayerManager.h} (56%) rename ios/{RCTMGL/RCTMGLFillExtrusionLayerManager.m => RCTMLN/RCTMLNFillExtrusionLayerManager.m} (75%) create mode 100644 ios/RCTMLN/RCTMLNFillLayer.h rename ios/{RCTMGL/RCTMGLFillLayer.m => RCTMLN/RCTMLNFillLayer.m} (51%) rename ios/{RCTMGL/RCTMGLFillLayerManager.h => RCTMLN/RCTMLNFillLayerManager.h} (60%) rename ios/{RCTMGL/RCTMGLFillLayerManager.m => RCTMLN/RCTMLNFillLayerManager.m} (78%) create mode 100644 ios/RCTMLN/RCTMLNHeatmapLayer.h create mode 100644 ios/RCTMLN/RCTMLNHeatmapLayer.m create mode 100644 ios/RCTMLN/RCTMLNHeatmapLayerManager.h rename ios/{RCTMGL/RCTMGLHeatmapLayerManager.m => RCTMLN/RCTMLNHeatmapLayerManager.m} (76%) rename ios/{RCTMGL/RCTMGLImageQueue.h => RCTMLN/RCTMLNImageQueue.h} (84%) rename ios/{RCTMGL/RCTMGLImageQueue.m => RCTMLN/RCTMLNImageQueue.m} (69%) rename ios/{RCTMGL/RCTMGLImageQueueOperation.h => RCTMLN/RCTMLNImageQueueOperation.h} (78%) rename ios/{RCTMGL/RCTMGLImageQueueOperation.m => RCTMLN/RCTMLNImageQueueOperation.m} (79%) rename ios/{RCTMGL/RCTMGLImageSource.h => RCTMLN/RCTMLNImageSource.h} (68%) rename ios/{RCTMGL/RCTMGLImageSource.m => RCTMLN/RCTMLNImageSource.m} (75%) rename ios/{RCTMGL/RCTMGLImageSourceManager.h => RCTMLN/RCTMLNImageSourceManager.h} (60%) rename ios/{RCTMGL/RCTMGLImageSourceManager.m => RCTMLN/RCTMLNImageSourceManager.m} (60%) rename ios/{RCTMGL/RCTMGLImages.h => RCTMLN/RCTMLNImages.h} (80%) rename ios/{RCTMGL/RCTMGLImages.m => RCTMLN/RCTMLNImages.m} (89%) create mode 100644 ios/RCTMLN/RCTMLNImagesManager.h rename ios/{RCTMGL/RCTMGLImagesManager.m => RCTMLN/RCTMLNImagesManager.m} (69%) rename ios/{RCTMGL/RCTMGLLayer.h => RCTMLN/RCTMLNLayer.h} (68%) rename ios/{RCTMGL/RCTMGLLayer.m => RCTMLN/RCTMLNLayer.m} (87%) rename ios/{RCTMGL/RCTMGLLight.h => RCTMLN/RCTMLNLight.h} (60%) rename ios/{RCTMGL/RCTMGLLight.m => RCTMLN/RCTMLNLight.m} (65%) rename ios/{RCTMGL/RCTMGLLightManager.h => RCTMLN/RCTMLNLightManager.h} (63%) rename ios/{RCTMGL/RCTMGLLightManager.m => RCTMLN/RCTMLNLightManager.m} (57%) create mode 100644 ios/RCTMLN/RCTMLNLineLayer.h rename ios/{RCTMGL/RCTMGLLineLayer.m => RCTMLN/RCTMLNLineLayer.m} (50%) rename ios/{RCTMGL/RCTMGLLineLayerManager.h => RCTMLN/RCTMLNLineLayerManager.h} (60%) rename ios/{RCTMGL/RCTMGLLineLayerManager.m => RCTMLN/RCTMLNLineLayerManager.m} (79%) rename ios/{RCTMGL/RCTMGLLocation.h => RCTMLN/RCTMLNLocation.h} (82%) rename ios/{RCTMGL/RCTMGLLocation.m => RCTMLN/RCTMLNLocation.m} (90%) create mode 100644 ios/RCTMLN/RCTMLNLocationManager.h rename ios/{RCTMGL/RCTMGLLocationManager.m => RCTMLN/RCTMLNLocationManager.m} (80%) create mode 100644 ios/RCTMLN/RCTMLNLocationManagerDelegate.h rename ios/{RCTMGL/RCTMGLLocationModule.h => RCTMLN/RCTMLNLocationModule.h} (67%) rename ios/{RCTMGL/RCTMGLLocationModule.m => RCTMLN/RCTMLNLocationModule.m} (69%) create mode 100644 ios/RCTMLN/RCTMLNLogging.h rename ios/{RCTMGL/RCTMGLLogging.m => RCTMLN/RCTMLNLogging.m} (65%) rename ios/{RCTMGL/RCTMGLMapTouchEvent.h => RCTMLN/RCTMLNMapTouchEvent.h} (50%) rename ios/{RCTMGL/RCTMGLMapTouchEvent.m => RCTMLN/RCTMLNMapTouchEvent.m} (66%) rename ios/{RCTMGL/RCTMGLMapView.h => RCTMLN/RCTMLNMapView.h} (62%) rename ios/{RCTMGL/RCTMGLMapView.m => RCTMLN/RCTMLNMapView.m} (75%) rename ios/{RCTMGL/RCTMGLMapViewManager.h => RCTMLN/RCTMLNMapViewManager.h} (71%) rename ios/{RCTMGL/RCTMGLMapViewManager.m => RCTMLN/RCTMLNMapViewManager.m} (72%) rename ios/{RCTMGL/RCTMGLNativeUserLocation.h => RCTMLN/RCTMLNNativeUserLocation.h} (60%) rename ios/{RCTMGL/RCTMGLNativeUserLocation.m => RCTMLN/RCTMLNNativeUserLocation.m} (78%) create mode 100644 ios/RCTMLN/RCTMLNNativeUserLocationManager.h create mode 100644 ios/RCTMLN/RCTMLNNativeUserLocationManager.m rename ios/{RCTMGL/RCTMGLPointAnnotation.h => RCTMLN/RCTMLNPointAnnotation.h} (76%) rename ios/{RCTMGL/RCTMGLPointAnnotation.m => RCTMLN/RCTMLNPointAnnotation.m} (83%) rename ios/{RCTMGL/RCTMGLPointAnnotationManager.h => RCTMLN/RCTMLNPointAnnotationManager.h} (57%) rename ios/{RCTMGL/RCTMGLPointAnnotationManager.m => RCTMLN/RCTMLNPointAnnotationManager.m} (82%) create mode 100644 ios/RCTMLN/RCTMLNRasterLayer.h create mode 100644 ios/RCTMLN/RCTMLNRasterLayer.m rename ios/{RCTMGL/RCTMGLRasterLayerManager.h => RCTMLN/RCTMLNRasterLayerManager.h} (59%) rename ios/{RCTMGL/RCTMGLRasterLayerManager.m => RCTMLN/RCTMLNRasterLayerManager.m} (74%) rename ios/{RCTMGL/RCTMGLRasterSource.h => RCTMLN/RCTMLNRasterSource.h} (55%) rename ios/{RCTMGL/RCTMGLRasterSource.m => RCTMLN/RCTMLNRasterSource.m} (52%) rename ios/{RCTMGL/RCTMGLRasterSourceManager.h => RCTMLN/RCTMLNRasterSourceManager.h} (59%) rename ios/{RCTMGL/RCTMGLRasterSourceManager.m => RCTMLN/RCTMLNRasterSourceManager.m} (72%) rename ios/{RCTMGL/RCTMGLShapeSource.h => RCTMLN/RCTMLNShapeSource.h} (79%) rename ios/{RCTMGL/RCTMGLShapeSource.m => RCTMLN/RCTMLNShapeSource.m} (53%) rename ios/{RCTMGL/RCTMGLShapeSourceManager.h => RCTMLN/RCTMLNShapeSourceManager.h} (62%) rename ios/{RCTMGL/RCTMGLShapeSourceManager.m => RCTMLN/RCTMLNShapeSourceManager.m} (85%) rename ios/{RCTMGL/RCTMGLSource.h => RCTMLN/RCTMLNSource.h} (70%) rename ios/{RCTMGL/RCTMGLSource.m => RCTMLN/RCTMLNSource.m} (82%) create mode 100644 ios/RCTMLN/RCTMLNStyle.h rename ios/{RCTMGL/RCTMGLStyle.m => RCTMLN/RCTMLNStyle.m} (56%) rename ios/{RCTMGL/RCTMGLStyleValue.h => RCTMLN/RCTMLNStyleValue.h} (62%) rename ios/{RCTMGL/RCTMGLStyleValue.m => RCTMLN/RCTMLNStyleValue.m} (80%) rename ios/{RCTMGL/RCTMGLSymbolLayer.h => RCTMLN/RCTMLNSymbolLayer.h} (71%) rename ios/{RCTMGL/RCTMGLSymbolLayer.m => RCTMLN/RCTMLNSymbolLayer.m} (83%) rename ios/{RCTMGL/RCTMGLSymbolLayerManager.h => RCTMLN/RCTMLNSymbolLayerManager.h} (59%) rename ios/{RCTMGL/RCTMGLSymbolLayerManager.m => RCTMLN/RCTMLNSymbolLayerManager.m} (79%) rename ios/{RCTMGL/RCTMGLTileSource.h => RCTMLN/RCTMLNTileSource.h} (65%) create mode 100644 ios/RCTMLN/RCTMLNTileSource.m create mode 100644 ios/RCTMLN/RCTMLNUserLocation.h rename ios/{RCTMGL/RCTMGLUserLocation.m => RCTMLN/RCTMLNUserLocation.m} (52%) rename ios/{RCTMGL/RCTMGLUtils.h => RCTMLN/RCTMLNUtils.h} (74%) rename ios/{RCTMGL/RCTMGLUtils.m => RCTMLN/RCTMLNUtils.m} (85%) rename ios/{RCTMGL/RCTMGLVectorLayer.h => RCTMLN/RCTMLNVectorLayer.h} (62%) rename ios/{RCTMGL/RCTMGLVectorLayer.m => RCTMLN/RCTMLNVectorLayer.m} (80%) rename ios/{RCTMGL/RCTMGLVectorSource.h => RCTMLN/RCTMLNVectorSource.h} (53%) rename ios/{RCTMGL/RCTMGLVectorSource.m => RCTMLN/RCTMLNVectorSource.m} (56%) rename ios/{RCTMGL/RCTMGLVectorSourceManager.h => RCTMLN/RCTMLNVectorSourceManager.h} (61%) rename ios/{RCTMGL/RCTMGLVectorSourceManager.m => RCTMLN/RCTMLNVectorSourceManager.m} (83%) rename ios/{RCTMGL => RCTMLN}/RNMBImageUtils.h (96%) rename ios/{RCTMGL => RCTMLN}/RNMBImageUtils.m (93%) rename ios/{RCTMGL => RCTMLN}/ViewManager.h (69%) rename ios/{RCTMGL => RCTMLN}/ViewManager.m (88%) rename ios/{RCTMGL => RCTMLN}/index.d.ts (100%) rename javascript/{MGLModule.ts => MLNModule.ts} (87%) rename scripts/templates/{RCTMGLStyle.h.ejs => RCTMLNStyle.h.ejs} (74%) rename scripts/templates/{RCTMGLStyle.m.ejs => RCTMLNStyle.m.ejs} (87%) rename scripts/templates/{RCTMGLStyleFactory.java.ejs => RCTMLNStyleFactory.java.ejs} (87%) diff --git a/.gitignore b/.gitignore index 1d5c9b618..42dba6956 100644 --- a/.gitignore +++ b/.gitignore @@ -99,10 +99,11 @@ RNTester/Pods/* # project specific ios/Mapbox.framework +ios/Maplibre.framework ios/temp.zip ios/.framework_version ios/Pods/ -ios/RCTMGL.xcodeproj/xcshareddata/ +ios/RCTMLN.xcodeproj/xcshareddata/ android/build/ android/.gradle/ android/.idea/ diff --git a/.sonarcloud.properties b/.sonarcloud.properties index cd93bc753..fbe9d49e4 100644 --- a/.sonarcloud.properties +++ b/.sonarcloud.properties @@ -1,5 +1,5 @@ # Path to sources -sonar.sources=javascript,android/src,ios/RCTMGL +sonar.sources=javascript,android/src,ios/RCTMLN #sonar.exclusions= #sonar.inclusions= diff --git a/CHANGELOG.md b/CHANGELOG.md index 43246491d..a6187f243 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,9 @@ Please add unreleased changes in the following style: PR Title ([#123](link to my pr)) ``` +## 10.0.0-alpha.4 +Update maplibre-native to use [new metal renderer on iOS](https://github.com/maplibre/maplibre-native/releases/tag/ios-v6.4.0) + ## 10.0.0-alpha.3 Fix: Remove unused import breaking react-native 0.74.0 ([#365](https://github.com/maplibre/maplibre-react-native/pull/365)) diff --git a/__tests__/components/BackgroundLayer.test.js b/__tests__/components/BackgroundLayer.test.js index efc36b895..3e38fe98d 100644 --- a/__tests__/components/BackgroundLayer.test.js +++ b/__tests__/components/BackgroundLayer.test.js @@ -9,7 +9,7 @@ describe('BackgroundLayer', () => { , ); - const backgroundLayer = queryByTestId('rctmglBackgroundLayer'); + const backgroundLayer = queryByTestId('rctmlnBackgroundLayer'); const {props} = backgroundLayer; expect(props.sourceID).toStrictEqual('DefaultSourceID'); @@ -30,7 +30,7 @@ describe('BackgroundLayer', () => { }; const {queryByTestId} = render(); - const backgroundLayer = queryByTestId('rctmglBackgroundLayer'); + const backgroundLayer = queryByTestId('rctmlnBackgroundLayer'); const {props} = backgroundLayer; expect(props.id).toStrictEqual(testProps.id); diff --git a/__tests__/components/Callout.test.js b/__tests__/components/Callout.test.js index d4f47e398..504486f46 100644 --- a/__tests__/components/Callout.test.js +++ b/__tests__/components/Callout.test.js @@ -15,7 +15,7 @@ describe('Callout', () => { describe('_renderDefaultCallout', () => { test('renders default children', () => { const {UNSAFE_getByType, UNSAFE_getAllByType} = render(); - const callout = UNSAFE_getByType('RCTMGLCallout'); + const callout = UNSAFE_getByType('RCTMLNCallout'); expect(callout).toBeDefined(); expect(UNSAFE_getAllByType(Text).length).toBe(1); @@ -34,7 +34,7 @@ describe('Callout', () => { , ); - const callout = UNSAFE_getByType('RCTMGLCallout'); + const callout = UNSAFE_getByType('RCTMLNCallout'); const views = UNSAFE_getAllByType(View); const text = UNSAFE_getByType(Text); @@ -76,7 +76,7 @@ describe('Callout', () => { {'Foo Bar'} , ); - const callout = UNSAFE_getByType('RCTMGLCallout'); + const callout = UNSAFE_getByType('RCTMLNCallout'); const views = UNSAFE_getAllByType(View); const calloutWrapperTestStyle = callout.props.style[1].width; diff --git a/__tests__/components/CircleLayer.test.js b/__tests__/components/CircleLayer.test.js index 039b3b701..60dfa4208 100644 --- a/__tests__/components/CircleLayer.test.js +++ b/__tests__/components/CircleLayer.test.js @@ -6,7 +6,7 @@ import {render} from '@testing-library/react-native'; describe('CircleLayer', () => { test('renders correctly with default props', () => { const {queryByTestId} = render(); - const circleLayer = queryByTestId('rctmglCircleLayer'); + const circleLayer = queryByTestId('rctmlnCircleLayer'); const {props} = circleLayer; expect(props.sourceID).toStrictEqual('DefaultSourceID'); @@ -27,7 +27,7 @@ describe('CircleLayer', () => { }; const {queryByTestId} = render(); - const circleLayer = queryByTestId('rctmglCircleLayer'); + const circleLayer = queryByTestId('rctmlnCircleLayer'); const {props} = circleLayer; expect(props.id).toStrictEqual(customProps.id); diff --git a/__tests__/components/HeatmapLayer.test.js b/__tests__/components/HeatmapLayer.test.js index 634df5e38..02801ec76 100644 --- a/__tests__/components/HeatmapLayer.test.js +++ b/__tests__/components/HeatmapLayer.test.js @@ -8,7 +8,7 @@ describe('HeatmapLayer', () => { const {UNSAFE_getByType} = render( , ); - const heatmapLayer = UNSAFE_getByType('RCTMGLHeatmapLayer'); + const heatmapLayer = UNSAFE_getByType('RCTMLNHeatmapLayer'); const {props} = heatmapLayer; expect(props.sourceID).toStrictEqual('DefaultSourceID'); }); @@ -27,7 +27,7 @@ describe('HeatmapLayer', () => { style: {visibility: 'none'}, }; const {UNSAFE_getByType} = render(); - const {props} = UNSAFE_getByType('RCTMGLHeatmapLayer'); + const {props} = UNSAFE_getByType('RCTMLNHeatmapLayer'); expect(props.id).toStrictEqual(testProps.id); expect(props.sourceID).toStrictEqual(testProps.sourceID); diff --git a/__tests__/components/Light.test.js b/__tests__/components/Light.test.js index 8981e0c4c..49aead81a 100644 --- a/__tests__/components/Light.test.js +++ b/__tests__/components/Light.test.js @@ -6,7 +6,7 @@ import {render} from '@testing-library/react-native'; describe('Light', () => { test('renders correctly', () => { const {queryByTestId} = render(); - const light = queryByTestId('rctmglLight'); + const light = queryByTestId('rctmlnLight'); expect(light).toBeDefined(); }); @@ -21,7 +21,7 @@ describe('Light', () => { const {queryByTestId} = render(); - const customStyles = queryByTestId('rctmglLight').props.reactStyle; + const customStyles = queryByTestId('rctmlnLight').props.reactStyle; const {anchor} = customStyles; const {color} = customStyles; const {position} = customStyles; diff --git a/__tests__/modules/location/locationManager.test.js b/__tests__/modules/location/locationManager.test.js index 380a1359f..ff5c36394 100644 --- a/__tests__/modules/location/locationManager.test.js +++ b/__tests__/modules/location/locationManager.test.js @@ -4,8 +4,8 @@ import LocationManager, { import {NativeModules} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; -const MapLibreGLLocationManager = NativeModules.MGLLocationModule; +const MapLibreGL = NativeModules.MLNModule; +const MapLibreGLLocationManager = NativeModules.MLNLocationModule; const location = { coords: { diff --git a/__tests__/modules/offline/OfflinePack.test.js b/__tests__/modules/offline/OfflinePack.test.js index 73dea3c91..8927309c0 100644 --- a/__tests__/modules/offline/OfflinePack.test.js +++ b/__tests__/modules/offline/OfflinePack.test.js @@ -20,7 +20,7 @@ describe('OfflinePack', () => { it('should resume pack download', () => { const spy = jest.spyOn( - NativeModules.MGLOfflineModule, + NativeModules.MLNOfflineModule, 'resumePackDownload', ); const offlinePack = new OfflinePack(fakeNativePack); @@ -30,7 +30,7 @@ describe('OfflinePack', () => { }); it('should pause pack download', () => { - const spy = jest.spyOn(NativeModules.MGLOfflineModule, 'pausePackDownload'); + const spy = jest.spyOn(NativeModules.MLNOfflineModule, 'pausePackDownload'); const offlinePack = new OfflinePack(fakeNativePack); offlinePack.pause(); expect(spy).toHaveBeenCalled(); @@ -38,7 +38,7 @@ describe('OfflinePack', () => { }); it('should get pack status', () => { - const spy = jest.spyOn(NativeModules.MGLOfflineModule, 'getPackStatus'); + const spy = jest.spyOn(NativeModules.MLNOfflineModule, 'getPackStatus'); const offlinePack = new OfflinePack(fakeNativePack); offlinePack.status(); expect(spy).toHaveBeenCalled(); diff --git a/__tests__/modules/offline/offlineManager.test.js b/__tests__/modules/offline/offlineManager.test.js index 5942e53f3..a789db655 100644 --- a/__tests__/modules/offline/offlineManager.test.js +++ b/__tests__/modules/offline/offlineManager.test.js @@ -71,7 +71,7 @@ describe('offlineManager', () => { it('should set max tile count limit', () => { const expectedLimit = 2000; - const spy = jest.spyOn(NativeModules.MGLOfflineModule, 'setTileCountLimit'); + const spy = jest.spyOn(NativeModules.MLNOfflineModule, 'setTileCountLimit'); MapLibreGL.offlineManager.setTileCountLimit(expectedLimit); expect(spy).toHaveBeenCalledWith(expectedLimit); spy.mockRestore(); @@ -80,7 +80,7 @@ describe('offlineManager', () => { it('should set progress event throttle value', () => { const expectedThrottleValue = 500; const spy = jest.spyOn( - NativeModules.MGLOfflineModule, + NativeModules.MLNOfflineModule, 'setProgressEventThrottle', ); MapLibreGL.offlineManager.setProgressEventThrottle(expectedThrottleValue); @@ -194,7 +194,7 @@ describe('offlineManager', () => { beforeEach(() => (Platform.OS = 'android')); it('should set pack observer manually', async () => { - const spy = jest.spyOn(NativeModules.MGLOfflineModule, 'setPackObserver'); + const spy = jest.spyOn(NativeModules.MLNOfflineModule, 'setPackObserver'); const name = `test-${Date.now()}`; const noop = () => {}; @@ -207,7 +207,7 @@ describe('offlineManager', () => { }); it('should not set pack observer manually during create flow', async () => { - const spy = jest.spyOn(NativeModules.MGLOfflineModule, 'setPackObserver'); + const spy = jest.spyOn(NativeModules.MLNOfflineModule, 'setPackObserver'); const name = `test-${Date.now()}`; const noop = () => {}; @@ -223,7 +223,7 @@ describe('offlineManager', () => { beforeEach(() => (Platform.OS = 'ios')); it('should not set pack observer manually', async () => { - const spy = jest.spyOn(NativeModules.MGLOfflineModule, 'setPackObserver'); + const spy = jest.spyOn(NativeModules.MLNOfflineModule, 'setPackObserver'); const name = `test-${Date.now()}`; const noop = () => {}; diff --git a/__tests__/modules/snapshot/SnapshotOptions.test.js b/__tests__/modules/snapshot/SnapshotOptions.test.js index 73e950145..47157eb12 100644 --- a/__tests__/modules/snapshot/SnapshotOptions.test.js +++ b/__tests__/modules/snapshot/SnapshotOptions.test.js @@ -17,7 +17,7 @@ describe('SnapshotOptions', () => { const options = new SnapshotOptions({centerCoordinate}); expect(options.toJSON()).toEqual({ - styleURL: NativeModules.MGLModule.StyleURL.Default, + styleURL: NativeModules.MLNModule.StyleURL.Default, heading: 0.0, pitch: 0.0, zoomLevel: 16.0, @@ -39,7 +39,7 @@ describe('SnapshotOptions', () => { height: 600, writeToDisk: true, withLogo: true, - styleURL: NativeModules.MGLModule.StyleURL.Default, + styleURL: NativeModules.MLNModule.StyleURL.Default, }; const options = new SnapshotOptions(expectedOptions); @@ -59,7 +59,7 @@ describe('SnapshotOptions', () => { ], width: 400, height: 600, - styleURL: NativeModules.MGLModule.StyleURL.Default, + styleURL: NativeModules.MLNModule.StyleURL.Default, writeToDisk: false, withLogo: true, }; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/RCTMGLPackage.java b/android/rctmgl/src/main/java/com/mapbox/rctmgl/RCTMGLPackage.java deleted file mode 100644 index f43ffc80f..000000000 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/RCTMGLPackage.java +++ /dev/null @@ -1,99 +0,0 @@ -package com.mapbox.rctmgl; - -import com.facebook.react.ReactPackage; -import com.facebook.react.bridge.JavaScriptModule; -import com.facebook.react.bridge.NativeModule; -import com.facebook.react.bridge.ReactApplicationContext; -import com.facebook.react.uimanager.ViewManager; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; - -import com.mapbox.rctmgl.components.annotation.RCTMGLCalloutManager; -import com.mapbox.rctmgl.components.annotation.RCTMGLPointAnnotationManager; -import com.mapbox.rctmgl.components.annotation.RCTMGLMarkerViewManager; -import com.mapbox.rctmgl.components.camera.RCTMGLCameraManager; -import com.mapbox.rctmgl.components.images.RCTMGLImagesManager; -import com.mapbox.rctmgl.components.location.RCTMGLNativeUserLocationManager; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapViewManager; -import com.mapbox.rctmgl.components.mapview.RCTMGLAndroidTextureMapViewManager; -import com.mapbox.rctmgl.components.styles.layers.RCTMGLBackgroundLayerManager; -import com.mapbox.rctmgl.components.styles.layers.RCTMGLCircleLayerManager; -import com.mapbox.rctmgl.components.styles.layers.RCTMGLFillExtrusionLayerManager; -import com.mapbox.rctmgl.components.styles.layers.RCTMGLFillLayerManager; -import com.mapbox.rctmgl.components.styles.layers.RCTMGLHeatmapLayerManager; -import com.mapbox.rctmgl.components.styles.layers.RCTMGLLineLayerManager; -import com.mapbox.rctmgl.components.styles.layers.RCTMGLRasterLayerManager; -import com.mapbox.rctmgl.components.styles.layers.RCTMGLSymbolLayerManager; -import com.mapbox.rctmgl.components.styles.light.RCTMGLLightManager; -import com.mapbox.rctmgl.components.styles.sources.RCTMGLImageSourceManager; -import com.mapbox.rctmgl.components.styles.sources.RCTMGLRasterSourceManager; -import com.mapbox.rctmgl.components.styles.sources.RCTMGLShapeSourceManager; -import com.mapbox.rctmgl.components.styles.sources.RCTMGLVectorSourceManager; -import com.mapbox.rctmgl.modules.RCTMGLLocationModule; -import com.mapbox.rctmgl.modules.RCTMGLLogging; -import com.mapbox.rctmgl.modules.RCTMGLModule; -import com.mapbox.rctmgl.modules.RCTMGLOfflineModule; -import com.mapbox.rctmgl.modules.RCTMGLSnapshotModule; - -/** - * Created by nickitaliano on 8/18/17. - */ - -public class RCTMGLPackage implements ReactPackage { - - @Override - public List createNativeModules(ReactApplicationContext reactApplicationContext) { - List modules = new ArrayList<>(); - - modules.add(new RCTMGLModule(reactApplicationContext)); - modules.add(new RCTMGLOfflineModule(reactApplicationContext)); - modules.add(new RCTMGLSnapshotModule(reactApplicationContext)); - modules.add(new RCTMGLLocationModule(reactApplicationContext)); - modules.add(new RCTMGLLogging(reactApplicationContext)); - - return modules; - } - - @Deprecated - public List> createJSModules() { - return Collections.emptyList(); - } - - @Override - public List createViewManagers(ReactApplicationContext reactApplicationContext) { - List managers = new ArrayList<>(); - - // components - managers.add(new RCTMGLCameraManager(reactApplicationContext)); - managers.add(new RCTMGLMapViewManager(reactApplicationContext)); - managers.add(new RCTMGLMarkerViewManager(reactApplicationContext)); - managers.add(new RCTMGLAndroidTextureMapViewManager(reactApplicationContext)); - managers.add(new RCTMGLLightManager()); - managers.add(new RCTMGLPointAnnotationManager(reactApplicationContext)); - managers.add(new RCTMGLCalloutManager()); - managers.add(new RCTMGLNativeUserLocationManager()); - - // sources - managers.add(new RCTMGLVectorSourceManager(reactApplicationContext)); - managers.add(new RCTMGLShapeSourceManager(reactApplicationContext)); - managers.add(new RCTMGLRasterSourceManager(reactApplicationContext)); - managers.add(new RCTMGLImageSourceManager()); - - // images - managers.add(new RCTMGLImagesManager(reactApplicationContext)); - - // layers - managers.add(new RCTMGLFillLayerManager()); - managers.add(new RCTMGLFillExtrusionLayerManager()); - managers.add(new RCTMGLHeatmapLayerManager()); - managers.add(new RCTMGLLineLayerManager()); - managers.add(new RCTMGLCircleLayerManager()); - managers.add(new RCTMGLSymbolLayerManager()); - managers.add(new RCTMGLRasterLayerManager()); - managers.add(new RCTMGLBackgroundLayerManager()); - - return managers; - } -} diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLCalloutManager.java b/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLCalloutManager.java deleted file mode 100644 index b8230b289..000000000 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLCalloutManager.java +++ /dev/null @@ -1,22 +0,0 @@ -package com.mapbox.rctmgl.components.annotation; - -import com.facebook.react.uimanager.ThemedReactContext; -import com.facebook.react.uimanager.ViewGroupManager; - -/** - * Created by nickitaliano on 10/11/17. - */ - -public class RCTMGLCalloutManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLCallout"; - - @Override - public String getName() { - return REACT_CLASS; - } - - @Override - protected RCTMGLCallout createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLCallout(reactContext); - } -} diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLBackgroundLayer.java b/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLBackgroundLayer.java deleted file mode 100644 index 8e360cbf4..000000000 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLBackgroundLayer.java +++ /dev/null @@ -1,27 +0,0 @@ -package com.mapbox.rctmgl.components.styles.layers; - -import android.content.Context; - -import com.mapbox.mapboxsdk.style.layers.BackgroundLayer; -import com.mapbox.rctmgl.components.styles.RCTMGLStyle; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleFactory; - -/** - * Created by nickitaliano on 9/25/17. - */ - -public class RCTMGLBackgroundLayer extends RCTLayer { - public RCTMGLBackgroundLayer(Context context) { - super(context); - } - - @Override - public BackgroundLayer makeLayer() { - return new BackgroundLayer(mID); - } - - @Override - public void addStyles() { - RCTMGLStyleFactory.setBackgroundLayerStyle(mLayer, new RCTMGLStyle(getContext(), mReactStyle, mMap)); - } -} diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLRasterLayer.java b/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLRasterLayer.java deleted file mode 100644 index c7c65325b..000000000 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLRasterLayer.java +++ /dev/null @@ -1,27 +0,0 @@ -package com.mapbox.rctmgl.components.styles.layers; - -import android.content.Context; - -import com.mapbox.mapboxsdk.style.layers.RasterLayer; -import com.mapbox.rctmgl.components.styles.RCTMGLStyle; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleFactory; - -/** - * Created by nickitaliano on 9/25/17. - */ - -public class RCTMGLRasterLayer extends RCTLayer { - public RCTMGLRasterLayer(Context context) { - super(context); - } - - @Override - public RasterLayer makeLayer() { - return new RasterLayer(mID, mSourceID); - } - - @Override - public void addStyles() { - RCTMGLStyleFactory.setRasterLayerStyle(mLayer, new RCTMGLStyle(getContext(), mReactStyle, mMap)); - } -} diff --git a/android/rctmgl/src/main/res/values/strings.xml b/android/rctmgl/src/main/res/values/strings.xml deleted file mode 100644 index 069947f47..000000000 --- a/android/rctmgl/src/main/res/values/strings.xml +++ /dev/null @@ -1,3 +0,0 @@ - - RCTMGL - diff --git a/android/rctmgl/.gitignore b/android/rctmln/.gitignore similarity index 100% rename from android/rctmgl/.gitignore rename to android/rctmln/.gitignore diff --git a/android/rctmgl/.npmignore b/android/rctmln/.npmignore similarity index 100% rename from android/rctmgl/.npmignore rename to android/rctmln/.npmignore diff --git a/android/rctmgl/.settings/org.eclipse.buildship.core.prefs b/android/rctmln/.settings/org.eclipse.buildship.core.prefs similarity index 100% rename from android/rctmgl/.settings/org.eclipse.buildship.core.prefs rename to android/rctmln/.settings/org.eclipse.buildship.core.prefs diff --git a/android/rctmgl/build.gradle b/android/rctmln/build.gradle similarity index 100% rename from android/rctmgl/build.gradle rename to android/rctmln/build.gradle diff --git a/android/rctmgl/proguard-rules.pro b/android/rctmln/proguard-rules.pro similarity index 100% rename from android/rctmgl/proguard-rules.pro rename to android/rctmln/proguard-rules.pro diff --git a/android/rctmgl/src/main/AndroidManifest.xml b/android/rctmln/src/main/AndroidManifest.xml similarity index 85% rename from android/rctmgl/src/main/AndroidManifest.xml rename to android/rctmln/src/main/AndroidManifest.xml index cdc05e12a..335fa4c02 100644 --- a/android/rctmgl/src/main/AndroidManifest.xml +++ b/android/rctmln/src/main/AndroidManifest.xml @@ -1,4 +1,4 @@ - + diff --git a/android/rctmln/src/main/java/com/maplibre/rctmln/RCTMLNPackage.java b/android/rctmln/src/main/java/com/maplibre/rctmln/RCTMLNPackage.java new file mode 100644 index 000000000..cf02f0b8b --- /dev/null +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/RCTMLNPackage.java @@ -0,0 +1,99 @@ +package com.maplibre.rctmln; + +import com.facebook.react.ReactPackage; +import com.facebook.react.bridge.JavaScriptModule; +import com.facebook.react.bridge.NativeModule; +import com.facebook.react.bridge.ReactApplicationContext; +import com.facebook.react.uimanager.ViewManager; + +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; + +import com.maplibre.rctmln.components.annotation.RCTMLNCalloutManager; +import com.maplibre.rctmln.components.annotation.RCTMLNPointAnnotationManager; +import com.maplibre.rctmln.components.annotation.RCTMLNMarkerViewManager; +import com.maplibre.rctmln.components.camera.RCTMLNCameraManager; +import com.maplibre.rctmln.components.images.RCTMLNImagesManager; +import com.maplibre.rctmln.components.location.RCTMLNNativeUserLocationManager; +import com.maplibre.rctmln.components.mapview.RCTMLNMapViewManager; +import com.maplibre.rctmln.components.mapview.RCTMLNAndroidTextureMapViewManager; +import com.maplibre.rctmln.components.styles.layers.RCTMLNBackgroundLayerManager; +import com.maplibre.rctmln.components.styles.layers.RCTMLNCircleLayerManager; +import com.maplibre.rctmln.components.styles.layers.RCTMLNFillExtrusionLayerManager; +import com.maplibre.rctmln.components.styles.layers.RCTMLNFillLayerManager; +import com.maplibre.rctmln.components.styles.layers.RCTMLNHeatmapLayerManager; +import com.maplibre.rctmln.components.styles.layers.RCTMLNLineLayerManager; +import com.maplibre.rctmln.components.styles.layers.RCTMLNRasterLayerManager; +import com.maplibre.rctmln.components.styles.layers.RCTMLNSymbolLayerManager; +import com.maplibre.rctmln.components.styles.light.RCTMLNLightManager; +import com.maplibre.rctmln.components.styles.sources.RCTMLNImageSourceManager; +import com.maplibre.rctmln.components.styles.sources.RCTMLNRasterSourceManager; +import com.maplibre.rctmln.components.styles.sources.RCTMLNShapeSourceManager; +import com.maplibre.rctmln.components.styles.sources.RCTMLNVectorSourceManager; +import com.maplibre.rctmln.modules.RCTMLNLocationModule; +import com.maplibre.rctmln.modules.RCTMLNLogging; +import com.maplibre.rctmln.modules.RCTMLNModule; +import com.maplibre.rctmln.modules.RCTMLNOfflineModule; +import com.maplibre.rctmln.modules.RCTMLNSnapshotModule; + +/** + * Created by nickitaliano on 8/18/17. + */ + +public class RCTMLNPackage implements ReactPackage { + + @Override + public List createNativeModules(ReactApplicationContext reactApplicationContext) { + List modules = new ArrayList<>(); + + modules.add(new RCTMLNModule(reactApplicationContext)); + modules.add(new RCTMLNOfflineModule(reactApplicationContext)); + modules.add(new RCTMLNSnapshotModule(reactApplicationContext)); + modules.add(new RCTMLNLocationModule(reactApplicationContext)); + modules.add(new RCTMLNLogging(reactApplicationContext)); + + return modules; + } + + @Deprecated + public List> createJSModules() { + return Collections.emptyList(); + } + + @Override + public List createViewManagers(ReactApplicationContext reactApplicationContext) { + List managers = new ArrayList<>(); + + // components + managers.add(new RCTMLNCameraManager(reactApplicationContext)); + managers.add(new RCTMLNMapViewManager(reactApplicationContext)); + managers.add(new RCTMLNMarkerViewManager(reactApplicationContext)); + managers.add(new RCTMLNAndroidTextureMapViewManager(reactApplicationContext)); + managers.add(new RCTMLNLightManager()); + managers.add(new RCTMLNPointAnnotationManager(reactApplicationContext)); + managers.add(new RCTMLNCalloutManager()); + managers.add(new RCTMLNNativeUserLocationManager()); + + // sources + managers.add(new RCTMLNVectorSourceManager(reactApplicationContext)); + managers.add(new RCTMLNShapeSourceManager(reactApplicationContext)); + managers.add(new RCTMLNRasterSourceManager(reactApplicationContext)); + managers.add(new RCTMLNImageSourceManager()); + + // images + managers.add(new RCTMLNImagesManager(reactApplicationContext)); + + // layers + managers.add(new RCTMLNFillLayerManager()); + managers.add(new RCTMLNFillExtrusionLayerManager()); + managers.add(new RCTMLNHeatmapLayerManager()); + managers.add(new RCTMLNLineLayerManager()); + managers.add(new RCTMLNCircleLayerManager()); + managers.add(new RCTMLNSymbolLayerManager()); + managers.add(new RCTMLNRasterLayerManager()); + managers.add(new RCTMLNBackgroundLayerManager()); + + return managers; + } +} diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/AbstractEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/AbstractEvent.java similarity index 92% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/AbstractEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/AbstractEvent.java index cf2d10347..d212d106e 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/AbstractEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/AbstractEvent.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components; +package com.maplibre.rctmln.components; import com.facebook.react.bridge.WritableMap; import com.facebook.react.uimanager.events.Event; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/AbstractEventEmitter.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/AbstractEventEmitter.java similarity index 96% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/AbstractEventEmitter.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/AbstractEventEmitter.java index e5c19cefa..952c71775 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/AbstractEventEmitter.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/AbstractEventEmitter.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components; +package com.maplibre.rctmln.components; import android.view.ViewGroup; @@ -8,7 +8,7 @@ import com.facebook.react.uimanager.UIManagerModule; import com.facebook.react.uimanager.ViewGroupManager; import com.facebook.react.uimanager.events.EventDispatcher; -import com.mapbox.rctmgl.events.IEvent; +import com.maplibre.rctmln.events.IEvent; import java.util.HashMap; import java.util.Map; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/AbstractMapFeature.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/AbstractMapFeature.java similarity index 56% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/AbstractMapFeature.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/AbstractMapFeature.java index a06f8fe39..5b5ced450 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/AbstractMapFeature.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/AbstractMapFeature.java @@ -1,9 +1,9 @@ -package com.mapbox.rctmgl.components; +package com.maplibre.rctmln.components; import android.content.Context; import com.facebook.react.views.view.ReactViewGroup; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; /** * Created by nickitaliano on 9/6/17. @@ -14,6 +14,6 @@ public AbstractMapFeature(Context context) { super(context); } - public abstract void addToMap(RCTMGLMapView mapView); - public abstract void removeFromMap(RCTMGLMapView mapView); + public abstract void addToMap(RCTMLNMapView mapView); + public abstract void removeFromMap(RCTMLNMapView mapView); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/MarkerView.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/MarkerView.java similarity index 90% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/MarkerView.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/MarkerView.java index 7a42211dd..ff23d28d0 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/MarkerView.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/MarkerView.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.annotation; +package com.maplibre.rctmln.components.annotation; import android.view.View; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/MarkerViewManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/MarkerViewManager.java similarity index 97% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/MarkerViewManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/MarkerViewManager.java index ed806704c..8f541cc1e 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/MarkerViewManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/MarkerViewManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.annotation; +package com.maplibre.rctmln.components.annotation; import androidx.annotation.NonNull; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLCallout.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNCallout.java similarity index 53% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLCallout.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNCallout.java index 94d53f95c..3c9b48e73 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLCallout.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNCallout.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.annotation; +package com.maplibre.rctmln.components.annotation; import android.content.Context; @@ -8,8 +8,8 @@ * Created by nickitaliano on 10/11/17. */ -public class RCTMGLCallout extends ReactViewGroup { - public RCTMGLCallout(Context context) { +public class RCTMLNCallout extends ReactViewGroup { + public RCTMLNCallout(Context context) { super(context); } } diff --git a/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNCalloutManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNCalloutManager.java new file mode 100644 index 000000000..0ed63f22e --- /dev/null +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNCalloutManager.java @@ -0,0 +1,22 @@ +package com.maplibre.rctmln.components.annotation; + +import com.facebook.react.uimanager.ThemedReactContext; +import com.facebook.react.uimanager.ViewGroupManager; + +/** + * Created by nickitaliano on 10/11/17. + */ + +public class RCTMLNCalloutManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNCallout"; + + @Override + public String getName() { + return REACT_CLASS; + } + + @Override + protected RCTMLNCallout createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNCallout(reactContext); + } +} diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLMarkerView.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNMarkerView.java similarity index 82% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLMarkerView.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNMarkerView.java index 74c4a53a4..6e68c9863 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLMarkerView.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNMarkerView.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.annotation; +package com.maplibre.rctmln.components.annotation; import android.content.Context; import android.graphics.PointF; @@ -9,13 +9,13 @@ import com.mapbox.geojson.Point; import com.mapbox.mapboxsdk.maps.MapboxMap; import com.mapbox.mapboxsdk.maps.OnMapReadyCallback; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.utils.GeoJSONUtils; -public class RCTMGLMarkerView extends AbstractMapFeature implements MarkerView.OnPositionUpdateListener, View.OnLayoutChangeListener { - private RCTMGLMarkerViewManager mManager; - private RCTMGLMapView mMapView; +public class RCTMLNMarkerView extends AbstractMapFeature implements MarkerView.OnPositionUpdateListener, View.OnLayoutChangeListener { + private RCTMLNMarkerViewManager mManager; + private RCTMLNMapView mMapView; private View mChildView; @@ -26,7 +26,7 @@ public class RCTMGLMarkerView extends AbstractMapFeature implements MarkerView.O private Float[] mAnchor; - public RCTMGLMarkerView(Context context, RCTMGLMarkerViewManager manager) { + public RCTMLNMarkerView(Context context, RCTMLNMarkerViewManager manager) { super(context); mManager = manager; } @@ -57,10 +57,10 @@ public void refresh() { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { mMapView = mapView; - final RCTMGLMarkerView rctmglMarkerView = this; + final RCTMLNMarkerView rctmlnMarkerView = this; mMapView.getMapAsync( new OnMapReadyCallback() { @@ -70,8 +70,8 @@ public void onMapReady(@NonNull MapboxMap mapboxMap) { if (mChildView != null) { mMarkerView = new MarkerView(GeoJSONUtils.toLatLng(mCoordinate), mChildView); - mMarkerView.setOnPositionUpdateListener(rctmglMarkerView); - mChildView.addOnLayoutChangeListener(rctmglMarkerView); + mMarkerView.setOnPositionUpdateListener(rctmlnMarkerView); + mChildView.addOnLayoutChangeListener(rctmlnMarkerView); mMarkerViewManager.addMarker(mMarkerView); } } @@ -91,7 +91,7 @@ public PointF onUpdate(PointF pointF) { } @Override - public void removeFromMap(RCTMGLMapView mapView) { + public void removeFromMap(RCTMLNMapView mapView) { if (mMarkerView != null) { mMarkerViewManager.removeMarker(mMarkerView); mChildView.removeOnLayoutChangeListener(this); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLMarkerViewManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNMarkerViewManager.java similarity index 59% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLMarkerViewManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNMarkerViewManager.java index 32c9fb9bb..3504dafa1 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLMarkerViewManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNMarkerViewManager.java @@ -1,19 +1,19 @@ -package com.mapbox.rctmgl.components.annotation; +package com.maplibre.rctmln.components.annotation; import com.facebook.react.bridge.ReactApplicationContext; import com.facebook.react.bridge.ReadableMap; import com.facebook.react.common.MapBuilder; import com.facebook.react.uimanager.ThemedReactContext; import com.facebook.react.uimanager.annotations.ReactProp; -import com.mapbox.rctmgl.components.AbstractEventEmitter; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.components.AbstractEventEmitter; +import com.maplibre.rctmln.utils.GeoJSONUtils; import java.util.Map; -public class RCTMGLMarkerViewManager extends AbstractEventEmitter { - public static final String REACT_CLASS = "RCTMGLMarkerView"; +public class RCTMLNMarkerViewManager extends AbstractEventEmitter { + public static final String REACT_CLASS = "RCTMLNMarkerView"; - public RCTMGLMarkerViewManager(ReactApplicationContext reactApplicationContext) { + public RCTMLNMarkerViewManager(ReactApplicationContext reactApplicationContext) { super(reactApplicationContext); } @@ -23,18 +23,18 @@ public String getName() { } @ReactProp(name="coordinate") - public void setCoordinate(RCTMGLMarkerView markerView, String geoJSONStr) { + public void setCoordinate(RCTMLNMarkerView markerView, String geoJSONStr) { markerView.setCoordinate(GeoJSONUtils.toPointGeometry(geoJSONStr)); } @ReactProp(name="anchor") - public void setAnchor(RCTMGLMarkerView markerView, ReadableMap map) { + public void setAnchor(RCTMLNMarkerView markerView, ReadableMap map) { markerView.setAnchor((float) map.getDouble("x"), (float) map.getDouble("y")); } @Override - protected RCTMGLMarkerView createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLMarkerView(reactContext, this); + protected RCTMLNMarkerView createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNMarkerView(reactContext, this); } @Override diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLPointAnnotation.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNPointAnnotation.java similarity index 92% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLPointAnnotation.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNPointAnnotation.java index daf77fa41..d4ef17731 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLPointAnnotation.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNPointAnnotation.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.annotation; +package com.maplibre.rctmln.components.annotation; import android.content.Context; import android.graphics.PointF; @@ -13,20 +13,20 @@ import com.mapbox.mapboxsdk.plugins.annotation.SymbolManager; import com.mapbox.mapboxsdk.plugins.annotation.SymbolOptions; import com.mapbox.mapboxsdk.maps.MapboxMap; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.events.PointAnnotationClickEvent; -import com.mapbox.rctmgl.events.PointAnnotationDragEvent; -import com.mapbox.rctmgl.events.constants.EventTypes; -import com.mapbox.rctmgl.utils.GeoJSONUtils; -import com.mapbox.rctmgl.utils.BitmapUtils; - -public class RCTMGLPointAnnotation extends AbstractMapFeature implements View.OnLayoutChangeListener { +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.events.PointAnnotationClickEvent; +import com.maplibre.rctmln.events.PointAnnotationDragEvent; +import com.maplibre.rctmln.events.constants.EventTypes; +import com.maplibre.rctmln.utils.GeoJSONUtils; +import com.maplibre.rctmln.utils.BitmapUtils; + +public class RCTMLNPointAnnotation extends AbstractMapFeature implements View.OnLayoutChangeListener { private Context mContext; - private RCTMGLPointAnnotationManager mManager; + private RCTMLNPointAnnotationManager mManager; private Symbol mAnnotation; private MapboxMap mMap; - private RCTMGLMapView mMapView; + private RCTMLNMapView mMapView; private boolean mHasChildren; @@ -51,7 +51,7 @@ public class RCTMGLPointAnnotation extends AbstractMapFeature implements View.On private static final String MARKER_IMAGE_ID = "MARKER_IMAGE_ID"; - public RCTMGLPointAnnotation(Context context, RCTMGLPointAnnotationManager manager) { + public RCTMLNPointAnnotation(Context context, RCTMLNPointAnnotationManager manager) { super(context); mContext = context; mManager = manager; @@ -59,7 +59,7 @@ public RCTMGLPointAnnotation(Context context, RCTMGLPointAnnotationManager manag @Override public void addView(View childView, int childPosition) { - if (childView instanceof RCTMGLCallout) { + if (childView instanceof RCTMLNCallout) { mCalloutView = childView; } else { mChildView = childView; @@ -91,7 +91,7 @@ public void onStyleLoaded(@NonNull Style style) { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { mMapView = mapView; mMap = mapView.getMapboxMap(); makeMarker(); @@ -112,8 +112,8 @@ public void addToMap(RCTMGLMapView mapView) { } @Override - public void removeFromMap(RCTMGLMapView mapView) { - RCTMGLMapView map = (mMapView != null) ? mMapView : mapView; + public void removeFromMap(RCTMLNMapView mapView) { + RCTMLNMapView map = (mMapView != null) ? mMapView : mapView; if (map == null) { return; } @@ -144,7 +144,7 @@ private void refreshBitmap(View v, int left, int top, int right, int bottom) { Bitmap bitmap = BitmapUtils.viewToBitmap(v, left, top, right, bottom); String bitmapId = Integer.toString(v.getId()); addBitmapToStyle(bitmap, bitmapId); - if (v instanceof RCTMGLCallout) { + if (v instanceof RCTMLNCallout) { mCalloutBitmap = bitmap; mCalloutBitmapId = bitmapId; } else { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLPointAnnotationManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNPointAnnotationManager.java similarity index 71% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLPointAnnotationManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNPointAnnotationManager.java index 734b03f33..5afae0f0b 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/annotation/RCTMGLPointAnnotationManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/annotation/RCTMLNPointAnnotationManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.annotation; +package com.maplibre.rctmln.components.annotation; import androidx.annotation.Nullable; @@ -8,9 +8,9 @@ import com.facebook.react.common.MapBuilder; import com.facebook.react.uimanager.ThemedReactContext; import com.facebook.react.uimanager.annotations.ReactProp; -import com.mapbox.rctmgl.components.AbstractEventEmitter; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.components.AbstractEventEmitter; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.utils.GeoJSONUtils; import java.util.Map; @@ -18,10 +18,10 @@ * Created by nickitaliano on 9/27/17. */ -public class RCTMGLPointAnnotationManager extends AbstractEventEmitter { - public static final String REACT_CLASS = "RCTMGLPointAnnotation"; +public class RCTMLNPointAnnotationManager extends AbstractEventEmitter { + public static final String REACT_CLASS = "RCTMLNPointAnnotation"; - public RCTMGLPointAnnotationManager(ReactApplicationContext reactApplicationContext) { + public RCTMLNPointAnnotationManager(ReactApplicationContext reactApplicationContext) { super(reactApplicationContext); } @@ -53,32 +53,32 @@ public String getName() { } @Override - protected RCTMGLPointAnnotation createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLPointAnnotation(reactContext, this); + protected RCTMLNPointAnnotation createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNPointAnnotation(reactContext, this); } @ReactProp(name="id") - public void setId(RCTMGLPointAnnotation annotation, String id) { + public void setId(RCTMLNPointAnnotation annotation, String id) { annotation.setID(id); } @ReactProp(name="coordinate") - public void setCoordinate(RCTMGLPointAnnotation annotation, String geoJSONStr) { + public void setCoordinate(RCTMLNPointAnnotation annotation, String geoJSONStr) { annotation.setCoordinate(GeoJSONUtils.toPointGeometry(geoJSONStr)); } @ReactProp(name="anchor") - public void setAnchor(RCTMGLPointAnnotation annotation, ReadableMap map) { + public void setAnchor(RCTMLNPointAnnotation annotation, ReadableMap map) { annotation.setAnchor((float) map.getDouble("x"), (float) map.getDouble("y")); } @ReactProp(name="draggable") - public void setDraggable(RCTMGLPointAnnotation annotation, Boolean draggable) { + public void setDraggable(RCTMLNPointAnnotation annotation, Boolean draggable) { annotation.setDraggable(draggable); } @Override - public void receiveCommand(RCTMGLPointAnnotation annotation, int commandID, @Nullable ReadableArray args) { + public void receiveCommand(RCTMLNPointAnnotation annotation, int commandID, @Nullable ReadableArray args) { switch (commandID) { case METHOD_REFRESH: annotation.refresh(); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/CameraStop.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/CameraStop.java similarity index 95% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/CameraStop.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/CameraStop.java index 490122ae2..2a4041748 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/CameraStop.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/CameraStop.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.camera; +package com.maplibre.rctmln.components.camera; import android.content.Context; import androidx.annotation.NonNull; @@ -13,10 +13,10 @@ import com.mapbox.mapboxsdk.geometry.LatLng; import com.mapbox.mapboxsdk.geometry.LatLngBounds; import com.mapbox.mapboxsdk.maps.MapboxMap; -import com.mapbox.rctmgl.components.camera.constants.CameraMode; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.components.camera.constants.CameraMode; +import com.maplibre.rctmln.utils.GeoJSONUtils; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; /** * Created by nickitaliano on 9/5/17. @@ -80,7 +80,7 @@ public void setMode(@CameraMode.Mode int mode) { mMode = mode; } - public CameraUpdateItem toCameraUpdate(RCTMGLMapView mapView) { + public CameraUpdateItem toCameraUpdate(RCTMLNMapView mapView) { MapboxMap map = mapView.getMapboxMap(); CameraPosition currentCamera = map.getCameraPosition(); CameraPosition.Builder builder = new CameraPosition.Builder(currentCamera); @@ -212,7 +212,7 @@ public static CameraStop fromReadableMap(Context context, @NonNull ReadableMap r return stop; } - private static int[] clippedPadding(int[] padding, RCTMGLMapView mapView) { + private static int[] clippedPadding(int[] padding, RCTMLNMapView mapView) { int mapHeight = mapView.getHeight(); int mapWidth = mapView.getWidth(); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/CameraUpdateItem.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/CameraUpdateItem.java similarity index 96% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/CameraUpdateItem.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/CameraUpdateItem.java index 4bfb472bd..4efc29ff1 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/CameraUpdateItem.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/CameraUpdateItem.java @@ -1,11 +1,11 @@ -package com.mapbox.rctmgl.components.camera; +package com.maplibre.rctmln.components.camera; import androidx.annotation.NonNull; import com.mapbox.mapboxsdk.camera.CameraUpdate; import com.mapbox.mapboxsdk.constants.MapboxConstants; import com.mapbox.mapboxsdk.maps.MapboxMap; -import com.mapbox.rctmgl.components.camera.constants.CameraMode; +import com.maplibre.rctmln.components.camera.constants.CameraMode; import java.lang.ref.WeakReference; import java.util.concurrent.Callable; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/CameraUpdateQueue.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/CameraUpdateQueue.java similarity index 90% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/CameraUpdateQueue.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/CameraUpdateQueue.java index 5c2ca480d..0afe77840 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/CameraUpdateQueue.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/CameraUpdateQueue.java @@ -1,7 +1,7 @@ -package com.mapbox.rctmgl.components.camera; +package com.maplibre.rctmln.components.camera; import com.mapbox.mapboxsdk.maps.MapboxMap; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; import java.util.ArrayList; import java.util.Iterator; @@ -53,7 +53,7 @@ public void setOnCompleteAllListener(OnCompleteAllListener listener) { mCompleteListener = listener; } - public void execute(RCTMGLMapView map) { + public void execute(RCTMLNMapView map) { if (mQueue.isEmpty()) { if (mCompleteListener != null) { mCompleteListener.onCompleteAll(); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/RCTMGLCamera.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/RCTMLNCamera.java similarity index 93% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/RCTMGLCamera.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/RCTMLNCamera.java index 9e77f5b4e..421f65132 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/RCTMGLCamera.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/RCTMLNCamera.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.camera; +package com.maplibre.rctmln.components.camera; import android.content.Context; import android.location.Location; @@ -18,22 +18,22 @@ import com.mapbox.mapboxsdk.location.LocationComponentOptions; import com.mapbox.mapboxsdk.location.LocationComponentActivationOptions; // import com.mapbox.mapboxsdk.plugins.locationlayer.LocationLayerPlugin; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.location.LocationComponentManager; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.events.IEvent; -import com.mapbox.rctmgl.events.MapUserTrackingModeEvent; -import com.mapbox.rctmgl.events.MapChangeEvent; -import com.mapbox.rctmgl.location.LocationManager; -import com.mapbox.rctmgl.location.UserLocation; -import com.mapbox.rctmgl.location.UserLocationVerticalAlignment; -import com.mapbox.rctmgl.location.UserTrackingMode; -import com.mapbox.rctmgl.location.UserTrackingState; -import com.mapbox.rctmgl.utils.GeoJSONUtils; - -import com.mapbox.rctmgl.R; - -import com.mapbox.rctmgl.events.constants.EventTypes; +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.location.LocationComponentManager; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.events.IEvent; +import com.maplibre.rctmln.events.MapUserTrackingModeEvent; +import com.maplibre.rctmln.events.MapChangeEvent; +import com.maplibre.rctmln.location.LocationManager; +import com.maplibre.rctmln.location.UserLocation; +import com.maplibre.rctmln.location.UserLocationVerticalAlignment; +import com.maplibre.rctmln.location.UserTrackingMode; +import com.maplibre.rctmln.location.UserTrackingState; +import com.maplibre.rctmln.utils.GeoJSONUtils; + +import com.maplibre.rctmln.R; + +import com.maplibre.rctmln.events.constants.EventTypes; import com.facebook.react.bridge.WritableMap; import com.facebook.react.bridge.WritableNativeMap; @@ -44,9 +44,9 @@ import androidx.annotation.NonNull; -public class RCTMGLCamera extends AbstractMapFeature { - private RCTMGLCameraManager mManager; - private RCTMGLMapView mMapView; +public class RCTMLNCamera extends AbstractMapFeature { + private RCTMLNCameraManager mManager; + private RCTMLNMapView mMapView; private boolean hasSentFirstRegion = false; @@ -114,7 +114,7 @@ public void onFinish() { } }; - public RCTMGLCamera(Context context, RCTMGLCameraManager manager) { + public RCTMLNCamera(Context context, RCTMLNCameraManager manager) { super(context); mContext = context; mManager = manager; @@ -125,7 +125,7 @@ public RCTMGLCamera(Context context, RCTMGLCameraManager manager) { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { mMapView = mapView; setInitialCamera(); @@ -142,7 +142,7 @@ public void addToMap(RCTMGLMapView mapView) { } @Override - public void removeFromMap(RCTMGLMapView mapView) { + public void removeFromMap(RCTMLNMapView mapView) { } @@ -191,7 +191,7 @@ private void updateMaxMinZoomLevel() { private void setInitialCamera() { if (mDefaultStop != null) { mDefaultStop.setDuration(0); - mDefaultStop.setMode(com.mapbox.rctmgl.components.camera.constants.CameraMode.NONE); + mDefaultStop.setMode(com.maplibre.rctmln.components.camera.constants.CameraMode.NONE); CameraUpdateItem item = mDefaultStop.toCameraUpdate(mMapView); item.run(); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/RCTMGLCameraManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/RCTMLNCameraManager.java similarity index 64% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/RCTMGLCameraManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/RCTMLNCameraManager.java index 07097ec83..f467c45be 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/RCTMGLCameraManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/RCTMLNCameraManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.camera; +package com.maplibre.rctmln.components.camera; import com.mapbox.geojson.FeatureCollection; import com.facebook.common.logging.FLog; @@ -6,18 +6,18 @@ import com.facebook.react.bridge.ReadableMap; import com.facebook.react.uimanager.ThemedReactContext; import com.facebook.react.uimanager.annotations.ReactProp; -import com.mapbox.rctmgl.components.AbstractEventEmitter; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.components.AbstractEventEmitter; +import com.maplibre.rctmln.utils.GeoJSONUtils; import java.util.HashMap; import java.util.Map; -public class RCTMGLCameraManager extends AbstractEventEmitter { - public static final String REACT_CLASS = "RCTMGLCamera"; +public class RCTMLNCameraManager extends AbstractEventEmitter { + public static final String REACT_CLASS = "RCTMLNCamera"; private ReactApplicationContext mContext; - public RCTMGLCameraManager(ReactApplicationContext context) { + public RCTMLNCameraManager(ReactApplicationContext context) { super(context); mContext = context; } @@ -33,12 +33,12 @@ public String getName() { } @Override - protected RCTMGLCamera createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLCamera(reactContext, this); + protected RCTMLNCamera createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNCamera(reactContext, this); } @ReactProp(name="stop") - public void setStop(RCTMGLCamera camera, ReadableMap map) { + public void setStop(RCTMLNCamera camera, ReadableMap map) { if (map != null) { CameraStop stop = CameraStop.fromReadableMap(mContext, map, null); camera.setStop(stop); @@ -46,7 +46,7 @@ public void setStop(RCTMGLCamera camera, ReadableMap map) { } @ReactProp(name="defaultStop") - public void setDefaultStop(RCTMGLCamera camera, ReadableMap map) { + public void setDefaultStop(RCTMLNCamera camera, ReadableMap map) { if (map != null) { CameraStop stop = CameraStop.fromReadableMap(mContext, map, null); camera.setDefaultStop(stop); @@ -54,7 +54,7 @@ public void setDefaultStop(RCTMGLCamera camera, ReadableMap map) { } @ReactProp(name="maxBounds") - public void setMaxBounds(RCTMGLCamera camera, String value) { + public void setMaxBounds(RCTMLNCamera camera, String value) { if (value != null) { FeatureCollection collection = FeatureCollection.fromJson(value); camera.setMaxBounds(GeoJSONUtils.toLatLngBounds(collection)); @@ -63,38 +63,38 @@ public void setMaxBounds(RCTMGLCamera camera, String value) { @ReactProp(name="userTrackingMode") - public void setUserTrackingMode(RCTMGLCamera camera, int userTrackingMode) { + public void setUserTrackingMode(RCTMLNCamera camera, int userTrackingMode) { camera.setUserTrackingMode(userTrackingMode); throw new AssertionError("Unused code"); } @ReactProp(name="followZoomLevel") - public void setZoomLevel(RCTMGLCamera camera, double zoomLevel) { + public void setZoomLevel(RCTMLNCamera camera, double zoomLevel) { camera.setZoomLevel(zoomLevel); } @ReactProp(name="followUserLocation") - public void setFollowUserLocation(RCTMGLCamera camera, boolean value) { + public void setFollowUserLocation(RCTMLNCamera camera, boolean value) { camera.setFollowUserLocation(value); } @ReactProp(name="followUserMode") - public void setFollowUserMode(RCTMGLCamera camera, String value) { + public void setFollowUserMode(RCTMLNCamera camera, String value) { camera.setFollowUserMode(value); } @ReactProp(name="minZoomLevel") - public void setMinZoomLevel(RCTMGLCamera camera, double value) { + public void setMinZoomLevel(RCTMLNCamera camera, double value) { camera.setMinZoomLevel(value); } @ReactProp(name="maxZoomLevel") - public void setMaxZoomLevel(RCTMGLCamera camera, double value) { + public void setMaxZoomLevel(RCTMLNCamera camera, double value) { camera.setMaxZoomLevel(value); } @ReactProp(name="followPitch") - public void setFollowPitch(RCTMGLCamera camera, double value) { + public void setFollowPitch(RCTMLNCamera camera, double value) { camera.setFollowPitch(value); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/constants/CameraMode.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/constants/CameraMode.java similarity index 89% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/constants/CameraMode.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/constants/CameraMode.java index 4d0bc1bcc..4df0b19d5 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/camera/constants/CameraMode.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/camera/constants/CameraMode.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.camera.constants; +package com.maplibre.rctmln.components.camera.constants; import androidx.annotation.IntDef; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/images/RCTMGLImages.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/images/RCTMLNImages.java similarity index 90% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/images/RCTMGLImages.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/images/RCTMLNImages.java index 194905a0a..8dcdff45b 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/images/RCTMGLImages.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/images/RCTMLNImages.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.images; +package com.maplibre.rctmln.components.images; import android.content.Context; import android.graphics.Bitmap; @@ -11,12 +11,12 @@ import com.mapbox.mapboxsdk.maps.MapboxMap; import com.mapbox.mapboxsdk.maps.Style; import com.mapbox.mapboxsdk.utils.BitmapUtils; -import com.mapbox.rctmgl.R; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.events.ImageMissingEvent; -import com.mapbox.rctmgl.utils.DownloadMapImageTask; -import com.mapbox.rctmgl.utils.ImageEntry; +import com.maplibre.rctmln.R; +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.events.ImageMissingEvent; +import com.maplibre.rctmln.utils.DownloadMapImageTask; +import com.maplibre.rctmln.utils.ImageEntry; import java.util.AbstractMap; import java.util.ArrayList; @@ -28,12 +28,12 @@ import java.util.Set; import java.util.stream.Collectors; -public class RCTMGLImages extends AbstractMapFeature { +public class RCTMLNImages extends AbstractMapFeature { private static Bitmap mImagePlaceholder; Set mCurrentImages; private Map mImages; private Map mNativeImages; - private RCTMGLImagesManager mManager; + private RCTMLNImagesManager mManager; private boolean mSendMissingImageEvents = false; private MapboxMap mMap; @@ -47,7 +47,7 @@ public void setID(String id) { mID = id; } - public RCTMGLImages(Context context, RCTMGLImagesManager manager) { + public RCTMLNImages(Context context, RCTMLNImagesManager manager) { super(context); mManager = manager; mCurrentImages = new HashSet<>(); @@ -93,7 +93,7 @@ public void setHasOnImageMissing(boolean value) { } @Override - public void removeFromMap(RCTMGLMapView mapView) { + public void removeFromMap(RCTMLNMapView mapView) { removeImages(mapView); mMap = null; mNativeImages = new HashMap<>(); @@ -101,7 +101,7 @@ public void removeFromMap(RCTMGLMapView mapView) { mCurrentImages = new HashSet<>(); } - private void removeImages(RCTMGLMapView mapView) { + private void removeImages(RCTMLNMapView mapView) { mapView.getStyle(new Style.OnStyleLoaded() { @Override public void onStyleLoaded(@NonNull Style style) { @@ -136,14 +136,14 @@ public boolean addMissingImageToStyle(@NonNull String id, @NonNull MapboxMap map if (mNativeImages != null) { BitmapDrawable drawable = mNativeImages.get(id); if (drawable != null) { - addNativeImages(RCTMGLImages.entry(id, drawable), map); + addNativeImages(RCTMLNImages.entry(id, drawable), map); return true; } } if (mImages != null) { ImageEntry entry = mImages.get(id); if (entry != null) { - addRemoteImages(RCTMGLImages.entry(id, entry), map); + addRemoteImages(RCTMLNImages.entry(id, entry), map); return true; } } @@ -175,7 +175,7 @@ private boolean hasImage(String imageId, @NonNull MapboxMap map) { } @Override - public void addToMap(final RCTMGLMapView mapView) { + public void addToMap(final RCTMLNMapView mapView) { // Wait for style before adding the source to the map // only then we can pre-load required images / placeholders into the style // before we add the ShapeSource to the map diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/images/RCTMGLImagesManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/images/RCTMLNImagesManager.java similarity index 73% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/images/RCTMGLImagesManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/images/RCTMLNImagesManager.java index fa197927f..616b1d9e5 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/images/RCTMGLImagesManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/images/RCTMLNImagesManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.images; +package com.maplibre.rctmln.components.images; import android.graphics.drawable.BitmapDrawable; @@ -11,12 +11,12 @@ import com.facebook.react.uimanager.ThemedReactContext; import com.facebook.react.uimanager.ViewGroupManager; import com.facebook.react.uimanager.annotations.ReactProp; -import com.mapbox.rctmgl.components.AbstractEventEmitter; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.styles.sources.RCTMGLShapeSource; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.utils.ImageEntry; -import com.mapbox.rctmgl.utils.ResourceUtils; +import com.maplibre.rctmln.components.AbstractEventEmitter; +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.styles.sources.RCTMLNShapeSource; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.utils.ImageEntry; +import com.maplibre.rctmln.utils.ResourceUtils; import java.util.AbstractMap; import java.util.ArrayList; @@ -24,34 +24,34 @@ import java.util.Map; -public class RCTMGLImagesManager extends AbstractEventEmitter { - public static final String REACT_CLASS = "RCTMGLImages"; +public class RCTMLNImagesManager extends AbstractEventEmitter { + public static final String REACT_CLASS = "RCTMLNImages"; private ReactApplicationContext mContext; @Override public String getName() { - return "RCTMGLImages"; + return "RCTMLNImages"; } - public RCTMGLImagesManager(ReactApplicationContext context) { + public RCTMLNImagesManager(ReactApplicationContext context) { super(context); mContext = context; } @Override - public RCTMGLImages createViewInstance(ThemedReactContext context) { - return new RCTMGLImages(context, this); + public RCTMLNImages createViewInstance(ThemedReactContext context) { + return new RCTMLNImages(context, this); } @ReactProp(name = "id") - public void setId(RCTMGLImages source, String id) { + public void setId(RCTMLNImages source, String id) { source.setID(id); } @ReactProp(name = "images") - public void setImages(RCTMGLImages images, ReadableMap map) { + public void setImages(RCTMLNImages images, ReadableMap map) { List> imagesList = new ArrayList<>(); ReadableMapKeySetIterator iterator = map.keySetIterator(); @@ -74,12 +74,12 @@ public void setImages(RCTMGLImages images, ReadableMap map) { } @ReactProp(name = "hasOnImageMissing") - public void setHasOnImageMissing(RCTMGLImages images, Boolean value) { + public void setHasOnImageMissing(RCTMLNImages images, Boolean value) { images.setHasOnImageMissing(value); } @ReactProp(name = "nativeImages") - public void setNativeImages(RCTMGLImages images, ReadableArray arr) { + public void setNativeImages(RCTMLNImages images, ReadableArray arr) { List> resources = new ArrayList<>(); for (int i = 0; i < arr.size(); i++) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/location/LocationComponentManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/location/LocationComponentManager.java similarity index 94% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/location/LocationComponentManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/location/LocationComponentManager.java index 2cf8f0c41..428f6a4c3 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/location/LocationComponentManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/location/LocationComponentManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.location; +package com.maplibre.rctmln.components.location; import android.annotation.SuppressLint; import android.content.Context; @@ -11,9 +11,9 @@ import com.mapbox.mapboxsdk.location.modes.RenderMode; import com.mapbox.mapboxsdk.maps.MapboxMap; import com.mapbox.mapboxsdk.maps.Style; -import com.mapbox.rctmgl.R; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.location.LocationManager; +import com.maplibre.rctmln.R; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.location.LocationManager; import androidx.annotation.NonNull; @@ -23,7 +23,7 @@ * And NativeUserLocation can ask for display of user's current location - independent of Camera's user tracking. */ public class LocationComponentManager { - private RCTMGLMapView mMapView = null; + private RCTMLNMapView mMapView = null; private MapboxMap mMap = null; private LocationManager mLocationManager = null; @@ -32,8 +32,8 @@ public class LocationComponentManager { private @RenderMode.Mode int mRenderMode = RenderMode.COMPASS; - public LocationComponentManager(RCTMGLMapView rctmglMapView, Context context) { - mMapView = rctmglMapView; + public LocationComponentManager(RCTMLNMapView rctmlnMapView, Context context) { + mMapView = rctmlnMapView; mMap = mMapView.getMapboxMap(); mContext = context; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/location/RCTMGLNativeUserLocation.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/location/RCTMLNNativeUserLocation.java similarity index 80% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/location/RCTMGLNativeUserLocation.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/location/RCTMLNNativeUserLocation.java index 745f185cc..69cbad2cf 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/location/RCTMGLNativeUserLocation.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/location/RCTMLNNativeUserLocation.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.location; +package com.maplibre.rctmln.components.location; import android.annotation.SuppressLint; import android.content.Context; @@ -9,21 +9,21 @@ import com.mapbox.mapboxsdk.maps.MapboxMap; import com.mapbox.mapboxsdk.maps.OnMapReadyCallback; import com.mapbox.mapboxsdk.maps.Style; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; -public class RCTMGLNativeUserLocation extends AbstractMapFeature implements OnMapReadyCallback, Style.OnStyleLoaded { +public class RCTMLNNativeUserLocation extends AbstractMapFeature implements OnMapReadyCallback, Style.OnStyleLoaded { private boolean mEnabled = true; private MapboxMap mMap; - private RCTMGLMapView mMapView; + private RCTMLNMapView mMapView; private @RenderMode.Mode int mRenderMode = RenderMode.COMPASS; - public RCTMGLNativeUserLocation(Context context) { + public RCTMLNNativeUserLocation(Context context) { super(context); } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { mEnabled = true; mMapView = mapView; mapView.getMapAsync(this); @@ -31,7 +31,7 @@ public void addToMap(RCTMGLMapView mapView) { } @Override - public void removeFromMap(RCTMGLMapView mapView) { + public void removeFromMap(RCTMLNMapView mapView) { mEnabled = false; if (mMap != null) mMap.getStyle(this); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/location/RCTMGLNativeUserLocationManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/location/RCTMLNNativeUserLocationManager.java similarity index 66% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/location/RCTMGLNativeUserLocationManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/location/RCTMLNNativeUserLocationManager.java index 834246537..ca639e295 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/location/RCTMGLNativeUserLocationManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/location/RCTMLNNativeUserLocationManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.location; +package com.maplibre.rctmln.components.location; import com.facebook.react.uimanager.ThemedReactContext; import com.facebook.react.uimanager.ViewGroupManager; @@ -7,8 +7,8 @@ import javax.annotation.Nonnull; -public class RCTMGLNativeUserLocationManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLNativeUserLocation"; +public class RCTMLNNativeUserLocationManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNNativeUserLocation"; @Nonnull @Override @@ -17,7 +17,7 @@ public String getName() { } @ReactProp(name="androidRenderMode") - public void setAndroidRenderMode(RCTMGLNativeUserLocation userLocation, String mode) { + public void setAndroidRenderMode(RCTMLNNativeUserLocation userLocation, String mode) { if ("compass".equalsIgnoreCase(mode)) { userLocation.setRenderMode(RenderMode.COMPASS); } else if ("gps".equalsIgnoreCase(mode)) { @@ -29,7 +29,7 @@ public void setAndroidRenderMode(RCTMGLNativeUserLocation userLocation, String m @Nonnull @Override - protected RCTMGLNativeUserLocation createViewInstance(@Nonnull ThemedReactContext reactContext) { - return new RCTMGLNativeUserLocation(reactContext); + protected RCTMLNNativeUserLocation createViewInstance(@Nonnull ThemedReactContext reactContext) { + return new RCTMLNNativeUserLocation(reactContext); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/LayerSourceInfo.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/LayerSourceInfo.java similarity index 98% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/LayerSourceInfo.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/LayerSourceInfo.java index e8d93715f..95d99fdb2 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/LayerSourceInfo.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/LayerSourceInfo.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.mapview; +package com.maplibre.rctmln.components.mapview; import com.mapbox.mapboxsdk.style.layers.CircleLayer; import com.mapbox.mapboxsdk.style.layers.FillExtrusionLayer; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLAndroidTextureMapView.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNAndroidTextureMapView.java similarity index 55% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLAndroidTextureMapView.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNAndroidTextureMapView.java index df81804e4..0786fd784 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLAndroidTextureMapView.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNAndroidTextureMapView.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.mapview; +package com.maplibre.rctmln.components.mapview; import android.content.Context; import com.mapbox.mapboxsdk.maps.MapboxMapOptions; @@ -7,10 +7,10 @@ */ @SuppressWarnings({"MissingPermission"}) -public class RCTMGLAndroidTextureMapView extends RCTMGLMapView { - public static final String LOG_TAG = "RCTMGLAndroidTextureMapView"; +public class RCTMLNAndroidTextureMapView extends RCTMLNMapView { + public static final String LOG_TAG = "RCTMLNAndroidTextureMapView"; - public RCTMGLAndroidTextureMapView(Context context, RCTMGLAndroidTextureMapViewManager manager, MapboxMapOptions options) { + public RCTMLNAndroidTextureMapView(Context context, RCTMLNAndroidTextureMapViewManager manager, MapboxMapOptions options) { super(context, manager, options); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLAndroidTextureMapViewManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNAndroidTextureMapViewManager.java similarity index 58% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLAndroidTextureMapViewManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNAndroidTextureMapViewManager.java index 39964b87a..1d6f71181 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLAndroidTextureMapViewManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNAndroidTextureMapViewManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.mapview; +package com.maplibre.rctmln.components.mapview; import com.facebook.react.bridge.ReactApplicationContext; import com.mapbox.mapboxsdk.maps.MapboxMapOptions; @@ -9,11 +9,11 @@ * Created by hernanmateo on 12/11/18. */ -public class RCTMGLAndroidTextureMapViewManager extends RCTMGLMapViewManager { - public static final String LOG_TAG = "RCTMGLAndroidTextureMapViewManager"; - public static final String REACT_CLASS = "RCTMGLAndroidTextureMapView"; +public class RCTMLNAndroidTextureMapViewManager extends RCTMLNMapViewManager { + public static final String LOG_TAG = "RCTMLNAndroidTextureMapViewManager"; + public static final String REACT_CLASS = "RCTMLNAndroidTextureMapView"; - public RCTMGLAndroidTextureMapViewManager(ReactApplicationContext context) { + public RCTMLNAndroidTextureMapViewManager(ReactApplicationContext context) { super(context); } @@ -23,9 +23,9 @@ public String getName() { } @Override - protected RCTMGLAndroidTextureMapView createViewInstance(ThemedReactContext themedReactContext) { + protected RCTMLNAndroidTextureMapView createViewInstance(ThemedReactContext themedReactContext) { MapboxMapOptions options = new MapboxMapOptions(); options.textureMode(true); - return new RCTMGLAndroidTextureMapView(themedReactContext, this, options); + return new RCTMLNAndroidTextureMapView(themedReactContext, this, options); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLMapView.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNMapView.java similarity index 92% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLMapView.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNMapView.java index 4661accb2..a204a85b7 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLMapView.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNMapView.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.mapview; +package com.maplibre.rctmln.components.mapview; import android.content.Context; import android.graphics.Bitmap; @@ -49,29 +49,29 @@ import com.mapbox.mapboxsdk.style.expressions.Expression; import com.mapbox.mapboxsdk.style.layers.Layer; import com.mapbox.mapboxsdk.style.layers.Property; -import com.mapbox.rctmgl.R; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.annotation.RCTMGLPointAnnotation; -import com.mapbox.rctmgl.components.annotation.RCTMGLMarkerView; -import com.mapbox.rctmgl.components.annotation.MarkerView; -import com.mapbox.rctmgl.components.annotation.MarkerViewManager; -import com.mapbox.rctmgl.components.camera.RCTMGLCamera; -import com.mapbox.rctmgl.components.images.RCTMGLImages; -import com.mapbox.rctmgl.components.location.LocationComponentManager; -import com.mapbox.rctmgl.components.location.RCTMGLNativeUserLocation; -import com.mapbox.rctmgl.components.mapview.helpers.CameraChangeTracker; -import com.mapbox.rctmgl.components.styles.layers.RCTLayer; -import com.mapbox.rctmgl.components.styles.light.RCTMGLLight; -import com.mapbox.rctmgl.components.styles.sources.RCTMGLShapeSource; -import com.mapbox.rctmgl.components.styles.sources.RCTSource; -import com.mapbox.rctmgl.events.AndroidCallbackEvent; -import com.mapbox.rctmgl.events.IEvent; -import com.mapbox.rctmgl.events.MapChangeEvent; -import com.mapbox.rctmgl.events.MapClickEvent; -import com.mapbox.rctmgl.events.constants.EventTypes; -import com.mapbox.rctmgl.utils.BitmapUtils; -import com.mapbox.rctmgl.utils.GeoJSONUtils; -import com.mapbox.rctmgl.utils.GeoViewport; +import com.maplibre.rctmln.R; +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.annotation.RCTMLNPointAnnotation; +import com.maplibre.rctmln.components.annotation.RCTMLNMarkerView; +import com.maplibre.rctmln.components.annotation.MarkerView; +import com.maplibre.rctmln.components.annotation.MarkerViewManager; +import com.maplibre.rctmln.components.camera.RCTMLNCamera; +import com.maplibre.rctmln.components.images.RCTMLNImages; +import com.maplibre.rctmln.components.location.LocationComponentManager; +import com.maplibre.rctmln.components.location.RCTMLNNativeUserLocation; +import com.maplibre.rctmln.components.mapview.helpers.CameraChangeTracker; +import com.maplibre.rctmln.components.styles.layers.RCTLayer; +import com.maplibre.rctmln.components.styles.light.RCTMLNLight; +import com.maplibre.rctmln.components.styles.sources.RCTMLNShapeSource; +import com.maplibre.rctmln.components.styles.sources.RCTSource; +import com.maplibre.rctmln.events.AndroidCallbackEvent; +import com.maplibre.rctmln.events.IEvent; +import com.maplibre.rctmln.events.MapChangeEvent; +import com.maplibre.rctmln.events.MapClickEvent; +import com.maplibre.rctmln.events.constants.EventTypes; +import com.maplibre.rctmln.utils.BitmapUtils; +import com.maplibre.rctmln.utils.GeoJSONUtils; +import com.maplibre.rctmln.utils.GeoViewport; import java.util.ArrayList; import java.util.Arrays; @@ -85,34 +85,34 @@ import javax.annotation.Nullable; import static com.mapbox.mapboxsdk.style.layers.PropertyFactory.visibility; -import static com.mapbox.rctmgl.modules.RCTMGLOfflineModule.DEFAULT_STYLE_URL; +import static com.maplibre.rctmln.modules.RCTMLNOfflineModule.DEFAULT_STYLE_URL; /** * Created by nickitaliano on 8/18/17. */ @SuppressWarnings({ "MissingPermission" }) -public class RCTMGLMapView extends MapView implements OnMapReadyCallback, MapboxMap.OnMapClickListener, +public class RCTMLNMapView extends MapView implements OnMapReadyCallback, MapboxMap.OnMapClickListener, MapboxMap.OnMapLongClickListener, MapView.OnCameraIsChangingListener, MapView.OnCameraDidChangeListener, MapView.OnDidFailLoadingMapListener, MapView.OnDidFinishLoadingMapListener, MapView.OnWillStartRenderingFrameListener, MapView.OnDidFinishRenderingFrameListener, MapView.OnWillStartRenderingMapListener, MapView.OnDidFinishRenderingMapListener, MapView.OnDidFinishLoadingStyleListener, MapView.OnStyleImageMissingListener { - public static final String LOG_TAG = "RCTMGLMapView"; + public static final String LOG_TAG = "RCTMLNMapView"; - private RCTMGLMapViewManager mManager; + private RCTMLNMapViewManager mManager; private Context mContext; private Handler mHandler; private LifecycleEventListener mLifeCycleListener; private boolean mPaused; private boolean mDestroyed; - private RCTMGLCamera mCamera; + private RCTMLNCamera mCamera; private List mFeatures; private List mQueuedFeatures; - private Map mPointAnnotations; + private Map mPointAnnotations; private Map mSources; - private List mImages; + private List mImages; private CameraChangeTracker mCameraChangeTracker = new CameraChangeTracker(); private List> mPreRenderMethods = new ArrayList<>(); @@ -156,7 +156,7 @@ public class RCTMGLMapView extends MapView implements OnMapReadyCallback, Mapbox private @Nullable Integer mTintColor = null; - public RCTMGLMapView(Context context, RCTMGLMapViewManager manager, MapboxMapOptions options) { + public RCTMLNMapView(Context context, RCTMLNMapViewManager manager, MapboxMapOptions options) { super(context, options); mContext = context; @@ -221,23 +221,23 @@ public void addFeature(View childView, int childPosition) { RCTSource source = (RCTSource) childView; mSources.put(source.getID(), source); feature = (AbstractMapFeature) childView; - } else if (childView instanceof RCTMGLImages) { - RCTMGLImages images = (RCTMGLImages) childView; + } else if (childView instanceof RCTMLNImages) { + RCTMLNImages images = (RCTMLNImages) childView; mImages.add(images); feature = (AbstractMapFeature) childView; - } else if (childView instanceof RCTMGLLight) { + } else if (childView instanceof RCTMLNLight) { feature = (AbstractMapFeature) childView; - } else if (childView instanceof RCTMGLNativeUserLocation) { + } else if (childView instanceof RCTMLNNativeUserLocation) { feature = (AbstractMapFeature) childView; - } else if (childView instanceof RCTMGLPointAnnotation) { - RCTMGLPointAnnotation annotation = (RCTMGLPointAnnotation) childView; + } else if (childView instanceof RCTMLNPointAnnotation) { + RCTMLNPointAnnotation annotation = (RCTMLNPointAnnotation) childView; mPointAnnotations.put(annotation.getID(), annotation); feature = (AbstractMapFeature) childView; - } else if (childView instanceof RCTMGLMarkerView) { - RCTMGLMarkerView marker = (RCTMGLMarkerView) childView; + } else if (childView instanceof RCTMLNMarkerView) { + RCTMLNMarkerView marker = (RCTMLNMarkerView) childView; feature = (AbstractMapFeature) childView; - } else if (childView instanceof RCTMGLCamera) { - mCamera = (RCTMGLCamera) childView; + } else if (childView instanceof RCTMLNCamera) { + mCamera = (RCTMLNCamera) childView; feature = (AbstractMapFeature) childView; } else if (childView instanceof RCTLayer) { feature = (RCTLayer) childView; @@ -269,16 +269,16 @@ public void removeFeature(int childPosition) { if (feature instanceof RCTSource) { RCTSource source = (RCTSource) feature; mSources.remove(source.getID()); - } else if (feature instanceof RCTMGLPointAnnotation) { - RCTMGLPointAnnotation annotation = (RCTMGLPointAnnotation) feature; + } else if (feature instanceof RCTMLNPointAnnotation) { + RCTMLNPointAnnotation annotation = (RCTMLNPointAnnotation) feature; if (annotation.getMapboxID() == mActiveMarkerID) { mActiveMarkerID = -1; } mPointAnnotations.remove(annotation.getID()); - } else if (feature instanceof RCTMGLImages) { - RCTMGLImages images = (RCTMGLImages) feature; + } else if (feature instanceof RCTMLNImages) { + RCTMLNImages images = (RCTMLNImages) feature; mImages.remove(images); } @@ -358,13 +358,13 @@ public void easeCamera(CameraUpdate cameraUpdate) { mMap.easeCamera(cameraUpdate); } - public RCTMGLPointAnnotation getPointAnnotationByID(String annotationID) { + public RCTMLNPointAnnotation getPointAnnotationByID(String annotationID) { if (annotationID == null) { return null; } for (String key : mPointAnnotations.keySet()) { - RCTMGLPointAnnotation annotation = mPointAnnotations.get(key); + RCTMLNPointAnnotation annotation = mPointAnnotations.get(key); if (annotation != null && annotationID.equals(annotation.getID())) { return annotation; @@ -374,9 +374,9 @@ public RCTMGLPointAnnotation getPointAnnotationByID(String annotationID) { return null; } - public RCTMGLPointAnnotation getPointAnnotationByMarkerID(long markerID) { + public RCTMLNPointAnnotation getPointAnnotationByMarkerID(long markerID) { for (String key : mPointAnnotations.keySet()) { - RCTMGLPointAnnotation annotation = mPointAnnotations.get(key); + RCTMLNPointAnnotation annotation = mPointAnnotations.get(key); if (annotation != null && markerID == annotation.getMapboxID()) { return annotation; @@ -531,7 +531,7 @@ public boolean onAnnotationClick(Symbol symbol) { public void onAnnotationDragStarted(Symbol symbol) { mAnnotationClicked = true; final long selectedMarkerID = symbol.getId(); - RCTMGLPointAnnotation annotation = getPointAnnotationByMarkerID(selectedMarkerID); + RCTMLNPointAnnotation annotation = getPointAnnotationByMarkerID(selectedMarkerID); if (annotation != null) { annotation.onDragStart(); } @@ -540,7 +540,7 @@ public void onAnnotationDragStarted(Symbol symbol) { @Override public void onAnnotationDrag(Symbol symbol) { final long selectedMarkerID = symbol.getId(); - RCTMGLPointAnnotation annotation = getPointAnnotationByMarkerID(selectedMarkerID); + RCTMLNPointAnnotation annotation = getPointAnnotationByMarkerID(selectedMarkerID); if (annotation != null) { annotation.onDrag(); } @@ -550,7 +550,7 @@ public void onAnnotationDrag(Symbol symbol) { public void onAnnotationDragFinished(Symbol symbol) { mAnnotationClicked = false; final long selectedMarkerID = symbol.getId(); - RCTMGLPointAnnotation annotation = getPointAnnotationByMarkerID(selectedMarkerID); + RCTMLNPointAnnotation annotation = getPointAnnotationByMarkerID(selectedMarkerID); if (annotation != null) { annotation.onDragEnd(); } @@ -572,7 +572,7 @@ public void addQueuedFeatures() { } private void setupLocalization(Style style) { - mLocalizationPlugin = new LocalizationPlugin(RCTMGLMapView.this, mMap, style); + mLocalizationPlugin = new LocalizationPlugin(RCTMLNMapView.this, mMap, style); if (mLocalizeLabels) { try { mLocalizationPlugin.matchMapLanguageWithDeviceDefault(); @@ -672,11 +672,11 @@ public void onMarkerClick(@NonNull Symbol symbol) { mAnnotationClicked = true; final long selectedMarkerID = symbol.getId(); - RCTMGLPointAnnotation activeAnnotation = null; - RCTMGLPointAnnotation nextActiveAnnotation = null; + RCTMLNPointAnnotation activeAnnotation = null; + RCTMLNPointAnnotation nextActiveAnnotation = null; for (String key : mPointAnnotations.keySet()) { - RCTMGLPointAnnotation annotation = mPointAnnotations.get(key); + RCTMLNPointAnnotation annotation = mPointAnnotations.get(key); final long curMarkerID = annotation.getMapboxID(); if (mActiveMarkerID == curMarkerID) { activeAnnotation = annotation; @@ -696,12 +696,12 @@ public void onMarkerClick(@NonNull Symbol symbol) { } - public void selectAnnotation(RCTMGLPointAnnotation annotation) { + public void selectAnnotation(RCTMLNPointAnnotation annotation) { mActiveMarkerID = annotation.getMapboxID(); annotation.onSelect(true); } - public void deselectAnnotation(RCTMGLPointAnnotation annotation) { + public void deselectAnnotation(RCTMLNPointAnnotation annotation) { mActiveMarkerID = -1; annotation.onDeselect(); } @@ -767,12 +767,12 @@ public void onDidFinishLoadingStyle() { @Override public void onStyleImageMissing(@NonNull String id) { - for (RCTMGLImages images : mImages) { + for (RCTMLNImages images : mImages) { if (images.addMissingImageToStyle(id, mMap)) { return; } } - for (RCTMGLImages images : mImages) { + for (RCTMLNImages images : mImages) { images.sendImageMissingEvent(id, mMap); } } @@ -1024,7 +1024,7 @@ public void onSnapshotReady(Bitmap snapshot) { : BitmapUtils.createBase64(snapshot); payload.putString("uri", uri); - AndroidCallbackEvent event = new AndroidCallbackEvent(RCTMGLMapView.this, callbackID, payload); + AndroidCallbackEvent event = new AndroidCallbackEvent(RCTMLNMapView.this, callbackID, payload); mManager.handleEvent(event); } }); @@ -1353,14 +1353,14 @@ private List getAllTouchableSources() { return sources; } - private List getAllShapeSources() { - List shapeSources = new ArrayList<>(); + private List getAllShapeSources() { + List shapeSources = new ArrayList<>(); for (String key : mSources.keySet()) { RCTSource source = mSources.get(key); - if (source instanceof RCTMGLShapeSource) { - shapeSources.add((RCTMGLShapeSource) source); + if (source instanceof RCTMLNShapeSource) { + shapeSources.add((RCTMLNShapeSource) source); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLMapViewManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNMapViewManager.java similarity index 80% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLMapViewManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNMapViewManager.java index 3e90d253e..015ad50c3 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/RCTMGLMapViewManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/RCTMLNMapViewManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.mapview; +package com.maplibre.rctmln.components.mapview; import android.util.Log; import android.view.Gravity; @@ -14,11 +14,11 @@ import com.mapbox.mapboxsdk.geometry.LatLngBounds; import com.mapbox.mapboxsdk.log.Logger; import com.mapbox.mapboxsdk.maps.MapboxMap; -import com.mapbox.rctmgl.components.AbstractEventEmitter; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.utils.ConvertUtils; -import com.mapbox.rctmgl.utils.ExpressionParser; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.components.AbstractEventEmitter; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.utils.ConvertUtils; +import com.maplibre.rctmln.utils.ExpressionParser; +import com.maplibre.rctmln.utils.GeoJSONUtils; import com.mapbox.geojson.FeatureCollection; import com.mapbox.geojson.Point; @@ -37,13 +37,13 @@ * Created by nickitaliano on 8/18/17. */ -public class RCTMGLMapViewManager extends AbstractEventEmitter { - public static final String LOG_TAG = "RCTMGLMapViewManager"; - public static final String REACT_CLASS = "RCTMGLMapView"; +public class RCTMLNMapViewManager extends AbstractEventEmitter { + public static final String LOG_TAG = "RCTMLNMapViewManager"; + public static final String REACT_CLASS = "RCTMLNMapView"; - private Map mViews; + private Map mViews; - public RCTMGLMapViewManager(ReactApplicationContext context) { + public RCTMLNMapViewManager(ReactApplicationContext context) { super(context); mViews = new HashMap<>(); } @@ -64,7 +64,7 @@ public Class getShadowNodeClass() { } @Override - protected void onAfterUpdateTransaction(RCTMGLMapView mapView) { + protected void onAfterUpdateTransaction(RCTMLNMapView mapView) { super.onAfterUpdateTransaction(mapView); if (mapView.getMapboxMap() == null) { @@ -74,32 +74,32 @@ protected void onAfterUpdateTransaction(RCTMGLMapView mapView) { } @Override - public void addView(RCTMGLMapView mapView, View childView, int childPosition) { + public void addView(RCTMLNMapView mapView, View childView, int childPosition) { mapView.addFeature(childView, childPosition); } @Override - public int getChildCount(RCTMGLMapView mapView) { + public int getChildCount(RCTMLNMapView mapView) { return mapView.getFeatureCount(); } @Override - public View getChildAt(RCTMGLMapView mapView, int index) { + public View getChildAt(RCTMLNMapView mapView, int index) { return mapView.getFeatureAt(index); } @Override - public void removeViewAt(RCTMGLMapView mapView, int index) { + public void removeViewAt(RCTMLNMapView mapView, int index) { mapView.removeFeature(index); } @Override - protected RCTMGLMapView createViewInstance(ThemedReactContext themedReactContext) { - return new RCTMGLMapView(themedReactContext, this, null); + protected RCTMLNMapView createViewInstance(ThemedReactContext themedReactContext) { + return new RCTMLNMapView(themedReactContext, this, null); } @Override - public void onDropViewInstance(RCTMGLMapView mapView) { + public void onDropViewInstance(RCTMLNMapView mapView) { int reactTag = mapView.getId(); if (mViews.containsKey(reactTag)) { @@ -109,89 +109,89 @@ public void onDropViewInstance(RCTMGLMapView mapView) { super.onDropViewInstance(mapView); } - public RCTMGLMapView getByReactTag(int reactTag) { + public RCTMLNMapView getByReactTag(int reactTag) { return mViews.get(reactTag); } //region React Props @ReactProp(name="styleURL") - public void setStyleURL(RCTMGLMapView mapView, String styleURL) { + public void setStyleURL(RCTMLNMapView mapView, String styleURL) { mapView.setReactStyleURL(styleURL); } @ReactProp(name="preferredFramesPerSecond") - public void setPreferredFramesPerSecond(RCTMGLMapView mapView, int preferredFramesPerSecond) { + public void setPreferredFramesPerSecond(RCTMLNMapView mapView, int preferredFramesPerSecond) { mapView.setReactPreferredFramesPerSecond(preferredFramesPerSecond); } @ReactProp(name="localizeLabels") - public void setLocalizeLabels(RCTMGLMapView mapView, boolean localizeLabels) { + public void setLocalizeLabels(RCTMLNMapView mapView, boolean localizeLabels) { mapView.setLocalizeLabels(localizeLabels); } @ReactProp(name="zoomEnabled") - public void setZoomEnabled(RCTMGLMapView mapView, boolean zoomEnabled) { + public void setZoomEnabled(RCTMLNMapView mapView, boolean zoomEnabled) { mapView.setReactZoomEnabled(zoomEnabled); } @ReactProp(name="scrollEnabled") - public void setScrollEnabled(RCTMGLMapView mapView, boolean scrollEnabled) { + public void setScrollEnabled(RCTMLNMapView mapView, boolean scrollEnabled) { mapView.setReactScrollEnabled(scrollEnabled); } @ReactProp(name="pitchEnabled") - public void setPitchEnabled(RCTMGLMapView mapView, boolean pitchEnabled) { + public void setPitchEnabled(RCTMLNMapView mapView, boolean pitchEnabled) { mapView.setReactPitchEnabled(pitchEnabled); } @ReactProp(name="rotateEnabled") - public void setRotateEnabled(RCTMGLMapView mapView, boolean rotateEnabled) { + public void setRotateEnabled(RCTMLNMapView mapView, boolean rotateEnabled) { mapView.setReactRotateEnabled(rotateEnabled); } @ReactProp(name="attributionEnabled") - public void setAttributionEnabled(RCTMGLMapView mapView, boolean attributionEnabled) { + public void setAttributionEnabled(RCTMLNMapView mapView, boolean attributionEnabled) { mapView.setReactAttributionEnabled(attributionEnabled); } @ReactProp(name="attributionPosition") - public void setAttributionPosition(RCTMGLMapView mapView, @Nullable ReadableMap attributionPosition) { + public void setAttributionPosition(RCTMLNMapView mapView, @Nullable ReadableMap attributionPosition) { mapView.setReactAttributionPosition(attributionPosition); } @ReactProp(name="logoEnabled") - public void setLogoEnabled(RCTMGLMapView mapView, boolean logoEnabled) { + public void setLogoEnabled(RCTMLNMapView mapView, boolean logoEnabled) { mapView.setReactLogoEnabled(logoEnabled); } @ReactProp(name="logoPosition") - public void setLogoPosition(RCTMGLMapView mapView, ReadableMap logoPosition) { + public void setLogoPosition(RCTMLNMapView mapView, ReadableMap logoPosition) { mapView.setReactLogoPosition(logoPosition); } @ReactProp(name="compassEnabled") - public void setCompassEnabled(RCTMGLMapView mapView, boolean compassEnabled) { + public void setCompassEnabled(RCTMLNMapView mapView, boolean compassEnabled) { mapView.setReactCompassEnabled(compassEnabled); } @ReactProp(name="compassViewMargins") - public void setCompassViewMargins(RCTMGLMapView mapView, ReadableMap compassViewMargins){ + public void setCompassViewMargins(RCTMLNMapView mapView, ReadableMap compassViewMargins){ mapView.setReactCompassViewMargins(compassViewMargins); } @ReactProp(name="compassViewPosition") - public void setCompassViewPosition(RCTMGLMapView mapView, int compassViewPosition) { + public void setCompassViewPosition(RCTMLNMapView mapView, int compassViewPosition) { mapView.setReactCompassViewPosition(compassViewPosition); } @ReactProp(name="contentInset") - public void setContentInset(RCTMGLMapView mapView, ReadableArray array) { + public void setContentInset(RCTMLNMapView mapView, ReadableArray array) { mapView.setReactContentInset(array); } @ReactProp(name = "tintColor", customType = "Color") - public void setTintColor(RCTMGLMapView mapView, @Nullable Integer tintColor) { + public void setTintColor(RCTMLNMapView mapView, @Nullable Integer tintColor) { mapView.setTintColor(tintColor); } @@ -245,7 +245,7 @@ public Map getCommandsMap() { } @Override - public void receiveCommand(RCTMGLMapView mapView, int commandID, @Nullable ReadableArray args) { + public void receiveCommand(RCTMLNMapView mapView, int commandID, @Nullable ReadableArray args) { // allows method calls to work with componentDidMount MapboxMap mapboxMap = mapView.getMapboxMap(); if (mapboxMap == null) { @@ -311,9 +311,9 @@ public void receiveCommand(RCTMGLMapView mapView, int commandID, @Nullable Reada //endregion private static final class MapShadowNode extends LayoutShadowNode { - private RCTMGLMapViewManager mViewManager; + private RCTMLNMapViewManager mViewManager; - public MapShadowNode(RCTMGLMapViewManager viewManager) { + public MapShadowNode(RCTMLNMapViewManager viewManager) { mViewManager = viewManager; } @@ -328,7 +328,7 @@ public void dispose() { * onDropViewInstance. */ private void diposeNativeMapView() { - final RCTMGLMapView mapView = mViewManager.getByReactTag(getReactTag()); + final RCTMLNMapView mapView = mViewManager.getByReactTag(getReactTag()); if (mapView != null) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/helpers/CameraChangeTracker.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/helpers/CameraChangeTracker.java similarity index 94% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/helpers/CameraChangeTracker.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/helpers/CameraChangeTracker.java index f94fe2e87..ea8013969 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/mapview/helpers/CameraChangeTracker.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/mapview/helpers/CameraChangeTracker.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.mapview.helpers; +package com.maplibre.rctmln.components.mapview.helpers; import android.util.Log; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyle.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyle.java similarity index 77% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyle.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyle.java index 6c2028fa7..5c84894f0 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyle.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyle.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles; +package com.maplibre.rctmln.components.styles; import android.content.Context; import androidx.annotation.NonNull; @@ -6,8 +6,8 @@ import com.facebook.react.bridge.ReadableMap; import com.facebook.react.bridge.ReadableMapKeySetIterator; import com.mapbox.mapboxsdk.maps.MapboxMap; -import com.mapbox.rctmgl.utils.DownloadMapImageTask; -import com.mapbox.rctmgl.utils.ImageEntry; +import com.maplibre.rctmln.utils.DownloadMapImageTask; +import com.maplibre.rctmln.utils.ImageEntry; import java.util.AbstractMap; import java.util.ArrayList; @@ -18,12 +18,12 @@ * Created by nickitaliano on 9/12/17. */ -public class RCTMGLStyle { +public class RCTMLNStyle { private Context mContext; private ReadableMap mReactStyle; private MapboxMap mMap; - public RCTMGLStyle(@NonNull Context context, @NonNull ReadableMap reactStyle, @NonNull MapboxMap map) { + public RCTMLNStyle(@NonNull Context context, @NonNull ReadableMap reactStyle, @NonNull MapboxMap map) { mContext = context; mReactStyle = reactStyle; mMap = map; @@ -48,7 +48,7 @@ public List getAllStyleKeys() { return keys; } - public RCTMGLStyleValue getStyleValueForKey(String styleKey) { + public RCTMLNStyleValue getStyleValueForKey(String styleKey) { ReadableMap styleValueConfig = mReactStyle.getMap(styleKey); if (styleValueConfig == null) { @@ -56,18 +56,18 @@ public RCTMGLStyleValue getStyleValueForKey(String styleKey) { return null; } - return new RCTMGLStyleValue(styleValueConfig); + return new RCTMLNStyleValue(styleValueConfig); } - public void addImage(RCTMGLStyleValue styleValue) { + public void addImage(RCTMLNStyleValue styleValue) { addImage(styleValue, null); } - public ImageEntry imageEntry(RCTMGLStyleValue styleValue) { + public ImageEntry imageEntry(RCTMLNStyleValue styleValue) { return new ImageEntry(styleValue.getImageURI(), styleValue.getImageScale()); } - public void addImage(RCTMGLStyleValue styleValue, DownloadMapImageTask.OnAllImagesLoaded callback) { + public void addImage(RCTMLNStyleValue styleValue, DownloadMapImageTask.OnAllImagesLoaded callback) { if (!styleValue.shouldAddImage()) { if (callback != null) { callback.onAllImagesLoaded(); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleFactory.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleFactory.java similarity index 75% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleFactory.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleFactory.java index f866191de..9a38946e9 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleFactory.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleFactory.java @@ -1,7 +1,7 @@ // DO NOT MODIFY // THIS FILE IS AUTOGENERATED -package com.mapbox.rctmgl.components.styles; +package com.maplibre.rctmln.components.styles; import com.mapbox.mapboxsdk.style.layers.BackgroundLayer; import com.mapbox.mapboxsdk.style.layers.CircleLayer; @@ -17,15 +17,15 @@ import com.mapbox.mapboxsdk.style.layers.TransitionOptions; import com.mapbox.mapboxsdk.style.light.Light; import com.mapbox.mapboxsdk.style.light.Position; -import com.mapbox.rctmgl.utils.DownloadMapImageTask; +import com.maplibre.rctmln.utils.DownloadMapImageTask; import java.util.List; -public class RCTMGLStyleFactory { +public class RCTMLNStyleFactory { public static final String VALUE_KEY = "value"; public static final String SHOULD_ADD_IMAGE_KEY = "shouldAddImage"; - public static void setFillLayerStyle(final FillLayer layer, RCTMGLStyle style) { + public static void setFillLayerStyle(final FillLayer layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -33,60 +33,60 @@ public static void setFillLayerStyle(final FillLayer layer, RCTMGLStyle style) { } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "fillSortKey": - RCTMGLStyleFactory.setFillSortKey(layer, styleValue); + RCTMLNStyleFactory.setFillSortKey(layer, styleValue); break; case "visibility": - RCTMGLStyleFactory.setVisibility(layer, styleValue); + RCTMLNStyleFactory.setVisibility(layer, styleValue); break; case "fillAntialias": - RCTMGLStyleFactory.setFillAntialias(layer, styleValue); + RCTMLNStyleFactory.setFillAntialias(layer, styleValue); break; case "fillOpacity": - RCTMGLStyleFactory.setFillOpacity(layer, styleValue); + RCTMLNStyleFactory.setFillOpacity(layer, styleValue); break; case "fillOpacityTransition": - RCTMGLStyleFactory.setFillOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setFillOpacityTransition(layer, styleValue); break; case "fillColor": - RCTMGLStyleFactory.setFillColor(layer, styleValue); + RCTMLNStyleFactory.setFillColor(layer, styleValue); break; case "fillColorTransition": - RCTMGLStyleFactory.setFillColorTransition(layer, styleValue); + RCTMLNStyleFactory.setFillColorTransition(layer, styleValue); break; case "fillOutlineColor": - RCTMGLStyleFactory.setFillOutlineColor(layer, styleValue); + RCTMLNStyleFactory.setFillOutlineColor(layer, styleValue); break; case "fillOutlineColorTransition": - RCTMGLStyleFactory.setFillOutlineColorTransition(layer, styleValue); + RCTMLNStyleFactory.setFillOutlineColorTransition(layer, styleValue); break; case "fillTranslate": - RCTMGLStyleFactory.setFillTranslate(layer, styleValue); + RCTMLNStyleFactory.setFillTranslate(layer, styleValue); break; case "fillTranslateTransition": - RCTMGLStyleFactory.setFillTranslateTransition(layer, styleValue); + RCTMLNStyleFactory.setFillTranslateTransition(layer, styleValue); break; case "fillTranslateAnchor": - RCTMGLStyleFactory.setFillTranslateAnchor(layer, styleValue); + RCTMLNStyleFactory.setFillTranslateAnchor(layer, styleValue); break; case "fillPattern": style.addImage(styleValue, new DownloadMapImageTask.OnAllImagesLoaded() { @Override public void onAllImagesLoaded() { - RCTMGLStyleFactory.setFillPattern(layer, styleValue); + RCTMLNStyleFactory.setFillPattern(layer, styleValue); } }); break; case "fillPatternTransition": - RCTMGLStyleFactory.setFillPatternTransition(layer, styleValue); + RCTMLNStyleFactory.setFillPatternTransition(layer, styleValue); break; } } } - public static void setLineLayerStyle(final LineLayer layer, RCTMGLStyle style) { + public static void setLineLayerStyle(final LineLayer layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -94,96 +94,96 @@ public static void setLineLayerStyle(final LineLayer layer, RCTMGLStyle style) { } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "lineCap": - RCTMGLStyleFactory.setLineCap(layer, styleValue); + RCTMLNStyleFactory.setLineCap(layer, styleValue); break; case "lineJoin": - RCTMGLStyleFactory.setLineJoin(layer, styleValue); + RCTMLNStyleFactory.setLineJoin(layer, styleValue); break; case "lineMiterLimit": - RCTMGLStyleFactory.setLineMiterLimit(layer, styleValue); + RCTMLNStyleFactory.setLineMiterLimit(layer, styleValue); break; case "lineRoundLimit": - RCTMGLStyleFactory.setLineRoundLimit(layer, styleValue); + RCTMLNStyleFactory.setLineRoundLimit(layer, styleValue); break; case "lineSortKey": - RCTMGLStyleFactory.setLineSortKey(layer, styleValue); + RCTMLNStyleFactory.setLineSortKey(layer, styleValue); break; case "visibility": - RCTMGLStyleFactory.setVisibility(layer, styleValue); + RCTMLNStyleFactory.setVisibility(layer, styleValue); break; case "lineOpacity": - RCTMGLStyleFactory.setLineOpacity(layer, styleValue); + RCTMLNStyleFactory.setLineOpacity(layer, styleValue); break; case "lineOpacityTransition": - RCTMGLStyleFactory.setLineOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setLineOpacityTransition(layer, styleValue); break; case "lineColor": - RCTMGLStyleFactory.setLineColor(layer, styleValue); + RCTMLNStyleFactory.setLineColor(layer, styleValue); break; case "lineColorTransition": - RCTMGLStyleFactory.setLineColorTransition(layer, styleValue); + RCTMLNStyleFactory.setLineColorTransition(layer, styleValue); break; case "lineTranslate": - RCTMGLStyleFactory.setLineTranslate(layer, styleValue); + RCTMLNStyleFactory.setLineTranslate(layer, styleValue); break; case "lineTranslateTransition": - RCTMGLStyleFactory.setLineTranslateTransition(layer, styleValue); + RCTMLNStyleFactory.setLineTranslateTransition(layer, styleValue); break; case "lineTranslateAnchor": - RCTMGLStyleFactory.setLineTranslateAnchor(layer, styleValue); + RCTMLNStyleFactory.setLineTranslateAnchor(layer, styleValue); break; case "lineWidth": - RCTMGLStyleFactory.setLineWidth(layer, styleValue); + RCTMLNStyleFactory.setLineWidth(layer, styleValue); break; case "lineWidthTransition": - RCTMGLStyleFactory.setLineWidthTransition(layer, styleValue); + RCTMLNStyleFactory.setLineWidthTransition(layer, styleValue); break; case "lineGapWidth": - RCTMGLStyleFactory.setLineGapWidth(layer, styleValue); + RCTMLNStyleFactory.setLineGapWidth(layer, styleValue); break; case "lineGapWidthTransition": - RCTMGLStyleFactory.setLineGapWidthTransition(layer, styleValue); + RCTMLNStyleFactory.setLineGapWidthTransition(layer, styleValue); break; case "lineOffset": - RCTMGLStyleFactory.setLineOffset(layer, styleValue); + RCTMLNStyleFactory.setLineOffset(layer, styleValue); break; case "lineOffsetTransition": - RCTMGLStyleFactory.setLineOffsetTransition(layer, styleValue); + RCTMLNStyleFactory.setLineOffsetTransition(layer, styleValue); break; case "lineBlur": - RCTMGLStyleFactory.setLineBlur(layer, styleValue); + RCTMLNStyleFactory.setLineBlur(layer, styleValue); break; case "lineBlurTransition": - RCTMGLStyleFactory.setLineBlurTransition(layer, styleValue); + RCTMLNStyleFactory.setLineBlurTransition(layer, styleValue); break; case "lineDasharray": - RCTMGLStyleFactory.setLineDasharray(layer, styleValue); + RCTMLNStyleFactory.setLineDasharray(layer, styleValue); break; case "lineDasharrayTransition": - RCTMGLStyleFactory.setLineDasharrayTransition(layer, styleValue); + RCTMLNStyleFactory.setLineDasharrayTransition(layer, styleValue); break; case "linePattern": style.addImage(styleValue, new DownloadMapImageTask.OnAllImagesLoaded() { @Override public void onAllImagesLoaded() { - RCTMGLStyleFactory.setLinePattern(layer, styleValue); + RCTMLNStyleFactory.setLinePattern(layer, styleValue); } }); break; case "linePatternTransition": - RCTMGLStyleFactory.setLinePatternTransition(layer, styleValue); + RCTMLNStyleFactory.setLinePatternTransition(layer, styleValue); break; case "lineGradient": - RCTMGLStyleFactory.setLineGradient(layer, styleValue); + RCTMLNStyleFactory.setLineGradient(layer, styleValue); break; } } } - public static void setSymbolLayerStyle(final SymbolLayer layer, RCTMGLStyle style) { + public static void setSymbolLayerStyle(final SymbolLayer layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -191,222 +191,222 @@ public static void setSymbolLayerStyle(final SymbolLayer layer, RCTMGLStyle styl } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "symbolPlacement": - RCTMGLStyleFactory.setSymbolPlacement(layer, styleValue); + RCTMLNStyleFactory.setSymbolPlacement(layer, styleValue); break; case "symbolSpacing": - RCTMGLStyleFactory.setSymbolSpacing(layer, styleValue); + RCTMLNStyleFactory.setSymbolSpacing(layer, styleValue); break; case "symbolAvoidEdges": - RCTMGLStyleFactory.setSymbolAvoidEdges(layer, styleValue); + RCTMLNStyleFactory.setSymbolAvoidEdges(layer, styleValue); break; case "symbolSortKey": - RCTMGLStyleFactory.setSymbolSortKey(layer, styleValue); + RCTMLNStyleFactory.setSymbolSortKey(layer, styleValue); break; case "symbolZOrder": - RCTMGLStyleFactory.setSymbolZOrder(layer, styleValue); + RCTMLNStyleFactory.setSymbolZOrder(layer, styleValue); break; case "iconAllowOverlap": - RCTMGLStyleFactory.setIconAllowOverlap(layer, styleValue); + RCTMLNStyleFactory.setIconAllowOverlap(layer, styleValue); break; case "iconIgnorePlacement": - RCTMGLStyleFactory.setIconIgnorePlacement(layer, styleValue); + RCTMLNStyleFactory.setIconIgnorePlacement(layer, styleValue); break; case "iconOptional": - RCTMGLStyleFactory.setIconOptional(layer, styleValue); + RCTMLNStyleFactory.setIconOptional(layer, styleValue); break; case "iconRotationAlignment": - RCTMGLStyleFactory.setIconRotationAlignment(layer, styleValue); + RCTMLNStyleFactory.setIconRotationAlignment(layer, styleValue); break; case "iconSize": - RCTMGLStyleFactory.setIconSize(layer, styleValue); + RCTMLNStyleFactory.setIconSize(layer, styleValue); break; case "iconTextFit": - RCTMGLStyleFactory.setIconTextFit(layer, styleValue); + RCTMLNStyleFactory.setIconTextFit(layer, styleValue); break; case "iconTextFitPadding": - RCTMGLStyleFactory.setIconTextFitPadding(layer, styleValue); + RCTMLNStyleFactory.setIconTextFitPadding(layer, styleValue); break; case "iconImage": style.addImage(styleValue, new DownloadMapImageTask.OnAllImagesLoaded() { @Override public void onAllImagesLoaded() { - RCTMGLStyleFactory.setIconImage(layer, styleValue); + RCTMLNStyleFactory.setIconImage(layer, styleValue); } }); break; case "iconRotate": - RCTMGLStyleFactory.setIconRotate(layer, styleValue); + RCTMLNStyleFactory.setIconRotate(layer, styleValue); break; case "iconPadding": - RCTMGLStyleFactory.setIconPadding(layer, styleValue); + RCTMLNStyleFactory.setIconPadding(layer, styleValue); break; case "iconKeepUpright": - RCTMGLStyleFactory.setIconKeepUpright(layer, styleValue); + RCTMLNStyleFactory.setIconKeepUpright(layer, styleValue); break; case "iconOffset": - RCTMGLStyleFactory.setIconOffset(layer, styleValue); + RCTMLNStyleFactory.setIconOffset(layer, styleValue); break; case "iconAnchor": - RCTMGLStyleFactory.setIconAnchor(layer, styleValue); + RCTMLNStyleFactory.setIconAnchor(layer, styleValue); break; case "iconPitchAlignment": - RCTMGLStyleFactory.setIconPitchAlignment(layer, styleValue); + RCTMLNStyleFactory.setIconPitchAlignment(layer, styleValue); break; case "textPitchAlignment": - RCTMGLStyleFactory.setTextPitchAlignment(layer, styleValue); + RCTMLNStyleFactory.setTextPitchAlignment(layer, styleValue); break; case "textRotationAlignment": - RCTMGLStyleFactory.setTextRotationAlignment(layer, styleValue); + RCTMLNStyleFactory.setTextRotationAlignment(layer, styleValue); break; case "textField": - RCTMGLStyleFactory.setTextField(layer, styleValue); + RCTMLNStyleFactory.setTextField(layer, styleValue); break; case "textFont": - RCTMGLStyleFactory.setTextFont(layer, styleValue); + RCTMLNStyleFactory.setTextFont(layer, styleValue); break; case "textSize": - RCTMGLStyleFactory.setTextSize(layer, styleValue); + RCTMLNStyleFactory.setTextSize(layer, styleValue); break; case "textMaxWidth": - RCTMGLStyleFactory.setTextMaxWidth(layer, styleValue); + RCTMLNStyleFactory.setTextMaxWidth(layer, styleValue); break; case "textLineHeight": - RCTMGLStyleFactory.setTextLineHeight(layer, styleValue); + RCTMLNStyleFactory.setTextLineHeight(layer, styleValue); break; case "textLetterSpacing": - RCTMGLStyleFactory.setTextLetterSpacing(layer, styleValue); + RCTMLNStyleFactory.setTextLetterSpacing(layer, styleValue); break; case "textJustify": - RCTMGLStyleFactory.setTextJustify(layer, styleValue); + RCTMLNStyleFactory.setTextJustify(layer, styleValue); break; case "textRadialOffset": - RCTMGLStyleFactory.setTextRadialOffset(layer, styleValue); + RCTMLNStyleFactory.setTextRadialOffset(layer, styleValue); break; case "textVariableAnchor": - RCTMGLStyleFactory.setTextVariableAnchor(layer, styleValue); + RCTMLNStyleFactory.setTextVariableAnchor(layer, styleValue); break; case "textAnchor": - RCTMGLStyleFactory.setTextAnchor(layer, styleValue); + RCTMLNStyleFactory.setTextAnchor(layer, styleValue); break; case "textMaxAngle": - RCTMGLStyleFactory.setTextMaxAngle(layer, styleValue); + RCTMLNStyleFactory.setTextMaxAngle(layer, styleValue); break; case "textWritingMode": - RCTMGLStyleFactory.setTextWritingMode(layer, styleValue); + RCTMLNStyleFactory.setTextWritingMode(layer, styleValue); break; case "textRotate": - RCTMGLStyleFactory.setTextRotate(layer, styleValue); + RCTMLNStyleFactory.setTextRotate(layer, styleValue); break; case "textPadding": - RCTMGLStyleFactory.setTextPadding(layer, styleValue); + RCTMLNStyleFactory.setTextPadding(layer, styleValue); break; case "textKeepUpright": - RCTMGLStyleFactory.setTextKeepUpright(layer, styleValue); + RCTMLNStyleFactory.setTextKeepUpright(layer, styleValue); break; case "textTransform": - RCTMGLStyleFactory.setTextTransform(layer, styleValue); + RCTMLNStyleFactory.setTextTransform(layer, styleValue); break; case "textOffset": - RCTMGLStyleFactory.setTextOffset(layer, styleValue); + RCTMLNStyleFactory.setTextOffset(layer, styleValue); break; case "textAllowOverlap": - RCTMGLStyleFactory.setTextAllowOverlap(layer, styleValue); + RCTMLNStyleFactory.setTextAllowOverlap(layer, styleValue); break; case "textIgnorePlacement": - RCTMGLStyleFactory.setTextIgnorePlacement(layer, styleValue); + RCTMLNStyleFactory.setTextIgnorePlacement(layer, styleValue); break; case "textOptional": - RCTMGLStyleFactory.setTextOptional(layer, styleValue); + RCTMLNStyleFactory.setTextOptional(layer, styleValue); break; case "visibility": - RCTMGLStyleFactory.setVisibility(layer, styleValue); + RCTMLNStyleFactory.setVisibility(layer, styleValue); break; case "iconOpacity": - RCTMGLStyleFactory.setIconOpacity(layer, styleValue); + RCTMLNStyleFactory.setIconOpacity(layer, styleValue); break; case "iconOpacityTransition": - RCTMGLStyleFactory.setIconOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setIconOpacityTransition(layer, styleValue); break; case "iconColor": - RCTMGLStyleFactory.setIconColor(layer, styleValue); + RCTMLNStyleFactory.setIconColor(layer, styleValue); break; case "iconColorTransition": - RCTMGLStyleFactory.setIconColorTransition(layer, styleValue); + RCTMLNStyleFactory.setIconColorTransition(layer, styleValue); break; case "iconHaloColor": - RCTMGLStyleFactory.setIconHaloColor(layer, styleValue); + RCTMLNStyleFactory.setIconHaloColor(layer, styleValue); break; case "iconHaloColorTransition": - RCTMGLStyleFactory.setIconHaloColorTransition(layer, styleValue); + RCTMLNStyleFactory.setIconHaloColorTransition(layer, styleValue); break; case "iconHaloWidth": - RCTMGLStyleFactory.setIconHaloWidth(layer, styleValue); + RCTMLNStyleFactory.setIconHaloWidth(layer, styleValue); break; case "iconHaloWidthTransition": - RCTMGLStyleFactory.setIconHaloWidthTransition(layer, styleValue); + RCTMLNStyleFactory.setIconHaloWidthTransition(layer, styleValue); break; case "iconHaloBlur": - RCTMGLStyleFactory.setIconHaloBlur(layer, styleValue); + RCTMLNStyleFactory.setIconHaloBlur(layer, styleValue); break; case "iconHaloBlurTransition": - RCTMGLStyleFactory.setIconHaloBlurTransition(layer, styleValue); + RCTMLNStyleFactory.setIconHaloBlurTransition(layer, styleValue); break; case "iconTranslate": - RCTMGLStyleFactory.setIconTranslate(layer, styleValue); + RCTMLNStyleFactory.setIconTranslate(layer, styleValue); break; case "iconTranslateTransition": - RCTMGLStyleFactory.setIconTranslateTransition(layer, styleValue); + RCTMLNStyleFactory.setIconTranslateTransition(layer, styleValue); break; case "iconTranslateAnchor": - RCTMGLStyleFactory.setIconTranslateAnchor(layer, styleValue); + RCTMLNStyleFactory.setIconTranslateAnchor(layer, styleValue); break; case "textOpacity": - RCTMGLStyleFactory.setTextOpacity(layer, styleValue); + RCTMLNStyleFactory.setTextOpacity(layer, styleValue); break; case "textOpacityTransition": - RCTMGLStyleFactory.setTextOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setTextOpacityTransition(layer, styleValue); break; case "textColor": - RCTMGLStyleFactory.setTextColor(layer, styleValue); + RCTMLNStyleFactory.setTextColor(layer, styleValue); break; case "textColorTransition": - RCTMGLStyleFactory.setTextColorTransition(layer, styleValue); + RCTMLNStyleFactory.setTextColorTransition(layer, styleValue); break; case "textHaloColor": - RCTMGLStyleFactory.setTextHaloColor(layer, styleValue); + RCTMLNStyleFactory.setTextHaloColor(layer, styleValue); break; case "textHaloColorTransition": - RCTMGLStyleFactory.setTextHaloColorTransition(layer, styleValue); + RCTMLNStyleFactory.setTextHaloColorTransition(layer, styleValue); break; case "textHaloWidth": - RCTMGLStyleFactory.setTextHaloWidth(layer, styleValue); + RCTMLNStyleFactory.setTextHaloWidth(layer, styleValue); break; case "textHaloWidthTransition": - RCTMGLStyleFactory.setTextHaloWidthTransition(layer, styleValue); + RCTMLNStyleFactory.setTextHaloWidthTransition(layer, styleValue); break; case "textHaloBlur": - RCTMGLStyleFactory.setTextHaloBlur(layer, styleValue); + RCTMLNStyleFactory.setTextHaloBlur(layer, styleValue); break; case "textHaloBlurTransition": - RCTMGLStyleFactory.setTextHaloBlurTransition(layer, styleValue); + RCTMLNStyleFactory.setTextHaloBlurTransition(layer, styleValue); break; case "textTranslate": - RCTMGLStyleFactory.setTextTranslate(layer, styleValue); + RCTMLNStyleFactory.setTextTranslate(layer, styleValue); break; case "textTranslateTransition": - RCTMGLStyleFactory.setTextTranslateTransition(layer, styleValue); + RCTMLNStyleFactory.setTextTranslateTransition(layer, styleValue); break; case "textTranslateAnchor": - RCTMGLStyleFactory.setTextTranslateAnchor(layer, styleValue); + RCTMLNStyleFactory.setTextTranslateAnchor(layer, styleValue); break; } } } - public static void setCircleLayerStyle(final CircleLayer layer, RCTMGLStyle style) { + public static void setCircleLayerStyle(final CircleLayer layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -414,76 +414,76 @@ public static void setCircleLayerStyle(final CircleLayer layer, RCTMGLStyle styl } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "circleSortKey": - RCTMGLStyleFactory.setCircleSortKey(layer, styleValue); + RCTMLNStyleFactory.setCircleSortKey(layer, styleValue); break; case "visibility": - RCTMGLStyleFactory.setVisibility(layer, styleValue); + RCTMLNStyleFactory.setVisibility(layer, styleValue); break; case "circleRadius": - RCTMGLStyleFactory.setCircleRadius(layer, styleValue); + RCTMLNStyleFactory.setCircleRadius(layer, styleValue); break; case "circleRadiusTransition": - RCTMGLStyleFactory.setCircleRadiusTransition(layer, styleValue); + RCTMLNStyleFactory.setCircleRadiusTransition(layer, styleValue); break; case "circleColor": - RCTMGLStyleFactory.setCircleColor(layer, styleValue); + RCTMLNStyleFactory.setCircleColor(layer, styleValue); break; case "circleColorTransition": - RCTMGLStyleFactory.setCircleColorTransition(layer, styleValue); + RCTMLNStyleFactory.setCircleColorTransition(layer, styleValue); break; case "circleBlur": - RCTMGLStyleFactory.setCircleBlur(layer, styleValue); + RCTMLNStyleFactory.setCircleBlur(layer, styleValue); break; case "circleBlurTransition": - RCTMGLStyleFactory.setCircleBlurTransition(layer, styleValue); + RCTMLNStyleFactory.setCircleBlurTransition(layer, styleValue); break; case "circleOpacity": - RCTMGLStyleFactory.setCircleOpacity(layer, styleValue); + RCTMLNStyleFactory.setCircleOpacity(layer, styleValue); break; case "circleOpacityTransition": - RCTMGLStyleFactory.setCircleOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setCircleOpacityTransition(layer, styleValue); break; case "circleTranslate": - RCTMGLStyleFactory.setCircleTranslate(layer, styleValue); + RCTMLNStyleFactory.setCircleTranslate(layer, styleValue); break; case "circleTranslateTransition": - RCTMGLStyleFactory.setCircleTranslateTransition(layer, styleValue); + RCTMLNStyleFactory.setCircleTranslateTransition(layer, styleValue); break; case "circleTranslateAnchor": - RCTMGLStyleFactory.setCircleTranslateAnchor(layer, styleValue); + RCTMLNStyleFactory.setCircleTranslateAnchor(layer, styleValue); break; case "circlePitchScale": - RCTMGLStyleFactory.setCirclePitchScale(layer, styleValue); + RCTMLNStyleFactory.setCirclePitchScale(layer, styleValue); break; case "circlePitchAlignment": - RCTMGLStyleFactory.setCirclePitchAlignment(layer, styleValue); + RCTMLNStyleFactory.setCirclePitchAlignment(layer, styleValue); break; case "circleStrokeWidth": - RCTMGLStyleFactory.setCircleStrokeWidth(layer, styleValue); + RCTMLNStyleFactory.setCircleStrokeWidth(layer, styleValue); break; case "circleStrokeWidthTransition": - RCTMGLStyleFactory.setCircleStrokeWidthTransition(layer, styleValue); + RCTMLNStyleFactory.setCircleStrokeWidthTransition(layer, styleValue); break; case "circleStrokeColor": - RCTMGLStyleFactory.setCircleStrokeColor(layer, styleValue); + RCTMLNStyleFactory.setCircleStrokeColor(layer, styleValue); break; case "circleStrokeColorTransition": - RCTMGLStyleFactory.setCircleStrokeColorTransition(layer, styleValue); + RCTMLNStyleFactory.setCircleStrokeColorTransition(layer, styleValue); break; case "circleStrokeOpacity": - RCTMGLStyleFactory.setCircleStrokeOpacity(layer, styleValue); + RCTMLNStyleFactory.setCircleStrokeOpacity(layer, styleValue); break; case "circleStrokeOpacityTransition": - RCTMGLStyleFactory.setCircleStrokeOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setCircleStrokeOpacityTransition(layer, styleValue); break; } } } - public static void setHeatmapLayerStyle(final HeatmapLayer layer, RCTMGLStyle style) { + public static void setHeatmapLayerStyle(final HeatmapLayer layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -491,40 +491,40 @@ public static void setHeatmapLayerStyle(final HeatmapLayer layer, RCTMGLStyle st } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "visibility": - RCTMGLStyleFactory.setVisibility(layer, styleValue); + RCTMLNStyleFactory.setVisibility(layer, styleValue); break; case "heatmapRadius": - RCTMGLStyleFactory.setHeatmapRadius(layer, styleValue); + RCTMLNStyleFactory.setHeatmapRadius(layer, styleValue); break; case "heatmapRadiusTransition": - RCTMGLStyleFactory.setHeatmapRadiusTransition(layer, styleValue); + RCTMLNStyleFactory.setHeatmapRadiusTransition(layer, styleValue); break; case "heatmapWeight": - RCTMGLStyleFactory.setHeatmapWeight(layer, styleValue); + RCTMLNStyleFactory.setHeatmapWeight(layer, styleValue); break; case "heatmapIntensity": - RCTMGLStyleFactory.setHeatmapIntensity(layer, styleValue); + RCTMLNStyleFactory.setHeatmapIntensity(layer, styleValue); break; case "heatmapIntensityTransition": - RCTMGLStyleFactory.setHeatmapIntensityTransition(layer, styleValue); + RCTMLNStyleFactory.setHeatmapIntensityTransition(layer, styleValue); break; case "heatmapColor": - RCTMGLStyleFactory.setHeatmapColor(layer, styleValue); + RCTMLNStyleFactory.setHeatmapColor(layer, styleValue); break; case "heatmapOpacity": - RCTMGLStyleFactory.setHeatmapOpacity(layer, styleValue); + RCTMLNStyleFactory.setHeatmapOpacity(layer, styleValue); break; case "heatmapOpacityTransition": - RCTMGLStyleFactory.setHeatmapOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setHeatmapOpacityTransition(layer, styleValue); break; } } } - public static void setFillExtrusionLayerStyle(final FillExtrusionLayer layer, RCTMGLStyle style) { + public static void setFillExtrusionLayerStyle(final FillExtrusionLayer layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -532,60 +532,60 @@ public static void setFillExtrusionLayerStyle(final FillExtrusionLayer layer, RC } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "visibility": - RCTMGLStyleFactory.setVisibility(layer, styleValue); + RCTMLNStyleFactory.setVisibility(layer, styleValue); break; case "fillExtrusionOpacity": - RCTMGLStyleFactory.setFillExtrusionOpacity(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionOpacity(layer, styleValue); break; case "fillExtrusionOpacityTransition": - RCTMGLStyleFactory.setFillExtrusionOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionOpacityTransition(layer, styleValue); break; case "fillExtrusionColor": - RCTMGLStyleFactory.setFillExtrusionColor(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionColor(layer, styleValue); break; case "fillExtrusionColorTransition": - RCTMGLStyleFactory.setFillExtrusionColorTransition(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionColorTransition(layer, styleValue); break; case "fillExtrusionTranslate": - RCTMGLStyleFactory.setFillExtrusionTranslate(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionTranslate(layer, styleValue); break; case "fillExtrusionTranslateTransition": - RCTMGLStyleFactory.setFillExtrusionTranslateTransition(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionTranslateTransition(layer, styleValue); break; case "fillExtrusionTranslateAnchor": - RCTMGLStyleFactory.setFillExtrusionTranslateAnchor(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionTranslateAnchor(layer, styleValue); break; case "fillExtrusionPattern": style.addImage(styleValue, new DownloadMapImageTask.OnAllImagesLoaded() { @Override public void onAllImagesLoaded() { - RCTMGLStyleFactory.setFillExtrusionPattern(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionPattern(layer, styleValue); } }); break; case "fillExtrusionPatternTransition": - RCTMGLStyleFactory.setFillExtrusionPatternTransition(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionPatternTransition(layer, styleValue); break; case "fillExtrusionHeight": - RCTMGLStyleFactory.setFillExtrusionHeight(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionHeight(layer, styleValue); break; case "fillExtrusionHeightTransition": - RCTMGLStyleFactory.setFillExtrusionHeightTransition(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionHeightTransition(layer, styleValue); break; case "fillExtrusionBase": - RCTMGLStyleFactory.setFillExtrusionBase(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionBase(layer, styleValue); break; case "fillExtrusionBaseTransition": - RCTMGLStyleFactory.setFillExtrusionBaseTransition(layer, styleValue); + RCTMLNStyleFactory.setFillExtrusionBaseTransition(layer, styleValue); break; } } } - public static void setRasterLayerStyle(final RasterLayer layer, RCTMGLStyle style) { + public static void setRasterLayerStyle(final RasterLayer layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -593,58 +593,58 @@ public static void setRasterLayerStyle(final RasterLayer layer, RCTMGLStyle styl } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "visibility": - RCTMGLStyleFactory.setVisibility(layer, styleValue); + RCTMLNStyleFactory.setVisibility(layer, styleValue); break; case "rasterOpacity": - RCTMGLStyleFactory.setRasterOpacity(layer, styleValue); + RCTMLNStyleFactory.setRasterOpacity(layer, styleValue); break; case "rasterOpacityTransition": - RCTMGLStyleFactory.setRasterOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setRasterOpacityTransition(layer, styleValue); break; case "rasterHueRotate": - RCTMGLStyleFactory.setRasterHueRotate(layer, styleValue); + RCTMLNStyleFactory.setRasterHueRotate(layer, styleValue); break; case "rasterHueRotateTransition": - RCTMGLStyleFactory.setRasterHueRotateTransition(layer, styleValue); + RCTMLNStyleFactory.setRasterHueRotateTransition(layer, styleValue); break; case "rasterBrightnessMin": - RCTMGLStyleFactory.setRasterBrightnessMin(layer, styleValue); + RCTMLNStyleFactory.setRasterBrightnessMin(layer, styleValue); break; case "rasterBrightnessMinTransition": - RCTMGLStyleFactory.setRasterBrightnessMinTransition(layer, styleValue); + RCTMLNStyleFactory.setRasterBrightnessMinTransition(layer, styleValue); break; case "rasterBrightnessMax": - RCTMGLStyleFactory.setRasterBrightnessMax(layer, styleValue); + RCTMLNStyleFactory.setRasterBrightnessMax(layer, styleValue); break; case "rasterBrightnessMaxTransition": - RCTMGLStyleFactory.setRasterBrightnessMaxTransition(layer, styleValue); + RCTMLNStyleFactory.setRasterBrightnessMaxTransition(layer, styleValue); break; case "rasterSaturation": - RCTMGLStyleFactory.setRasterSaturation(layer, styleValue); + RCTMLNStyleFactory.setRasterSaturation(layer, styleValue); break; case "rasterSaturationTransition": - RCTMGLStyleFactory.setRasterSaturationTransition(layer, styleValue); + RCTMLNStyleFactory.setRasterSaturationTransition(layer, styleValue); break; case "rasterContrast": - RCTMGLStyleFactory.setRasterContrast(layer, styleValue); + RCTMLNStyleFactory.setRasterContrast(layer, styleValue); break; case "rasterContrastTransition": - RCTMGLStyleFactory.setRasterContrastTransition(layer, styleValue); + RCTMLNStyleFactory.setRasterContrastTransition(layer, styleValue); break; case "rasterResampling": - RCTMGLStyleFactory.setRasterResampling(layer, styleValue); + RCTMLNStyleFactory.setRasterResampling(layer, styleValue); break; case "rasterFadeDuration": - RCTMGLStyleFactory.setRasterFadeDuration(layer, styleValue); + RCTMLNStyleFactory.setRasterFadeDuration(layer, styleValue); break; } } } - public static void setHillshadeLayerStyle(final HillshadeLayer layer, RCTMGLStyle style) { + public static void setHillshadeLayerStyle(final HillshadeLayer layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -652,46 +652,46 @@ public static void setHillshadeLayerStyle(final HillshadeLayer layer, RCTMGLStyl } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "visibility": - RCTMGLStyleFactory.setVisibility(layer, styleValue); + RCTMLNStyleFactory.setVisibility(layer, styleValue); break; case "hillshadeIlluminationDirection": - RCTMGLStyleFactory.setHillshadeIlluminationDirection(layer, styleValue); + RCTMLNStyleFactory.setHillshadeIlluminationDirection(layer, styleValue); break; case "hillshadeIlluminationAnchor": - RCTMGLStyleFactory.setHillshadeIlluminationAnchor(layer, styleValue); + RCTMLNStyleFactory.setHillshadeIlluminationAnchor(layer, styleValue); break; case "hillshadeExaggeration": - RCTMGLStyleFactory.setHillshadeExaggeration(layer, styleValue); + RCTMLNStyleFactory.setHillshadeExaggeration(layer, styleValue); break; case "hillshadeExaggerationTransition": - RCTMGLStyleFactory.setHillshadeExaggerationTransition(layer, styleValue); + RCTMLNStyleFactory.setHillshadeExaggerationTransition(layer, styleValue); break; case "hillshadeShadowColor": - RCTMGLStyleFactory.setHillshadeShadowColor(layer, styleValue); + RCTMLNStyleFactory.setHillshadeShadowColor(layer, styleValue); break; case "hillshadeShadowColorTransition": - RCTMGLStyleFactory.setHillshadeShadowColorTransition(layer, styleValue); + RCTMLNStyleFactory.setHillshadeShadowColorTransition(layer, styleValue); break; case "hillshadeHighlightColor": - RCTMGLStyleFactory.setHillshadeHighlightColor(layer, styleValue); + RCTMLNStyleFactory.setHillshadeHighlightColor(layer, styleValue); break; case "hillshadeHighlightColorTransition": - RCTMGLStyleFactory.setHillshadeHighlightColorTransition(layer, styleValue); + RCTMLNStyleFactory.setHillshadeHighlightColorTransition(layer, styleValue); break; case "hillshadeAccentColor": - RCTMGLStyleFactory.setHillshadeAccentColor(layer, styleValue); + RCTMLNStyleFactory.setHillshadeAccentColor(layer, styleValue); break; case "hillshadeAccentColorTransition": - RCTMGLStyleFactory.setHillshadeAccentColorTransition(layer, styleValue); + RCTMLNStyleFactory.setHillshadeAccentColorTransition(layer, styleValue); break; } } } - public static void setBackgroundLayerStyle(final BackgroundLayer layer, RCTMGLStyle style) { + public static void setBackgroundLayerStyle(final BackgroundLayer layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -699,39 +699,39 @@ public static void setBackgroundLayerStyle(final BackgroundLayer layer, RCTMGLSt } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "visibility": - RCTMGLStyleFactory.setVisibility(layer, styleValue); + RCTMLNStyleFactory.setVisibility(layer, styleValue); break; case "backgroundColor": - RCTMGLStyleFactory.setBackgroundColor(layer, styleValue); + RCTMLNStyleFactory.setBackgroundColor(layer, styleValue); break; case "backgroundColorTransition": - RCTMGLStyleFactory.setBackgroundColorTransition(layer, styleValue); + RCTMLNStyleFactory.setBackgroundColorTransition(layer, styleValue); break; case "backgroundPattern": style.addImage(styleValue, new DownloadMapImageTask.OnAllImagesLoaded() { @Override public void onAllImagesLoaded() { - RCTMGLStyleFactory.setBackgroundPattern(layer, styleValue); + RCTMLNStyleFactory.setBackgroundPattern(layer, styleValue); } }); break; case "backgroundPatternTransition": - RCTMGLStyleFactory.setBackgroundPatternTransition(layer, styleValue); + RCTMLNStyleFactory.setBackgroundPatternTransition(layer, styleValue); break; case "backgroundOpacity": - RCTMGLStyleFactory.setBackgroundOpacity(layer, styleValue); + RCTMLNStyleFactory.setBackgroundOpacity(layer, styleValue); break; case "backgroundOpacityTransition": - RCTMGLStyleFactory.setBackgroundOpacityTransition(layer, styleValue); + RCTMLNStyleFactory.setBackgroundOpacityTransition(layer, styleValue); break; } } } - public static void setLightLayerStyle(final Light layer, RCTMGLStyle style) { + public static void setLightLayerStyle(final Light layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -739,35 +739,35 @@ public static void setLightLayerStyle(final Light layer, RCTMGLStyle style) { } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { case "anchor": - RCTMGLStyleFactory.setAnchor(layer, styleValue); + RCTMLNStyleFactory.setAnchor(layer, styleValue); break; case "position": - RCTMGLStyleFactory.setPosition(layer, styleValue); + RCTMLNStyleFactory.setPosition(layer, styleValue); break; case "positionTransition": - RCTMGLStyleFactory.setPositionTransition(layer, styleValue); + RCTMLNStyleFactory.setPositionTransition(layer, styleValue); break; case "color": - RCTMGLStyleFactory.setColor(layer, styleValue); + RCTMLNStyleFactory.setColor(layer, styleValue); break; case "colorTransition": - RCTMGLStyleFactory.setColorTransition(layer, styleValue); + RCTMLNStyleFactory.setColorTransition(layer, styleValue); break; case "intensity": - RCTMGLStyleFactory.setIntensity(layer, styleValue); + RCTMLNStyleFactory.setIntensity(layer, styleValue); break; case "intensityTransition": - RCTMGLStyleFactory.setIntensityTransition(layer, styleValue); + RCTMLNStyleFactory.setIntensityTransition(layer, styleValue); break; } } } - public static void setFillSortKey(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillSortKey(FillLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillSortKey(styleValue.getExpression())); } else { @@ -775,11 +775,11 @@ public static void setFillSortKey(FillLayer layer, RCTMGLStyleValue styleValue) } } - public static void setVisibility(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setVisibility(FillLayer layer, RCTMLNStyleValue styleValue) { layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY))); } - public static void setFillAntialias(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillAntialias(FillLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillAntialias(styleValue.getExpression())); } else { @@ -787,7 +787,7 @@ public static void setFillAntialias(FillLayer layer, RCTMGLStyleValue styleValue } } - public static void setFillOpacity(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillOpacity(FillLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillOpacity(styleValue.getExpression())); } else { @@ -796,14 +796,14 @@ public static void setFillOpacity(FillLayer layer, RCTMGLStyleValue styleValue) } - public static void setFillOpacityTransition(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillOpacityTransition(FillLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillOpacityTransition(transition); } } - public static void setFillColor(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillColor(FillLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillColor(styleValue.getExpression())); } else { @@ -812,14 +812,14 @@ public static void setFillColor(FillLayer layer, RCTMGLStyleValue styleValue) { } - public static void setFillColorTransition(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillColorTransition(FillLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillColorTransition(transition); } } - public static void setFillOutlineColor(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillOutlineColor(FillLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillOutlineColor(styleValue.getExpression())); } else { @@ -828,14 +828,14 @@ public static void setFillOutlineColor(FillLayer layer, RCTMGLStyleValue styleVa } - public static void setFillOutlineColorTransition(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillOutlineColorTransition(FillLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillOutlineColorTransition(transition); } } - public static void setFillTranslate(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillTranslate(FillLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillTranslate(styleValue.getExpression())); } else { @@ -844,14 +844,14 @@ public static void setFillTranslate(FillLayer layer, RCTMGLStyleValue styleValue } - public static void setFillTranslateTransition(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillTranslateTransition(FillLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillTranslateTransition(transition); } } - public static void setFillTranslateAnchor(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillTranslateAnchor(FillLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillTranslateAnchor(styleValue.getExpression())); } else { @@ -859,7 +859,7 @@ public static void setFillTranslateAnchor(FillLayer layer, RCTMGLStyleValue styl } } - public static void setFillPattern(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillPattern(FillLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { if (styleValue.isImageStringValue()) { layer.setProperties(PropertyFactory.fillPattern(styleValue.getImageStringValue())); @@ -872,14 +872,14 @@ public static void setFillPattern(FillLayer layer, RCTMGLStyleValue styleValue) } - public static void setFillPatternTransition(FillLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillPatternTransition(FillLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillPatternTransition(transition); } } - public static void setLineCap(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineCap(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineCap(styleValue.getExpression())); } else { @@ -887,7 +887,7 @@ public static void setLineCap(LineLayer layer, RCTMGLStyleValue styleValue) { } } - public static void setLineJoin(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineJoin(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineJoin(styleValue.getExpression())); } else { @@ -895,7 +895,7 @@ public static void setLineJoin(LineLayer layer, RCTMGLStyleValue styleValue) { } } - public static void setLineMiterLimit(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineMiterLimit(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineMiterLimit(styleValue.getExpression())); } else { @@ -903,7 +903,7 @@ public static void setLineMiterLimit(LineLayer layer, RCTMGLStyleValue styleValu } } - public static void setLineRoundLimit(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineRoundLimit(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineRoundLimit(styleValue.getExpression())); } else { @@ -911,7 +911,7 @@ public static void setLineRoundLimit(LineLayer layer, RCTMGLStyleValue styleValu } } - public static void setLineSortKey(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineSortKey(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineSortKey(styleValue.getExpression())); } else { @@ -919,11 +919,11 @@ public static void setLineSortKey(LineLayer layer, RCTMGLStyleValue styleValue) } } - public static void setVisibility(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setVisibility(LineLayer layer, RCTMLNStyleValue styleValue) { layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY))); } - public static void setLineOpacity(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineOpacity(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineOpacity(styleValue.getExpression())); } else { @@ -932,14 +932,14 @@ public static void setLineOpacity(LineLayer layer, RCTMGLStyleValue styleValue) } - public static void setLineOpacityTransition(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineOpacityTransition(LineLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setLineOpacityTransition(transition); } } - public static void setLineColor(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineColor(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineColor(styleValue.getExpression())); } else { @@ -948,14 +948,14 @@ public static void setLineColor(LineLayer layer, RCTMGLStyleValue styleValue) { } - public static void setLineColorTransition(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineColorTransition(LineLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setLineColorTransition(transition); } } - public static void setLineTranslate(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineTranslate(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineTranslate(styleValue.getExpression())); } else { @@ -964,14 +964,14 @@ public static void setLineTranslate(LineLayer layer, RCTMGLStyleValue styleValue } - public static void setLineTranslateTransition(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineTranslateTransition(LineLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setLineTranslateTransition(transition); } } - public static void setLineTranslateAnchor(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineTranslateAnchor(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineTranslateAnchor(styleValue.getExpression())); } else { @@ -979,7 +979,7 @@ public static void setLineTranslateAnchor(LineLayer layer, RCTMGLStyleValue styl } } - public static void setLineWidth(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineWidth(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineWidth(styleValue.getExpression())); } else { @@ -988,14 +988,14 @@ public static void setLineWidth(LineLayer layer, RCTMGLStyleValue styleValue) { } - public static void setLineWidthTransition(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineWidthTransition(LineLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setLineWidthTransition(transition); } } - public static void setLineGapWidth(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineGapWidth(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineGapWidth(styleValue.getExpression())); } else { @@ -1004,14 +1004,14 @@ public static void setLineGapWidth(LineLayer layer, RCTMGLStyleValue styleValue) } - public static void setLineGapWidthTransition(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineGapWidthTransition(LineLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setLineGapWidthTransition(transition); } } - public static void setLineOffset(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineOffset(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineOffset(styleValue.getExpression())); } else { @@ -1020,14 +1020,14 @@ public static void setLineOffset(LineLayer layer, RCTMGLStyleValue styleValue) { } - public static void setLineOffsetTransition(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineOffsetTransition(LineLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setLineOffsetTransition(transition); } } - public static void setLineBlur(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineBlur(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineBlur(styleValue.getExpression())); } else { @@ -1036,14 +1036,14 @@ public static void setLineBlur(LineLayer layer, RCTMGLStyleValue styleValue) { } - public static void setLineBlurTransition(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineBlurTransition(LineLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setLineBlurTransition(transition); } } - public static void setLineDasharray(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineDasharray(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineDasharray(styleValue.getExpression())); } else { @@ -1052,14 +1052,14 @@ public static void setLineDasharray(LineLayer layer, RCTMGLStyleValue styleValue } - public static void setLineDasharrayTransition(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineDasharrayTransition(LineLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setLineDasharrayTransition(transition); } } - public static void setLinePattern(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLinePattern(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { if (styleValue.isImageStringValue()) { layer.setProperties(PropertyFactory.linePattern(styleValue.getImageStringValue())); @@ -1072,14 +1072,14 @@ public static void setLinePattern(LineLayer layer, RCTMGLStyleValue styleValue) } - public static void setLinePatternTransition(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLinePatternTransition(LineLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setLinePatternTransition(transition); } } - public static void setLineGradient(LineLayer layer, RCTMGLStyleValue styleValue) { + public static void setLineGradient(LineLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.lineGradient(styleValue.getExpression())); } else { @@ -1087,7 +1087,7 @@ public static void setLineGradient(LineLayer layer, RCTMGLStyleValue styleValue) } } - public static void setSymbolPlacement(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setSymbolPlacement(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.symbolPlacement(styleValue.getExpression())); } else { @@ -1095,7 +1095,7 @@ public static void setSymbolPlacement(SymbolLayer layer, RCTMGLStyleValue styleV } } - public static void setSymbolSpacing(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setSymbolSpacing(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.symbolSpacing(styleValue.getExpression())); } else { @@ -1103,7 +1103,7 @@ public static void setSymbolSpacing(SymbolLayer layer, RCTMGLStyleValue styleVal } } - public static void setSymbolAvoidEdges(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setSymbolAvoidEdges(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.symbolAvoidEdges(styleValue.getExpression())); } else { @@ -1111,7 +1111,7 @@ public static void setSymbolAvoidEdges(SymbolLayer layer, RCTMGLStyleValue style } } - public static void setSymbolSortKey(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setSymbolSortKey(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.symbolSortKey(styleValue.getExpression())); } else { @@ -1119,7 +1119,7 @@ public static void setSymbolSortKey(SymbolLayer layer, RCTMGLStyleValue styleVal } } - public static void setSymbolZOrder(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setSymbolZOrder(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.symbolZOrder(styleValue.getExpression())); } else { @@ -1127,7 +1127,7 @@ public static void setSymbolZOrder(SymbolLayer layer, RCTMGLStyleValue styleValu } } - public static void setIconAllowOverlap(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconAllowOverlap(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconAllowOverlap(styleValue.getExpression())); } else { @@ -1135,7 +1135,7 @@ public static void setIconAllowOverlap(SymbolLayer layer, RCTMGLStyleValue style } } - public static void setIconIgnorePlacement(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconIgnorePlacement(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconIgnorePlacement(styleValue.getExpression())); } else { @@ -1143,7 +1143,7 @@ public static void setIconIgnorePlacement(SymbolLayer layer, RCTMGLStyleValue st } } - public static void setIconOptional(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconOptional(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconOptional(styleValue.getExpression())); } else { @@ -1151,7 +1151,7 @@ public static void setIconOptional(SymbolLayer layer, RCTMGLStyleValue styleValu } } - public static void setIconRotationAlignment(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconRotationAlignment(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconRotationAlignment(styleValue.getExpression())); } else { @@ -1159,7 +1159,7 @@ public static void setIconRotationAlignment(SymbolLayer layer, RCTMGLStyleValue } } - public static void setIconSize(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconSize(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconSize(styleValue.getExpression())); } else { @@ -1167,7 +1167,7 @@ public static void setIconSize(SymbolLayer layer, RCTMGLStyleValue styleValue) { } } - public static void setIconTextFit(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconTextFit(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconTextFit(styleValue.getExpression())); } else { @@ -1175,7 +1175,7 @@ public static void setIconTextFit(SymbolLayer layer, RCTMGLStyleValue styleValue } } - public static void setIconTextFitPadding(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconTextFitPadding(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconTextFitPadding(styleValue.getExpression())); } else { @@ -1183,7 +1183,7 @@ public static void setIconTextFitPadding(SymbolLayer layer, RCTMGLStyleValue sty } } - public static void setIconImage(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconImage(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { if (styleValue.isImageStringValue()) { layer.setProperties(PropertyFactory.iconImage(styleValue.getImageStringValue())); @@ -1195,7 +1195,7 @@ public static void setIconImage(SymbolLayer layer, RCTMGLStyleValue styleValue) } } - public static void setIconRotate(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconRotate(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconRotate(styleValue.getExpression())); } else { @@ -1203,7 +1203,7 @@ public static void setIconRotate(SymbolLayer layer, RCTMGLStyleValue styleValue) } } - public static void setIconPadding(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconPadding(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconPadding(styleValue.getExpression())); } else { @@ -1211,7 +1211,7 @@ public static void setIconPadding(SymbolLayer layer, RCTMGLStyleValue styleValue } } - public static void setIconKeepUpright(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconKeepUpright(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconKeepUpright(styleValue.getExpression())); } else { @@ -1219,7 +1219,7 @@ public static void setIconKeepUpright(SymbolLayer layer, RCTMGLStyleValue styleV } } - public static void setIconOffset(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconOffset(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconOffset(styleValue.getExpression())); } else { @@ -1227,7 +1227,7 @@ public static void setIconOffset(SymbolLayer layer, RCTMGLStyleValue styleValue) } } - public static void setIconAnchor(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconAnchor(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconAnchor(styleValue.getExpression())); } else { @@ -1235,7 +1235,7 @@ public static void setIconAnchor(SymbolLayer layer, RCTMGLStyleValue styleValue) } } - public static void setIconPitchAlignment(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconPitchAlignment(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconPitchAlignment(styleValue.getExpression())); } else { @@ -1243,7 +1243,7 @@ public static void setIconPitchAlignment(SymbolLayer layer, RCTMGLStyleValue sty } } - public static void setTextPitchAlignment(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextPitchAlignment(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textPitchAlignment(styleValue.getExpression())); } else { @@ -1251,7 +1251,7 @@ public static void setTextPitchAlignment(SymbolLayer layer, RCTMGLStyleValue sty } } - public static void setTextRotationAlignment(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextRotationAlignment(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textRotationAlignment(styleValue.getExpression())); } else { @@ -1259,7 +1259,7 @@ public static void setTextRotationAlignment(SymbolLayer layer, RCTMGLStyleValue } } - public static void setTextField(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextField(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textField(styleValue.getExpression())); } else { @@ -1267,7 +1267,7 @@ public static void setTextField(SymbolLayer layer, RCTMGLStyleValue styleValue) } } - public static void setTextFont(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextFont(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textFont(styleValue.getExpression())); } else { @@ -1275,7 +1275,7 @@ public static void setTextFont(SymbolLayer layer, RCTMGLStyleValue styleValue) { } } - public static void setTextSize(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextSize(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textSize(styleValue.getExpression())); } else { @@ -1283,7 +1283,7 @@ public static void setTextSize(SymbolLayer layer, RCTMGLStyleValue styleValue) { } } - public static void setTextMaxWidth(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextMaxWidth(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textMaxWidth(styleValue.getExpression())); } else { @@ -1291,7 +1291,7 @@ public static void setTextMaxWidth(SymbolLayer layer, RCTMGLStyleValue styleValu } } - public static void setTextLineHeight(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextLineHeight(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textLineHeight(styleValue.getExpression())); } else { @@ -1299,7 +1299,7 @@ public static void setTextLineHeight(SymbolLayer layer, RCTMGLStyleValue styleVa } } - public static void setTextLetterSpacing(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextLetterSpacing(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textLetterSpacing(styleValue.getExpression())); } else { @@ -1307,7 +1307,7 @@ public static void setTextLetterSpacing(SymbolLayer layer, RCTMGLStyleValue styl } } - public static void setTextJustify(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextJustify(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textJustify(styleValue.getExpression())); } else { @@ -1315,7 +1315,7 @@ public static void setTextJustify(SymbolLayer layer, RCTMGLStyleValue styleValue } } - public static void setTextRadialOffset(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextRadialOffset(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textRadialOffset(styleValue.getExpression())); } else { @@ -1323,7 +1323,7 @@ public static void setTextRadialOffset(SymbolLayer layer, RCTMGLStyleValue style } } - public static void setTextVariableAnchor(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextVariableAnchor(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textVariableAnchor(styleValue.getExpression())); } else { @@ -1331,7 +1331,7 @@ public static void setTextVariableAnchor(SymbolLayer layer, RCTMGLStyleValue sty } } - public static void setTextAnchor(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextAnchor(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textAnchor(styleValue.getExpression())); } else { @@ -1339,7 +1339,7 @@ public static void setTextAnchor(SymbolLayer layer, RCTMGLStyleValue styleValue) } } - public static void setTextMaxAngle(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextMaxAngle(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textMaxAngle(styleValue.getExpression())); } else { @@ -1347,7 +1347,7 @@ public static void setTextMaxAngle(SymbolLayer layer, RCTMGLStyleValue styleValu } } - public static void setTextWritingMode(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextWritingMode(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textWritingMode(styleValue.getExpression())); } else { @@ -1355,7 +1355,7 @@ public static void setTextWritingMode(SymbolLayer layer, RCTMGLStyleValue styleV } } - public static void setTextRotate(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextRotate(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textRotate(styleValue.getExpression())); } else { @@ -1363,7 +1363,7 @@ public static void setTextRotate(SymbolLayer layer, RCTMGLStyleValue styleValue) } } - public static void setTextPadding(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextPadding(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textPadding(styleValue.getExpression())); } else { @@ -1371,7 +1371,7 @@ public static void setTextPadding(SymbolLayer layer, RCTMGLStyleValue styleValue } } - public static void setTextKeepUpright(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextKeepUpright(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textKeepUpright(styleValue.getExpression())); } else { @@ -1379,7 +1379,7 @@ public static void setTextKeepUpright(SymbolLayer layer, RCTMGLStyleValue styleV } } - public static void setTextTransform(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextTransform(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textTransform(styleValue.getExpression())); } else { @@ -1387,7 +1387,7 @@ public static void setTextTransform(SymbolLayer layer, RCTMGLStyleValue styleVal } } - public static void setTextOffset(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextOffset(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textOffset(styleValue.getExpression())); } else { @@ -1395,7 +1395,7 @@ public static void setTextOffset(SymbolLayer layer, RCTMGLStyleValue styleValue) } } - public static void setTextAllowOverlap(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextAllowOverlap(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textAllowOverlap(styleValue.getExpression())); } else { @@ -1403,7 +1403,7 @@ public static void setTextAllowOverlap(SymbolLayer layer, RCTMGLStyleValue style } } - public static void setTextIgnorePlacement(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextIgnorePlacement(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textIgnorePlacement(styleValue.getExpression())); } else { @@ -1411,7 +1411,7 @@ public static void setTextIgnorePlacement(SymbolLayer layer, RCTMGLStyleValue st } } - public static void setTextOptional(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextOptional(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textOptional(styleValue.getExpression())); } else { @@ -1419,11 +1419,11 @@ public static void setTextOptional(SymbolLayer layer, RCTMGLStyleValue styleValu } } - public static void setVisibility(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setVisibility(SymbolLayer layer, RCTMLNStyleValue styleValue) { layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY))); } - public static void setIconOpacity(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconOpacity(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconOpacity(styleValue.getExpression())); } else { @@ -1432,14 +1432,14 @@ public static void setIconOpacity(SymbolLayer layer, RCTMGLStyleValue styleValue } - public static void setIconOpacityTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconOpacityTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setIconOpacityTransition(transition); } } - public static void setIconColor(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconColor(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconColor(styleValue.getExpression())); } else { @@ -1448,14 +1448,14 @@ public static void setIconColor(SymbolLayer layer, RCTMGLStyleValue styleValue) } - public static void setIconColorTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconColorTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setIconColorTransition(transition); } } - public static void setIconHaloColor(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconHaloColor(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconHaloColor(styleValue.getExpression())); } else { @@ -1464,14 +1464,14 @@ public static void setIconHaloColor(SymbolLayer layer, RCTMGLStyleValue styleVal } - public static void setIconHaloColorTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconHaloColorTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setIconHaloColorTransition(transition); } } - public static void setIconHaloWidth(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconHaloWidth(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconHaloWidth(styleValue.getExpression())); } else { @@ -1480,14 +1480,14 @@ public static void setIconHaloWidth(SymbolLayer layer, RCTMGLStyleValue styleVal } - public static void setIconHaloWidthTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconHaloWidthTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setIconHaloWidthTransition(transition); } } - public static void setIconHaloBlur(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconHaloBlur(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconHaloBlur(styleValue.getExpression())); } else { @@ -1496,14 +1496,14 @@ public static void setIconHaloBlur(SymbolLayer layer, RCTMGLStyleValue styleValu } - public static void setIconHaloBlurTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconHaloBlurTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setIconHaloBlurTransition(transition); } } - public static void setIconTranslate(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconTranslate(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconTranslate(styleValue.getExpression())); } else { @@ -1512,14 +1512,14 @@ public static void setIconTranslate(SymbolLayer layer, RCTMGLStyleValue styleVal } - public static void setIconTranslateTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconTranslateTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setIconTranslateTransition(transition); } } - public static void setIconTranslateAnchor(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setIconTranslateAnchor(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.iconTranslateAnchor(styleValue.getExpression())); } else { @@ -1527,7 +1527,7 @@ public static void setIconTranslateAnchor(SymbolLayer layer, RCTMGLStyleValue st } } - public static void setTextOpacity(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextOpacity(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textOpacity(styleValue.getExpression())); } else { @@ -1536,14 +1536,14 @@ public static void setTextOpacity(SymbolLayer layer, RCTMGLStyleValue styleValue } - public static void setTextOpacityTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextOpacityTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setTextOpacityTransition(transition); } } - public static void setTextColor(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextColor(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textColor(styleValue.getExpression())); } else { @@ -1552,14 +1552,14 @@ public static void setTextColor(SymbolLayer layer, RCTMGLStyleValue styleValue) } - public static void setTextColorTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextColorTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setTextColorTransition(transition); } } - public static void setTextHaloColor(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextHaloColor(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textHaloColor(styleValue.getExpression())); } else { @@ -1568,14 +1568,14 @@ public static void setTextHaloColor(SymbolLayer layer, RCTMGLStyleValue styleVal } - public static void setTextHaloColorTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextHaloColorTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setTextHaloColorTransition(transition); } } - public static void setTextHaloWidth(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextHaloWidth(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textHaloWidth(styleValue.getExpression())); } else { @@ -1584,14 +1584,14 @@ public static void setTextHaloWidth(SymbolLayer layer, RCTMGLStyleValue styleVal } - public static void setTextHaloWidthTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextHaloWidthTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setTextHaloWidthTransition(transition); } } - public static void setTextHaloBlur(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextHaloBlur(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textHaloBlur(styleValue.getExpression())); } else { @@ -1600,14 +1600,14 @@ public static void setTextHaloBlur(SymbolLayer layer, RCTMGLStyleValue styleValu } - public static void setTextHaloBlurTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextHaloBlurTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setTextHaloBlurTransition(transition); } } - public static void setTextTranslate(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextTranslate(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textTranslate(styleValue.getExpression())); } else { @@ -1616,14 +1616,14 @@ public static void setTextTranslate(SymbolLayer layer, RCTMGLStyleValue styleVal } - public static void setTextTranslateTransition(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextTranslateTransition(SymbolLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setTextTranslateTransition(transition); } } - public static void setTextTranslateAnchor(SymbolLayer layer, RCTMGLStyleValue styleValue) { + public static void setTextTranslateAnchor(SymbolLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.textTranslateAnchor(styleValue.getExpression())); } else { @@ -1631,7 +1631,7 @@ public static void setTextTranslateAnchor(SymbolLayer layer, RCTMGLStyleValue st } } - public static void setCircleSortKey(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleSortKey(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleSortKey(styleValue.getExpression())); } else { @@ -1639,11 +1639,11 @@ public static void setCircleSortKey(CircleLayer layer, RCTMGLStyleValue styleVal } } - public static void setVisibility(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setVisibility(CircleLayer layer, RCTMLNStyleValue styleValue) { layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY))); } - public static void setCircleRadius(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleRadius(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleRadius(styleValue.getExpression())); } else { @@ -1652,14 +1652,14 @@ public static void setCircleRadius(CircleLayer layer, RCTMGLStyleValue styleValu } - public static void setCircleRadiusTransition(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleRadiusTransition(CircleLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setCircleRadiusTransition(transition); } } - public static void setCircleColor(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleColor(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleColor(styleValue.getExpression())); } else { @@ -1668,14 +1668,14 @@ public static void setCircleColor(CircleLayer layer, RCTMGLStyleValue styleValue } - public static void setCircleColorTransition(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleColorTransition(CircleLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setCircleColorTransition(transition); } } - public static void setCircleBlur(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleBlur(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleBlur(styleValue.getExpression())); } else { @@ -1684,14 +1684,14 @@ public static void setCircleBlur(CircleLayer layer, RCTMGLStyleValue styleValue) } - public static void setCircleBlurTransition(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleBlurTransition(CircleLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setCircleBlurTransition(transition); } } - public static void setCircleOpacity(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleOpacity(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleOpacity(styleValue.getExpression())); } else { @@ -1700,14 +1700,14 @@ public static void setCircleOpacity(CircleLayer layer, RCTMGLStyleValue styleVal } - public static void setCircleOpacityTransition(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleOpacityTransition(CircleLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setCircleOpacityTransition(transition); } } - public static void setCircleTranslate(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleTranslate(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleTranslate(styleValue.getExpression())); } else { @@ -1716,14 +1716,14 @@ public static void setCircleTranslate(CircleLayer layer, RCTMGLStyleValue styleV } - public static void setCircleTranslateTransition(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleTranslateTransition(CircleLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setCircleTranslateTransition(transition); } } - public static void setCircleTranslateAnchor(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleTranslateAnchor(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleTranslateAnchor(styleValue.getExpression())); } else { @@ -1731,7 +1731,7 @@ public static void setCircleTranslateAnchor(CircleLayer layer, RCTMGLStyleValue } } - public static void setCirclePitchScale(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCirclePitchScale(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circlePitchScale(styleValue.getExpression())); } else { @@ -1739,7 +1739,7 @@ public static void setCirclePitchScale(CircleLayer layer, RCTMGLStyleValue style } } - public static void setCirclePitchAlignment(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCirclePitchAlignment(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circlePitchAlignment(styleValue.getExpression())); } else { @@ -1747,7 +1747,7 @@ public static void setCirclePitchAlignment(CircleLayer layer, RCTMGLStyleValue s } } - public static void setCircleStrokeWidth(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleStrokeWidth(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleStrokeWidth(styleValue.getExpression())); } else { @@ -1756,14 +1756,14 @@ public static void setCircleStrokeWidth(CircleLayer layer, RCTMGLStyleValue styl } - public static void setCircleStrokeWidthTransition(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleStrokeWidthTransition(CircleLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setCircleStrokeWidthTransition(transition); } } - public static void setCircleStrokeColor(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleStrokeColor(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleStrokeColor(styleValue.getExpression())); } else { @@ -1772,14 +1772,14 @@ public static void setCircleStrokeColor(CircleLayer layer, RCTMGLStyleValue styl } - public static void setCircleStrokeColorTransition(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleStrokeColorTransition(CircleLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setCircleStrokeColorTransition(transition); } } - public static void setCircleStrokeOpacity(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleStrokeOpacity(CircleLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.circleStrokeOpacity(styleValue.getExpression())); } else { @@ -1788,18 +1788,18 @@ public static void setCircleStrokeOpacity(CircleLayer layer, RCTMGLStyleValue st } - public static void setCircleStrokeOpacityTransition(CircleLayer layer, RCTMGLStyleValue styleValue) { + public static void setCircleStrokeOpacityTransition(CircleLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setCircleStrokeOpacityTransition(transition); } } - public static void setVisibility(HeatmapLayer layer, RCTMGLStyleValue styleValue) { + public static void setVisibility(HeatmapLayer layer, RCTMLNStyleValue styleValue) { layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY))); } - public static void setHeatmapRadius(HeatmapLayer layer, RCTMGLStyleValue styleValue) { + public static void setHeatmapRadius(HeatmapLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.heatmapRadius(styleValue.getExpression())); } else { @@ -1808,14 +1808,14 @@ public static void setHeatmapRadius(HeatmapLayer layer, RCTMGLStyleValue styleVa } - public static void setHeatmapRadiusTransition(HeatmapLayer layer, RCTMGLStyleValue styleValue) { + public static void setHeatmapRadiusTransition(HeatmapLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setHeatmapRadiusTransition(transition); } } - public static void setHeatmapWeight(HeatmapLayer layer, RCTMGLStyleValue styleValue) { + public static void setHeatmapWeight(HeatmapLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.heatmapWeight(styleValue.getExpression())); } else { @@ -1823,7 +1823,7 @@ public static void setHeatmapWeight(HeatmapLayer layer, RCTMGLStyleValue styleVa } } - public static void setHeatmapIntensity(HeatmapLayer layer, RCTMGLStyleValue styleValue) { + public static void setHeatmapIntensity(HeatmapLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.heatmapIntensity(styleValue.getExpression())); } else { @@ -1832,14 +1832,14 @@ public static void setHeatmapIntensity(HeatmapLayer layer, RCTMGLStyleValue styl } - public static void setHeatmapIntensityTransition(HeatmapLayer layer, RCTMGLStyleValue styleValue) { + public static void setHeatmapIntensityTransition(HeatmapLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setHeatmapIntensityTransition(transition); } } - public static void setHeatmapColor(HeatmapLayer layer, RCTMGLStyleValue styleValue) { + public static void setHeatmapColor(HeatmapLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.heatmapColor(styleValue.getExpression())); } else { @@ -1847,7 +1847,7 @@ public static void setHeatmapColor(HeatmapLayer layer, RCTMGLStyleValue styleVal } } - public static void setHeatmapOpacity(HeatmapLayer layer, RCTMGLStyleValue styleValue) { + public static void setHeatmapOpacity(HeatmapLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.heatmapOpacity(styleValue.getExpression())); } else { @@ -1856,18 +1856,18 @@ public static void setHeatmapOpacity(HeatmapLayer layer, RCTMGLStyleValue styleV } - public static void setHeatmapOpacityTransition(HeatmapLayer layer, RCTMGLStyleValue styleValue) { + public static void setHeatmapOpacityTransition(HeatmapLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setHeatmapOpacityTransition(transition); } } - public static void setVisibility(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setVisibility(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY))); } - public static void setFillExtrusionOpacity(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionOpacity(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillExtrusionOpacity(styleValue.getExpression())); } else { @@ -1876,14 +1876,14 @@ public static void setFillExtrusionOpacity(FillExtrusionLayer layer, RCTMGLStyle } - public static void setFillExtrusionOpacityTransition(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionOpacityTransition(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillExtrusionOpacityTransition(transition); } } - public static void setFillExtrusionColor(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionColor(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillExtrusionColor(styleValue.getExpression())); } else { @@ -1892,14 +1892,14 @@ public static void setFillExtrusionColor(FillExtrusionLayer layer, RCTMGLStyleVa } - public static void setFillExtrusionColorTransition(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionColorTransition(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillExtrusionColorTransition(transition); } } - public static void setFillExtrusionTranslate(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionTranslate(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillExtrusionTranslate(styleValue.getExpression())); } else { @@ -1908,14 +1908,14 @@ public static void setFillExtrusionTranslate(FillExtrusionLayer layer, RCTMGLSty } - public static void setFillExtrusionTranslateTransition(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionTranslateTransition(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillExtrusionTranslateTransition(transition); } } - public static void setFillExtrusionTranslateAnchor(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionTranslateAnchor(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillExtrusionTranslateAnchor(styleValue.getExpression())); } else { @@ -1923,7 +1923,7 @@ public static void setFillExtrusionTranslateAnchor(FillExtrusionLayer layer, RCT } } - public static void setFillExtrusionPattern(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionPattern(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { if (styleValue.isImageStringValue()) { layer.setProperties(PropertyFactory.fillExtrusionPattern(styleValue.getImageStringValue())); @@ -1936,14 +1936,14 @@ public static void setFillExtrusionPattern(FillExtrusionLayer layer, RCTMGLStyle } - public static void setFillExtrusionPatternTransition(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionPatternTransition(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillExtrusionPatternTransition(transition); } } - public static void setFillExtrusionHeight(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionHeight(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillExtrusionHeight(styleValue.getExpression())); } else { @@ -1952,14 +1952,14 @@ public static void setFillExtrusionHeight(FillExtrusionLayer layer, RCTMGLStyleV } - public static void setFillExtrusionHeightTransition(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionHeightTransition(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillExtrusionHeightTransition(transition); } } - public static void setFillExtrusionBase(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionBase(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.fillExtrusionBase(styleValue.getExpression())); } else { @@ -1968,18 +1968,18 @@ public static void setFillExtrusionBase(FillExtrusionLayer layer, RCTMGLStyleVal } - public static void setFillExtrusionBaseTransition(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) { + public static void setFillExtrusionBaseTransition(FillExtrusionLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setFillExtrusionBaseTransition(transition); } } - public static void setVisibility(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setVisibility(RasterLayer layer, RCTMLNStyleValue styleValue) { layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY))); } - public static void setRasterOpacity(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterOpacity(RasterLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.rasterOpacity(styleValue.getExpression())); } else { @@ -1988,14 +1988,14 @@ public static void setRasterOpacity(RasterLayer layer, RCTMGLStyleValue styleVal } - public static void setRasterOpacityTransition(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterOpacityTransition(RasterLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setRasterOpacityTransition(transition); } } - public static void setRasterHueRotate(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterHueRotate(RasterLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.rasterHueRotate(styleValue.getExpression())); } else { @@ -2004,14 +2004,14 @@ public static void setRasterHueRotate(RasterLayer layer, RCTMGLStyleValue styleV } - public static void setRasterHueRotateTransition(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterHueRotateTransition(RasterLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setRasterHueRotateTransition(transition); } } - public static void setRasterBrightnessMin(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterBrightnessMin(RasterLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.rasterBrightnessMin(styleValue.getExpression())); } else { @@ -2020,14 +2020,14 @@ public static void setRasterBrightnessMin(RasterLayer layer, RCTMGLStyleValue st } - public static void setRasterBrightnessMinTransition(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterBrightnessMinTransition(RasterLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setRasterBrightnessMinTransition(transition); } } - public static void setRasterBrightnessMax(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterBrightnessMax(RasterLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.rasterBrightnessMax(styleValue.getExpression())); } else { @@ -2036,14 +2036,14 @@ public static void setRasterBrightnessMax(RasterLayer layer, RCTMGLStyleValue st } - public static void setRasterBrightnessMaxTransition(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterBrightnessMaxTransition(RasterLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setRasterBrightnessMaxTransition(transition); } } - public static void setRasterSaturation(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterSaturation(RasterLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.rasterSaturation(styleValue.getExpression())); } else { @@ -2052,14 +2052,14 @@ public static void setRasterSaturation(RasterLayer layer, RCTMGLStyleValue style } - public static void setRasterSaturationTransition(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterSaturationTransition(RasterLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setRasterSaturationTransition(transition); } } - public static void setRasterContrast(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterContrast(RasterLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.rasterContrast(styleValue.getExpression())); } else { @@ -2068,14 +2068,14 @@ public static void setRasterContrast(RasterLayer layer, RCTMGLStyleValue styleVa } - public static void setRasterContrastTransition(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterContrastTransition(RasterLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setRasterContrastTransition(transition); } } - public static void setRasterResampling(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterResampling(RasterLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.rasterResampling(styleValue.getExpression())); } else { @@ -2083,7 +2083,7 @@ public static void setRasterResampling(RasterLayer layer, RCTMGLStyleValue style } } - public static void setRasterFadeDuration(RasterLayer layer, RCTMGLStyleValue styleValue) { + public static void setRasterFadeDuration(RasterLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.rasterFadeDuration(styleValue.getExpression())); } else { @@ -2091,11 +2091,11 @@ public static void setRasterFadeDuration(RasterLayer layer, RCTMGLStyleValue sty } } - public static void setVisibility(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setVisibility(HillshadeLayer layer, RCTMLNStyleValue styleValue) { layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY))); } - public static void setHillshadeIlluminationDirection(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeIlluminationDirection(HillshadeLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.hillshadeIlluminationDirection(styleValue.getExpression())); } else { @@ -2103,7 +2103,7 @@ public static void setHillshadeIlluminationDirection(HillshadeLayer layer, RCTMG } } - public static void setHillshadeIlluminationAnchor(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeIlluminationAnchor(HillshadeLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.hillshadeIlluminationAnchor(styleValue.getExpression())); } else { @@ -2111,7 +2111,7 @@ public static void setHillshadeIlluminationAnchor(HillshadeLayer layer, RCTMGLSt } } - public static void setHillshadeExaggeration(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeExaggeration(HillshadeLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.hillshadeExaggeration(styleValue.getExpression())); } else { @@ -2120,14 +2120,14 @@ public static void setHillshadeExaggeration(HillshadeLayer layer, RCTMGLStyleVal } - public static void setHillshadeExaggerationTransition(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeExaggerationTransition(HillshadeLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setHillshadeExaggerationTransition(transition); } } - public static void setHillshadeShadowColor(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeShadowColor(HillshadeLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.hillshadeShadowColor(styleValue.getExpression())); } else { @@ -2136,14 +2136,14 @@ public static void setHillshadeShadowColor(HillshadeLayer layer, RCTMGLStyleValu } - public static void setHillshadeShadowColorTransition(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeShadowColorTransition(HillshadeLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setHillshadeShadowColorTransition(transition); } } - public static void setHillshadeHighlightColor(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeHighlightColor(HillshadeLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.hillshadeHighlightColor(styleValue.getExpression())); } else { @@ -2152,14 +2152,14 @@ public static void setHillshadeHighlightColor(HillshadeLayer layer, RCTMGLStyleV } - public static void setHillshadeHighlightColorTransition(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeHighlightColorTransition(HillshadeLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setHillshadeHighlightColorTransition(transition); } } - public static void setHillshadeAccentColor(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeAccentColor(HillshadeLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.hillshadeAccentColor(styleValue.getExpression())); } else { @@ -2168,18 +2168,18 @@ public static void setHillshadeAccentColor(HillshadeLayer layer, RCTMGLStyleValu } - public static void setHillshadeAccentColorTransition(HillshadeLayer layer, RCTMGLStyleValue styleValue) { + public static void setHillshadeAccentColorTransition(HillshadeLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setHillshadeAccentColorTransition(transition); } } - public static void setVisibility(BackgroundLayer layer, RCTMGLStyleValue styleValue) { + public static void setVisibility(BackgroundLayer layer, RCTMLNStyleValue styleValue) { layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY))); } - public static void setBackgroundColor(BackgroundLayer layer, RCTMGLStyleValue styleValue) { + public static void setBackgroundColor(BackgroundLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.backgroundColor(styleValue.getExpression())); } else { @@ -2188,14 +2188,14 @@ public static void setBackgroundColor(BackgroundLayer layer, RCTMGLStyleValue st } - public static void setBackgroundColorTransition(BackgroundLayer layer, RCTMGLStyleValue styleValue) { + public static void setBackgroundColorTransition(BackgroundLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setBackgroundColorTransition(transition); } } - public static void setBackgroundPattern(BackgroundLayer layer, RCTMGLStyleValue styleValue) { + public static void setBackgroundPattern(BackgroundLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { if (styleValue.isImageStringValue()) { layer.setProperties(PropertyFactory.backgroundPattern(styleValue.getImageStringValue())); @@ -2208,14 +2208,14 @@ public static void setBackgroundPattern(BackgroundLayer layer, RCTMGLStyleValue } - public static void setBackgroundPatternTransition(BackgroundLayer layer, RCTMGLStyleValue styleValue) { + public static void setBackgroundPatternTransition(BackgroundLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setBackgroundPatternTransition(transition); } } - public static void setBackgroundOpacity(BackgroundLayer layer, RCTMGLStyleValue styleValue) { + public static void setBackgroundOpacity(BackgroundLayer layer, RCTMLNStyleValue styleValue) { if (styleValue.isExpression()) { layer.setProperties(PropertyFactory.backgroundOpacity(styleValue.getExpression())); } else { @@ -2224,48 +2224,48 @@ public static void setBackgroundOpacity(BackgroundLayer layer, RCTMGLStyleValue } - public static void setBackgroundOpacityTransition(BackgroundLayer layer, RCTMGLStyleValue styleValue) { + public static void setBackgroundOpacityTransition(BackgroundLayer layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setBackgroundOpacityTransition(transition); } } - public static void setAnchor(Light layer, RCTMGLStyleValue styleValue) { + public static void setAnchor(Light layer, RCTMLNStyleValue styleValue) { layer.setAnchor(styleValue.getString(VALUE_KEY)); } - public static void setPosition(Light layer, RCTMGLStyleValue styleValue) { + public static void setPosition(Light layer, RCTMLNStyleValue styleValue) { Float[] values = styleValue.getFloatArray(VALUE_KEY); layer.setPosition(Position.fromPosition(values[0], values[1], values[2])); } - public static void setPositionTransition(Light layer, RCTMGLStyleValue styleValue) { + public static void setPositionTransition(Light layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setPositionTransition(transition); } } - public static void setColor(Light layer, RCTMGLStyleValue styleValue) { + public static void setColor(Light layer, RCTMLNStyleValue styleValue) { layer.setColor(styleValue.getInt(VALUE_KEY)); } - public static void setColorTransition(Light layer, RCTMGLStyleValue styleValue) { + public static void setColorTransition(Light layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setColorTransition(transition); } } - public static void setIntensity(Light layer, RCTMGLStyleValue styleValue) { + public static void setIntensity(Light layer, RCTMLNStyleValue styleValue) { layer.setIntensity(styleValue.getFloat(VALUE_KEY)); } - public static void setIntensityTransition(Light layer, RCTMGLStyleValue styleValue) { + public static void setIntensityTransition(Light layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.setIntensityTransition(transition); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleFunctionParser.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleFunctionParser.java similarity index 90% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleFunctionParser.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleFunctionParser.java index d66f9ffa7..bd136c598 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleFunctionParser.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleFunctionParser.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles; +package com.maplibre.rctmln.components.styles; import android.util.Log; @@ -24,10 +24,10 @@ * Created by nickitaliano on 9/12/17. */ -public abstract class RCTMGLStyleFunctionParser { - private RCTMGLStyleValue mStyleValue; +public abstract class RCTMLNStyleFunctionParser { + private RCTMLNStyleValue mStyleValue; - public RCTMGLStyleFunctionParser(RCTMGLStyleValue styleValue) { + public RCTMLNStyleFunctionParser(RCTMLNStyleValue styleValue) { mStyleValue = styleValue; } @@ -41,7 +41,7 @@ public List getRawStops() { ReadableMap jsStopKey = rawStop.getMap(0); ReadableMap jsStopValue = rawStop.getMap(1); - RCTMGLStyleValue innerStyleValue = new RCTMGLStyleValue(jsStopValue); + RCTMLNStyleValue innerStyleValue = new RCTMLNStyleValue(jsStopValue); Object propertyValue = null; try { @@ -72,7 +72,7 @@ public List getRawStops() { return rawStops; } - protected abstract T getRawStopValue (RCTMGLStyleValue styleValue); + protected abstract T getRawStopValue (RCTMLNStyleValue styleValue); protected abstract PropertyValue getStopValue(T value); private Object getStopKey(ReadableMap jsStopKey) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleValue.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleValue.java similarity index 94% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleValue.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleValue.java index 37a166272..4cffa39fc 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleValue.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/RCTMLNStyleValue.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles; +package com.maplibre.rctmln.components.styles; import androidx.annotation.NonNull; @@ -10,15 +10,15 @@ import com.google.gson.JsonArray; import com.mapbox.mapboxsdk.style.expressions.Expression; import com.mapbox.mapboxsdk.style.layers.TransitionOptions; -import com.mapbox.rctmgl.utils.ConvertUtils; -import com.mapbox.rctmgl.utils.ExpressionParser; -import com.mapbox.rctmgl.utils.ImageEntry; +import com.maplibre.rctmln.utils.ConvertUtils; +import com.maplibre.rctmln.utils.ExpressionParser; +import com.maplibre.rctmln.utils.ImageEntry; /** * Created by nickitaliano on 9/12/17. */ -public class RCTMGLStyleValue { +public class RCTMLNStyleValue { private String mType; private boolean isExpression; @@ -34,7 +34,7 @@ public class RCTMGLStyleValue { public static final int InterpolationModeCategorical = 102; public static final int InterpolationModeIdentity = 103; - public RCTMGLStyleValue(@NonNull ReadableMap config) { + public RCTMLNStyleValue(@NonNull ReadableMap config) { mType = config.getString("styletype"); mPayload = config.getMap("stylevalue"); @@ -192,7 +192,7 @@ public TransitionOptions getTransition() { if (!mType.equals("transition")) { return null; } - ReadableMap config = getMap(RCTMGLStyleFactory.VALUE_KEY); + ReadableMap config = getMap(RCTMLNStyleFactory.VALUE_KEY); boolean enablePlacementTransitions = true; if (config.hasKey("enablePlacementTransitions")) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTLayer.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTLayer.java similarity index 93% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTLayer.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTLayer.java index 477197525..b7d163a89 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTLayer.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTLayer.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import android.content.Context; @@ -12,9 +12,9 @@ import com.mapbox.mapboxsdk.style.layers.Layer; import com.mapbox.mapboxsdk.style.layers.Property; import com.mapbox.mapboxsdk.style.layers.PropertyFactory; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.utils.ExpressionParser; +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.utils.ExpressionParser; import java.util.Arrays; import java.util.HashSet; @@ -43,7 +43,7 @@ public abstract class RCTLayer extends AbstractMapFeature { protected T mLayer; protected Context mContext; - protected RCTMGLMapView mMapView; + protected RCTMLNMapView mMapView; protected boolean mHadFilter; @@ -170,7 +170,7 @@ public void add() { } public void addAbove(final String aboveLayerID) { - mMapView.waitForLayer(aboveLayerID, new RCTMGLMapView.FoundLayerCallback() { + mMapView.waitForLayer(aboveLayerID, new RCTMLNMapView.FoundLayerCallback() { public void found(Layer layer) { if (!hasInitialized()) { return; @@ -183,7 +183,7 @@ public void found(Layer layer) { } public void addBelow(final String belowLayerID) { - mMapView.waitForLayer(belowLayerID, new RCTMGLMapView.FoundLayerCallback() { + mMapView.waitForLayer(belowLayerID, new RCTMLNMapView.FoundLayerCallback() { public void found(Layer layer) { if (!hasInitialized()) { return; @@ -243,7 +243,7 @@ protected void updateFilter(Expression expression) { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { mMap = mapView.getMapboxMap(); mMapView = mapView; @@ -265,7 +265,7 @@ public void addToMap(RCTMGLMapView mapView) { } @Override - public void removeFromMap(RCTMGLMapView mapView) { + public void removeFromMap(RCTMLNMapView mapView) { if (getStyle() != null) { getStyle().removeLayer(mLayer); } diff --git a/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNBackgroundLayer.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNBackgroundLayer.java new file mode 100644 index 000000000..3d9ad2507 --- /dev/null +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNBackgroundLayer.java @@ -0,0 +1,27 @@ +package com.maplibre.rctmln.components.styles.layers; + +import android.content.Context; + +import com.mapbox.mapboxsdk.style.layers.BackgroundLayer; +import com.maplibre.rctmln.components.styles.RCTMLNStyle; +import com.maplibre.rctmln.components.styles.RCTMLNStyleFactory; + +/** + * Created by nickitaliano on 9/25/17. + */ + +public class RCTMLNBackgroundLayer extends RCTLayer { + public RCTMLNBackgroundLayer(Context context) { + super(context); + } + + @Override + public BackgroundLayer makeLayer() { + return new BackgroundLayer(mID); + } + + @Override + public void addStyles() { + RCTMLNStyleFactory.setBackgroundLayerStyle(mLayer, new RCTMLNStyle(getContext(), mReactStyle, mMap)); + } +} diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLBackgroundLayerManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNBackgroundLayerManager.java similarity index 58% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLBackgroundLayerManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNBackgroundLayerManager.java index 7c5c3330f..6b61a3b95 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLBackgroundLayerManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNBackgroundLayerManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import com.facebook.react.bridge.ReadableMap; import com.facebook.react.uimanager.ThemedReactContext; @@ -9,8 +9,8 @@ * Created by nickitaliano on 9/25/17. */ -public class RCTMGLBackgroundLayerManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLBackgroundLayer"; +public class RCTMLNBackgroundLayerManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNBackgroundLayer"; @Override public String getName() { @@ -18,47 +18,47 @@ public String getName() { } @Override - protected RCTMGLBackgroundLayer createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLBackgroundLayer(reactContext); + protected RCTMLNBackgroundLayer createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNBackgroundLayer(reactContext); } @ReactProp(name="id") - public void setId(RCTMGLBackgroundLayer layer, String id) { + public void setId(RCTMLNBackgroundLayer layer, String id) { layer.setID(id); } @ReactProp(name="sourceID") - public void setSourceID(RCTMGLBackgroundLayer layer, String sourceID) { + public void setSourceID(RCTMLNBackgroundLayer layer, String sourceID) { layer.setSourceID(sourceID); } @ReactProp(name="aboveLayerID") - public void setAboveLayerID(RCTMGLBackgroundLayer layer, String aboveLayerID) { + public void setAboveLayerID(RCTMLNBackgroundLayer layer, String aboveLayerID) { layer.setAboveLayerID(aboveLayerID); } @ReactProp(name="belowLayerID") - public void setBelowLayerID(RCTMGLBackgroundLayer layer, String belowLayerID) { + public void setBelowLayerID(RCTMLNBackgroundLayer layer, String belowLayerID) { layer.setBelowLayerID(belowLayerID); } @ReactProp(name="layerIndex") - public void setLayerIndex(RCTMGLBackgroundLayer layer, int layerIndex){ + public void setLayerIndex(RCTMLNBackgroundLayer layer, int layerIndex){ layer.setLayerIndex(layerIndex); } @ReactProp(name="minZoomLevel") - public void setMinZoomLevel(RCTMGLBackgroundLayer layer, double minZoomLevel) { + public void setMinZoomLevel(RCTMLNBackgroundLayer layer, double minZoomLevel) { layer.setMinZoomLevel(minZoomLevel); } @ReactProp(name="maxZoomLevel") - public void setMaxZoomLevel(RCTMGLBackgroundLayer layer, double maxZoomLevel) { + public void setMaxZoomLevel(RCTMLNBackgroundLayer layer, double maxZoomLevel) { layer.setMaxZoomLevel(maxZoomLevel); } @ReactProp(name="reactStyle") - public void setReactStyle(RCTMGLBackgroundLayer layer, ReadableMap style) { + public void setReactStyle(RCTMLNBackgroundLayer layer, ReadableMap style) { layer.setReactStyle(style); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLCircleLayer.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNCircleLayer.java similarity index 64% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLCircleLayer.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNCircleLayer.java index 2bc3d8581..b0a3e41a5 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLCircleLayer.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNCircleLayer.java @@ -1,21 +1,21 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import android.content.Context; import com.mapbox.mapboxsdk.style.expressions.Expression; import com.mapbox.mapboxsdk.style.layers.CircleLayer; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.components.styles.RCTMGLStyle; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleFactory; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.components.styles.RCTMLNStyle; +import com.maplibre.rctmln.components.styles.RCTMLNStyleFactory; /** * Created by nickitaliano on 9/18/17. */ -public class RCTMGLCircleLayer extends RCTLayer { +public class RCTMLNCircleLayer extends RCTLayer { private String mSourceLayerID; - public RCTMGLCircleLayer(Context context) { + public RCTMLNCircleLayer(Context context) { super(context); } @@ -25,7 +25,7 @@ protected void updateFilter(Expression expression) { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { super.addToMap(mapView); } @@ -42,7 +42,7 @@ public CircleLayer makeLayer() { @Override public void addStyles() { - RCTMGLStyleFactory.setCircleLayerStyle(mLayer, new RCTMGLStyle(getContext(), mReactStyle, mMap)); + RCTMLNStyleFactory.setCircleLayerStyle(mLayer, new RCTMLNStyle(getContext(), mReactStyle, mMap)); } public void setSourceLayerID(String sourceLayerID) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLCircleLayerManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNCircleLayerManager.java similarity index 59% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLCircleLayerManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNCircleLayerManager.java index 8356ab771..5adf1624c 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLCircleLayerManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNCircleLayerManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import com.facebook.react.bridge.ReadableArray; import com.facebook.react.bridge.ReadableMap; @@ -12,8 +12,8 @@ * Created by nickitaliano on 9/18/17. */ -public class RCTMGLCircleLayerManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLCircleLayer"; +public class RCTMLNCircleLayerManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNCircleLayer"; @Override public String getName() { @@ -21,57 +21,57 @@ public String getName() { } @Override - protected RCTMGLCircleLayer createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLCircleLayer(reactContext); + protected RCTMLNCircleLayer createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNCircleLayer(reactContext); } @ReactProp(name="id") - public void setId(RCTMGLCircleLayer layer, String id) { + public void setId(RCTMLNCircleLayer layer, String id) { layer.setID(id); } @ReactProp(name="sourceID") - public void setSourceID(RCTMGLCircleLayer layer, String sourceID) { + public void setSourceID(RCTMLNCircleLayer layer, String sourceID) { layer.setSourceID(sourceID); } @ReactProp(name="aboveLayerID") - public void setAboveLayerID(RCTMGLCircleLayer layer, String aboveLayerID) { + public void setAboveLayerID(RCTMLNCircleLayer layer, String aboveLayerID) { layer.setAboveLayerID(aboveLayerID); } @ReactProp(name="belowLayerID") - public void setBelowLayerID(RCTMGLCircleLayer layer, String belowLayerID) { + public void setBelowLayerID(RCTMLNCircleLayer layer, String belowLayerID) { layer.setBelowLayerID(belowLayerID); } @ReactProp(name="layerIndex") - public void setLayerIndex(RCTMGLCircleLayer layer, int layerIndex){ + public void setLayerIndex(RCTMLNCircleLayer layer, int layerIndex){ layer.setLayerIndex(layerIndex); } @ReactProp(name="minZoomLevel") - public void setMinZoomLevel(RCTMGLCircleLayer layer, double minZoomLevel) { + public void setMinZoomLevel(RCTMLNCircleLayer layer, double minZoomLevel) { layer.setMinZoomLevel(minZoomLevel); } @ReactProp(name="maxZoomLevel") - public void setMaxZoomLevel(RCTMGLCircleLayer layer, double maxZoomLevel) { + public void setMaxZoomLevel(RCTMLNCircleLayer layer, double maxZoomLevel) { layer.setMaxZoomLevel(maxZoomLevel); } @ReactProp(name="reactStyle") - public void setReactStyle(RCTMGLCircleLayer layer, ReadableMap style) { + public void setReactStyle(RCTMLNCircleLayer layer, ReadableMap style) { layer.setReactStyle(style); } @ReactProp(name="sourceLayerID") - public void setSourceLayerId(RCTMGLCircleLayer layer, String sourceLayerID) { + public void setSourceLayerId(RCTMLNCircleLayer layer, String sourceLayerID) { layer.setSourceLayerID(sourceLayerID); } @ReactProp(name="filter") - public void setFilter(RCTMGLCircleLayer layer, ReadableArray filterList) { + public void setFilter(RCTMLNCircleLayer layer, ReadableArray filterList) { layer.setFilter(filterList); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillExtrusionLayer.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillExtrusionLayer.java similarity index 64% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillExtrusionLayer.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillExtrusionLayer.java index 4f9864cda..51e30b61c 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillExtrusionLayer.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillExtrusionLayer.java @@ -1,21 +1,21 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import android.content.Context; import com.mapbox.mapboxsdk.style.expressions.Expression; import com.mapbox.mapboxsdk.style.layers.FillExtrusionLayer; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.components.styles.RCTMGLStyle; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleFactory; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.components.styles.RCTMLNStyle; +import com.maplibre.rctmln.components.styles.RCTMLNStyleFactory; /** * Created by nickitaliano on 9/15/17. */ -public class RCTMGLFillExtrusionLayer extends RCTLayer { +public class RCTMLNFillExtrusionLayer extends RCTLayer { private String mSourceLayerID; - public RCTMGLFillExtrusionLayer(Context context) { + public RCTMLNFillExtrusionLayer(Context context) { super(context); } @@ -25,7 +25,7 @@ protected void updateFilter(Expression expression) { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { super.addToMap(mapView); } @@ -42,7 +42,7 @@ public FillExtrusionLayer makeLayer() { @Override public void addStyles() { - RCTMGLStyleFactory.setFillExtrusionLayerStyle(mLayer, new RCTMGLStyle(getContext(), mReactStyle, mMap)); + RCTMLNStyleFactory.setFillExtrusionLayerStyle(mLayer, new RCTMLNStyle(getContext(), mReactStyle, mMap)); } public void setSourceLayerID(String sourceLayerID) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillExtrusionLayerManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillExtrusionLayerManager.java similarity index 60% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillExtrusionLayerManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillExtrusionLayerManager.java index eb63759d8..79545d447 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillExtrusionLayerManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillExtrusionLayerManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import com.facebook.react.bridge.ReactApplicationContext; import com.facebook.react.bridge.ReadableArray; @@ -6,7 +6,7 @@ import com.facebook.react.uimanager.ThemedReactContext; import com.facebook.react.uimanager.ViewGroupManager; import com.facebook.react.uimanager.annotations.ReactProp; -import com.mapbox.rctmgl.components.AbstractEventEmitter; +import com.maplibre.rctmln.components.AbstractEventEmitter; import java.util.HashMap; import java.util.Map; @@ -15,8 +15,8 @@ * Created by nickitaliano on 9/15/17. */ -public class RCTMGLFillExtrusionLayerManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLFillExtrusionLayer"; +public class RCTMLNFillExtrusionLayerManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNFillExtrusionLayer"; @Override public String getName() { @@ -24,57 +24,57 @@ public String getName() { } @Override - protected RCTMGLFillExtrusionLayer createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLFillExtrusionLayer(reactContext); + protected RCTMLNFillExtrusionLayer createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNFillExtrusionLayer(reactContext); } @ReactProp(name="id") - public void setId(RCTMGLFillExtrusionLayer layer, String id) { + public void setId(RCTMLNFillExtrusionLayer layer, String id) { layer.setID(id); } @ReactProp(name="sourceID") - public void setSourceID(RCTMGLFillExtrusionLayer layer, String sourceID) { + public void setSourceID(RCTMLNFillExtrusionLayer layer, String sourceID) { layer.setSourceID(sourceID); } @ReactProp(name="aboveLayerID") - public void setAboveLayerID(RCTMGLFillExtrusionLayer layer, String aboveLayerID) { + public void setAboveLayerID(RCTMLNFillExtrusionLayer layer, String aboveLayerID) { layer.setAboveLayerID(aboveLayerID); } @ReactProp(name="belowLayerID") - public void setBelowLayerID(RCTMGLFillExtrusionLayer layer, String belowLayerID) { + public void setBelowLayerID(RCTMLNFillExtrusionLayer layer, String belowLayerID) { layer.setBelowLayerID(belowLayerID); } @ReactProp(name="layerIndex") - public void setLayerIndex(RCTMGLFillExtrusionLayer layer, int layerIndex){ + public void setLayerIndex(RCTMLNFillExtrusionLayer layer, int layerIndex){ layer.setLayerIndex(layerIndex); } @ReactProp(name="minZoomLevel") - public void setMinZoomLevel(RCTMGLFillExtrusionLayer layer, double minZoomLevel) { + public void setMinZoomLevel(RCTMLNFillExtrusionLayer layer, double minZoomLevel) { layer.setMinZoomLevel(minZoomLevel); } @ReactProp(name="maxZoomLevel") - public void setMaxZoomLevel(RCTMGLFillExtrusionLayer layer, double maxZoomLevel) { + public void setMaxZoomLevel(RCTMLNFillExtrusionLayer layer, double maxZoomLevel) { layer.setMaxZoomLevel(maxZoomLevel); } @ReactProp(name="reactStyle") - public void setReactStyle(RCTMGLFillExtrusionLayer layer, ReadableMap style) { + public void setReactStyle(RCTMLNFillExtrusionLayer layer, ReadableMap style) { layer.setReactStyle(style); } @ReactProp(name="sourceLayerID") - public void setSourceLayerId(RCTMGLFillExtrusionLayer layer, String sourceLayerID) { + public void setSourceLayerId(RCTMLNFillExtrusionLayer layer, String sourceLayerID) { layer.setSourceLayerID(sourceLayerID); } @ReactProp(name="filter") - public void setFilter(RCTMGLFillExtrusionLayer layer, ReadableArray filterList) { + public void setFilter(RCTMLNFillExtrusionLayer layer, ReadableArray filterList) { layer.setFilter(filterList); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillLayer.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillLayer.java similarity index 67% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillLayer.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillLayer.java index ccb1d1fa9..8d43d5198 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillLayer.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillLayer.java @@ -1,21 +1,21 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import android.content.Context; import com.mapbox.mapboxsdk.style.expressions.Expression; import com.mapbox.mapboxsdk.style.layers.FillLayer; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.components.styles.RCTMGLStyle; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleFactory; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.components.styles.RCTMLNStyle; +import com.maplibre.rctmln.components.styles.RCTMLNStyleFactory; /** * Created by nickitaliano on 9/8/17. */ -public class RCTMGLFillLayer extends RCTLayer { +public class RCTMLNFillLayer extends RCTLayer { private String mSourceLayerID; - public RCTMGLFillLayer(Context context) { + public RCTMLNFillLayer(Context context) { super(context); } @@ -25,7 +25,7 @@ protected void updateFilter(Expression expression) { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { super.addToMap(mapView); } @@ -42,7 +42,7 @@ public FillLayer makeLayer() { @Override public void addStyles() { - RCTMGLStyleFactory.setFillLayerStyle(mLayer, new RCTMGLStyle(getContext(), mReactStyle, mMap)); + RCTMLNStyleFactory.setFillLayerStyle(mLayer, new RCTMLNStyle(getContext(), mReactStyle, mMap)); } public void setSourceLayerID(String sourceLayerID) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillLayerManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillLayerManager.java similarity index 59% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillLayerManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillLayerManager.java index 30ad8d06f..48974e150 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLFillLayerManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNFillLayerManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import com.facebook.react.bridge.ReactApplicationContext; import com.facebook.react.bridge.ReadableArray; @@ -6,7 +6,7 @@ import com.facebook.react.uimanager.ThemedReactContext; import com.facebook.react.uimanager.ViewGroupManager; import com.facebook.react.uimanager.annotations.ReactProp; -import com.mapbox.rctmgl.components.AbstractEventEmitter; +import com.maplibre.rctmln.components.AbstractEventEmitter; import java.util.HashMap; import java.util.Map; @@ -15,8 +15,8 @@ * Created by nickitaliano on 9/8/17. */ -public class RCTMGLFillLayerManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLFillLayer"; +public class RCTMLNFillLayerManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNFillLayer"; @Override public String getName() { @@ -24,57 +24,57 @@ public String getName() { } @Override - protected RCTMGLFillLayer createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLFillLayer(reactContext); + protected RCTMLNFillLayer createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNFillLayer(reactContext); } @ReactProp(name="id") - public void setId(RCTMGLFillLayer layer, String id) { + public void setId(RCTMLNFillLayer layer, String id) { layer.setID(id); } @ReactProp(name="sourceID") - public void setSourceID(RCTMGLFillLayer layer, String sourceID) { + public void setSourceID(RCTMLNFillLayer layer, String sourceID) { layer.setSourceID(sourceID); } @ReactProp(name="sourceLayerID") - public void setSourceLayerId(RCTMGLFillLayer layer, String sourceLayerID) { + public void setSourceLayerId(RCTMLNFillLayer layer, String sourceLayerID) { layer.setSourceLayerID(sourceLayerID); } @ReactProp(name="aboveLayerID") - public void setAboveLayerID(RCTMGLFillLayer layer, String aboveLayerID) { + public void setAboveLayerID(RCTMLNFillLayer layer, String aboveLayerID) { layer.setAboveLayerID(aboveLayerID); } @ReactProp(name="belowLayerID") - public void setBelowLayerID(RCTMGLFillLayer layer, String belowLayerID) { + public void setBelowLayerID(RCTMLNFillLayer layer, String belowLayerID) { layer.setBelowLayerID(belowLayerID); } @ReactProp(name="layerIndex") - public void setLayerIndex(RCTMGLFillLayer layer, int layerIndex){ + public void setLayerIndex(RCTMLNFillLayer layer, int layerIndex){ layer.setLayerIndex(layerIndex); } @ReactProp(name="minZoomLevel") - public void setMinZoomLevel(RCTMGLFillLayer layer, double minZoomLevel) { + public void setMinZoomLevel(RCTMLNFillLayer layer, double minZoomLevel) { layer.setMinZoomLevel(minZoomLevel); } @ReactProp(name="maxZoomLevel") - public void setMaxZoomLevel(RCTMGLFillLayer layer, double maxZoomLevel) { + public void setMaxZoomLevel(RCTMLNFillLayer layer, double maxZoomLevel) { layer.setMaxZoomLevel(maxZoomLevel); } @ReactProp(name="reactStyle") - public void setReactStyle(RCTMGLFillLayer layer, ReadableMap style) { + public void setReactStyle(RCTMLNFillLayer layer, ReadableMap style) { layer.setReactStyle(style); } @ReactProp(name="filter") - public void setFilter(RCTMGLFillLayer layer, ReadableArray filterList) { + public void setFilter(RCTMLNFillLayer layer, ReadableArray filterList) { layer.setFilter(filterList); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLHeatmapLayer.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNHeatmapLayer.java similarity index 64% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLHeatmapLayer.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNHeatmapLayer.java index 734160a98..5cec0aafa 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLHeatmapLayer.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNHeatmapLayer.java @@ -1,21 +1,21 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import android.content.Context; import com.mapbox.mapboxsdk.style.expressions.Expression; import com.mapbox.mapboxsdk.style.layers.HeatmapLayer; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.components.styles.RCTMGLStyle; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleFactory; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.components.styles.RCTMLNStyle; +import com.maplibre.rctmln.components.styles.RCTMLNStyleFactory; /** * Created by dhee9000 on 6/8/2019 */ -public class RCTMGLHeatmapLayer extends RCTLayer { +public class RCTMLNHeatmapLayer extends RCTLayer { private String mSourceLayerID; - public RCTMGLHeatmapLayer(Context context){ + public RCTMLNHeatmapLayer(Context context){ super(context); } @@ -25,7 +25,7 @@ protected void updateFilter(Expression expression) { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { super.addToMap(mapView); } @@ -42,7 +42,7 @@ public HeatmapLayer makeLayer() { @Override public void addStyles() { - RCTMGLStyleFactory.setHeatmapLayerStyle(mLayer, new RCTMGLStyle(getContext(), mReactStyle, mMap)); + RCTMLNStyleFactory.setHeatmapLayerStyle(mLayer, new RCTMLNStyle(getContext(), mReactStyle, mMap)); } public void setSourceLayerID(String sourceLayerID) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLHeatmapLayerManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNHeatmapLayerManager.java similarity index 57% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLHeatmapLayerManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNHeatmapLayerManager.java index c6149e574..d64c0d554 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLHeatmapLayerManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNHeatmapLayerManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import com.facebook.react.bridge.ReadableArray; import com.facebook.react.bridge.ReadableMap; @@ -12,8 +12,8 @@ * Created by dhee9000 on 6/8/2019 */ -public class RCTMGLHeatmapLayerManager extends ViewGroupManager{ - public static final String REACT_CLASS = "RCTMGLHeatmapLayer"; +public class RCTMLNHeatmapLayerManager extends ViewGroupManager{ + public static final String REACT_CLASS = "RCTMLNHeatmapLayer"; @Override public String getName() { @@ -21,57 +21,57 @@ public String getName() { } @Override - protected RCTMGLHeatmapLayer createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLHeatmapLayer(reactContext); + protected RCTMLNHeatmapLayer createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNHeatmapLayer(reactContext); } @ReactProp(name="id") - public void setId(RCTMGLHeatmapLayer layer, String id) { + public void setId(RCTMLNHeatmapLayer layer, String id) { layer.setID(id); } @ReactProp(name="sourceID") - public void setSourceID(RCTMGLHeatmapLayer layer, String sourceID) { + public void setSourceID(RCTMLNHeatmapLayer layer, String sourceID) { layer.setSourceID(sourceID); } @ReactProp(name="aboveLayerID") - public void setAboveLayerID(RCTMGLHeatmapLayer layer, String aboveLayerID) { + public void setAboveLayerID(RCTMLNHeatmapLayer layer, String aboveLayerID) { layer.setAboveLayerID(aboveLayerID); } @ReactProp(name="belowLayerID") - public void setBelowLayerID(RCTMGLHeatmapLayer layer, String belowLayerID) { + public void setBelowLayerID(RCTMLNHeatmapLayer layer, String belowLayerID) { layer.setBelowLayerID(belowLayerID); } @ReactProp(name="layerIndex") - public void setLayerIndex(RCTMGLHeatmapLayer layer, int layerIndex){ + public void setLayerIndex(RCTMLNHeatmapLayer layer, int layerIndex){ layer.setLayerIndex(layerIndex); } @ReactProp(name="minZoomLevel") - public void setMinZoomLevel(RCTMGLHeatmapLayer layer, double minZoomLevel) { + public void setMinZoomLevel(RCTMLNHeatmapLayer layer, double minZoomLevel) { layer.setMinZoomLevel(minZoomLevel); } @ReactProp(name="maxZoomLevel") - public void setMaxZoomLevel(RCTMGLHeatmapLayer layer, double maxZoomLevel) { + public void setMaxZoomLevel(RCTMLNHeatmapLayer layer, double maxZoomLevel) { layer.setMaxZoomLevel(maxZoomLevel); } @ReactProp(name="reactStyle") - public void setReactStyle(RCTMGLHeatmapLayer layer, ReadableMap style) { + public void setReactStyle(RCTMLNHeatmapLayer layer, ReadableMap style) { layer.setReactStyle(style); } @ReactProp(name="sourceLayerID") - public void setSourceLayerId(RCTMGLHeatmapLayer layer, String sourceLayerID) { + public void setSourceLayerId(RCTMLNHeatmapLayer layer, String sourceLayerID) { layer.setSourceLayerID(sourceLayerID); } @ReactProp(name="filter") - public void setFilter(RCTMGLHeatmapLayer layer, ReadableArray filterList) { + public void setFilter(RCTMLNHeatmapLayer layer, ReadableArray filterList) { layer.setFilter(filterList); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLLineLayer.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNLineLayer.java similarity index 67% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLLineLayer.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNLineLayer.java index 5f1d4c6bc..4258a4086 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLLineLayer.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNLineLayer.java @@ -1,21 +1,21 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import android.content.Context; import com.mapbox.mapboxsdk.style.expressions.Expression; import com.mapbox.mapboxsdk.style.layers.LineLayer; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.components.styles.RCTMGLStyle; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleFactory; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.components.styles.RCTMLNStyle; +import com.maplibre.rctmln.components.styles.RCTMLNStyleFactory; /** * Created by nickitaliano on 9/18/17. */ -public class RCTMGLLineLayer extends RCTLayer { +public class RCTMLNLineLayer extends RCTLayer { private String mSourceLayerID; - public RCTMGLLineLayer(Context context) { + public RCTMLNLineLayer(Context context) { super(context); } @@ -25,7 +25,7 @@ protected void updateFilter(Expression expression) { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { super.addToMap(mapView); } @@ -42,7 +42,7 @@ public LineLayer makeLayer() { @Override public void addStyles() { - RCTMGLStyleFactory.setLineLayerStyle(mLayer, new RCTMGLStyle(getContext(), mReactStyle, mMap)); + RCTMLNStyleFactory.setLineLayerStyle(mLayer, new RCTMLNStyle(getContext(), mReactStyle, mMap)); } public void setSourceLayerID(String sourceLayerID) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLLineLayerManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNLineLayerManager.java similarity index 56% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLLineLayerManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNLineLayerManager.java index 5c983d0c0..505a1d139 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLLineLayerManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNLineLayerManager.java @@ -1,12 +1,12 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import com.facebook.react.bridge.ReadableArray; import com.facebook.react.bridge.ReadableMap; import com.facebook.react.uimanager.ThemedReactContext; import com.facebook.react.uimanager.ViewGroupManager; import com.facebook.react.uimanager.annotations.ReactProp; -import com.mapbox.rctmgl.components.AbstractEventEmitter; -import com.mapbox.rctmgl.components.AbstractMapFeature; +import com.maplibre.rctmln.components.AbstractEventEmitter; +import com.maplibre.rctmln.components.AbstractMapFeature; import java.util.Map; @@ -14,8 +14,8 @@ * Created by nickitaliano on 9/18/17. */ -public class RCTMGLLineLayerManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLLineLayer"; +public class RCTMLNLineLayerManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNLineLayer"; @Override public String getName() { @@ -23,57 +23,57 @@ public String getName() { } @Override - protected RCTMGLLineLayer createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLLineLayer(reactContext); + protected RCTMLNLineLayer createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNLineLayer(reactContext); } @ReactProp(name="id") - public void setId(RCTMGLLineLayer layer, String id) { + public void setId(RCTMLNLineLayer layer, String id) { layer.setID(id); } @ReactProp(name="sourceID") - public void setSourceID(RCTMGLLineLayer layer, String sourceID) { + public void setSourceID(RCTMLNLineLayer layer, String sourceID) { layer.setSourceID(sourceID); } @ReactProp(name="aboveLayerID") - public void setAboveLayerID(RCTMGLLineLayer layer, String aboveLayerID) { + public void setAboveLayerID(RCTMLNLineLayer layer, String aboveLayerID) { layer.setAboveLayerID(aboveLayerID); } @ReactProp(name="belowLayerID") - public void setBelowLayerID(RCTMGLLineLayer layer, String belowLayerID) { + public void setBelowLayerID(RCTMLNLineLayer layer, String belowLayerID) { layer.setBelowLayerID(belowLayerID); } @ReactProp(name="layerIndex") - public void setLayerIndex(RCTMGLLineLayer layer, int layerIndex){ + public void setLayerIndex(RCTMLNLineLayer layer, int layerIndex){ layer.setLayerIndex(layerIndex); } @ReactProp(name="minZoomLevel") - public void setMinZoomLevel(RCTMGLLineLayer layer, double minZoomLevel) { + public void setMinZoomLevel(RCTMLNLineLayer layer, double minZoomLevel) { layer.setMinZoomLevel(minZoomLevel); } @ReactProp(name="maxZoomLevel") - public void setMaxZoomLevel(RCTMGLLineLayer layer, double maxZoomLevel) { + public void setMaxZoomLevel(RCTMLNLineLayer layer, double maxZoomLevel) { layer.setMaxZoomLevel(maxZoomLevel); } @ReactProp(name="reactStyle") - public void setReactStyle(RCTMGLLineLayer layer, ReadableMap style) { + public void setReactStyle(RCTMLNLineLayer layer, ReadableMap style) { layer.setReactStyle(style); } @ReactProp(name="sourceLayerID") - public void setSourceLayerId(RCTMGLLineLayer layer, String sourceLayerID) { + public void setSourceLayerId(RCTMLNLineLayer layer, String sourceLayerID) { layer.setSourceLayerID(sourceLayerID); } @ReactProp(name="filter") - public void setFilter(RCTMGLLineLayer layer, ReadableArray filterList) { + public void setFilter(RCTMLNLineLayer layer, ReadableArray filterList) { layer.setFilter(filterList); } } diff --git a/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNRasterLayer.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNRasterLayer.java new file mode 100644 index 000000000..234532fa1 --- /dev/null +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNRasterLayer.java @@ -0,0 +1,27 @@ +package com.maplibre.rctmln.components.styles.layers; + +import android.content.Context; + +import com.mapbox.mapboxsdk.style.layers.RasterLayer; +import com.maplibre.rctmln.components.styles.RCTMLNStyle; +import com.maplibre.rctmln.components.styles.RCTMLNStyleFactory; + +/** + * Created by nickitaliano on 9/25/17. + */ + +public class RCTMLNRasterLayer extends RCTLayer { + public RCTMLNRasterLayer(Context context) { + super(context); + } + + @Override + public RasterLayer makeLayer() { + return new RasterLayer(mID, mSourceID); + } + + @Override + public void addStyles() { + RCTMLNStyleFactory.setRasterLayerStyle(mLayer, new RCTMLNStyle(getContext(), mReactStyle, mMap)); + } +} diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLRasterLayerManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNRasterLayerManager.java similarity index 57% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLRasterLayerManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNRasterLayerManager.java index 746031b9e..a5a7a76a6 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLRasterLayerManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNRasterLayerManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import com.facebook.react.bridge.ReadableMap; import com.facebook.react.uimanager.ThemedReactContext; @@ -9,8 +9,8 @@ * Created by nickitaliano on 9/25/17. */ -public class RCTMGLRasterLayerManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLRasterLayer"; +public class RCTMLNRasterLayerManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNRasterLayer"; @Override public String getName() { @@ -18,47 +18,47 @@ public String getName() { } @Override - protected RCTMGLRasterLayer createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLRasterLayer(reactContext); + protected RCTMLNRasterLayer createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNRasterLayer(reactContext); } @ReactProp(name="id") - public void setId(RCTMGLRasterLayer layer, String id) { + public void setId(RCTMLNRasterLayer layer, String id) { layer.setID(id); } @ReactProp(name="sourceID") - public void setSourceID(RCTMGLRasterLayer layer, String sourceID) { + public void setSourceID(RCTMLNRasterLayer layer, String sourceID) { layer.setSourceID(sourceID); } @ReactProp(name="aboveLayerID") - public void setAboveLayerID(RCTMGLRasterLayer layer, String aboveLayerID) { + public void setAboveLayerID(RCTMLNRasterLayer layer, String aboveLayerID) { layer.setAboveLayerID(aboveLayerID); } @ReactProp(name="belowLayerID") - public void setBelowLayerID(RCTMGLRasterLayer layer, String belowLayerID) { + public void setBelowLayerID(RCTMLNRasterLayer layer, String belowLayerID) { layer.setBelowLayerID(belowLayerID); } @ReactProp(name="layerIndex") - public void setLayerIndex(RCTMGLRasterLayer layer, int layerIndex){ + public void setLayerIndex(RCTMLNRasterLayer layer, int layerIndex){ layer.setLayerIndex(layerIndex); } @ReactProp(name="minZoomLevel") - public void setMinZoomLevel(RCTMGLRasterLayer layer, double minZoomLevel) { + public void setMinZoomLevel(RCTMLNRasterLayer layer, double minZoomLevel) { layer.setMinZoomLevel(minZoomLevel); } @ReactProp(name="maxZoomLevel") - public void setMaxZoomLevel(RCTMGLRasterLayer layer, double maxZoomLevel) { + public void setMaxZoomLevel(RCTMLNRasterLayer layer, double maxZoomLevel) { layer.setMaxZoomLevel(maxZoomLevel); } @ReactProp(name="reactStyle") - public void setReactStyle(RCTMGLRasterLayer layer, ReadableMap style) { + public void setReactStyle(RCTMLNRasterLayer layer, ReadableMap style) { layer.setReactStyle(style); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLSymbolLayer.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNSymbolLayer.java similarity index 64% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLSymbolLayer.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNSymbolLayer.java index 95106790c..76307fe4b 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLSymbolLayer.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNSymbolLayer.java @@ -1,21 +1,21 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import android.content.Context; import com.mapbox.mapboxsdk.style.expressions.Expression; import com.mapbox.mapboxsdk.style.layers.SymbolLayer; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.components.styles.RCTMGLStyle; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleFactory; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.components.styles.RCTMLNStyle; +import com.maplibre.rctmln.components.styles.RCTMLNStyleFactory; /** * Created by nickitaliano on 9/19/17. */ -public class RCTMGLSymbolLayer extends RCTLayer { +public class RCTMLNSymbolLayer extends RCTLayer { private String mSourceLayerID; - public RCTMGLSymbolLayer(Context context) { + public RCTMLNSymbolLayer(Context context) { super(context); } @@ -25,7 +25,7 @@ protected void updateFilter(Expression expression) { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { super.addToMap(mapView); } @@ -42,7 +42,7 @@ public SymbolLayer makeLayer() { @Override public void addStyles() { - RCTMGLStyleFactory.setSymbolLayerStyle(mLayer, new RCTMGLStyle(getContext(), mReactStyle, mMap)); + RCTMLNStyleFactory.setSymbolLayerStyle(mLayer, new RCTMLNStyle(getContext(), mReactStyle, mMap)); } public void setSourceLayerID(String sourceLayerID) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLSymbolLayerManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNSymbolLayerManager.java similarity index 59% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLSymbolLayerManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNSymbolLayerManager.java index ac99610cb..c3254b0fc 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/layers/RCTMGLSymbolLayerManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/layers/RCTMLNSymbolLayerManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.layers; +package com.maplibre.rctmln.components.styles.layers; import com.facebook.react.bridge.ReadableArray; import com.facebook.react.bridge.ReadableMap; @@ -10,8 +10,8 @@ * Created by nickitaliano on 9/19/17. */ -public class RCTMGLSymbolLayerManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLSymbolLayer"; +public class RCTMLNSymbolLayerManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNSymbolLayer"; @Override public String getName() { @@ -19,57 +19,57 @@ public String getName() { } @Override - protected RCTMGLSymbolLayer createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLSymbolLayer(reactContext); + protected RCTMLNSymbolLayer createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNSymbolLayer(reactContext); } @ReactProp(name="id") - public void setId(RCTMGLSymbolLayer layer, String id) { + public void setId(RCTMLNSymbolLayer layer, String id) { layer.setID(id); } @ReactProp(name="sourceID") - public void setSourceID(RCTMGLSymbolLayer layer, String sourceID) { + public void setSourceID(RCTMLNSymbolLayer layer, String sourceID) { layer.setSourceID(sourceID); } @ReactProp(name="aboveLayerID") - public void setAboveLayerID(RCTMGLSymbolLayer layer, String aboveLayerID) { + public void setAboveLayerID(RCTMLNSymbolLayer layer, String aboveLayerID) { layer.setAboveLayerID(aboveLayerID); } @ReactProp(name="belowLayerID") - public void setBelowLayerID(RCTMGLSymbolLayer layer, String belowLayerID) { + public void setBelowLayerID(RCTMLNSymbolLayer layer, String belowLayerID) { layer.setBelowLayerID(belowLayerID); } @ReactProp(name="layerIndex") - public void setLayerIndex(RCTMGLSymbolLayer layer, int layerIndex){ + public void setLayerIndex(RCTMLNSymbolLayer layer, int layerIndex){ layer.setLayerIndex(layerIndex); } @ReactProp(name="minZoomLevel") - public void setMinZoomLevel(RCTMGLSymbolLayer layer, double minZoomLevel) { + public void setMinZoomLevel(RCTMLNSymbolLayer layer, double minZoomLevel) { layer.setMinZoomLevel(minZoomLevel); } @ReactProp(name="maxZoomLevel") - public void setMaxZoomLevel(RCTMGLSymbolLayer layer, double maxZoomLevel) { + public void setMaxZoomLevel(RCTMLNSymbolLayer layer, double maxZoomLevel) { layer.setMaxZoomLevel(maxZoomLevel); } @ReactProp(name="reactStyle") - public void setReactStyle(RCTMGLSymbolLayer layer, ReadableMap style) { + public void setReactStyle(RCTMLNSymbolLayer layer, ReadableMap style) { layer.setReactStyle(style); } @ReactProp(name="sourceLayerID") - public void setSourceLayerId(RCTMGLSymbolLayer layer, String sourceLayerID) { + public void setSourceLayerId(RCTMLNSymbolLayer layer, String sourceLayerID) { layer.setSourceLayerID(sourceLayerID); } @ReactProp(name="filter") - public void setFilter(RCTMGLSymbolLayer layer, ReadableArray filterList) { + public void setFilter(RCTMLNSymbolLayer layer, ReadableArray filterList) { layer.setFilter(filterList); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/light/RCTMGLLight.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/light/RCTMLNLight.java similarity index 67% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/light/RCTMGLLight.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/light/RCTMLNLight.java index bc0342860..4d48ce6d0 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/light/RCTMGLLight.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/light/RCTMLNLight.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.light; +package com.maplibre.rctmln.components.styles.light; import android.content.Context; @@ -8,10 +8,10 @@ import com.mapbox.mapboxsdk.style.layers.TransitionOptions; import com.mapbox.mapboxsdk.style.light.Light; import com.mapbox.mapboxsdk.style.light.Position; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.components.styles.RCTMGLStyle; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleFactory; +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.components.styles.RCTMLNStyle; +import com.maplibre.rctmln.components.styles.RCTMLNStyleFactory; import java.util.HashMap; import java.util.Map; @@ -20,22 +20,22 @@ * Created by nickitaliano on 9/26/17. */ -public class RCTMGLLight extends AbstractMapFeature { +public class RCTMLNLight extends AbstractMapFeature { private MapboxMap mMap; private ReadableMap mReactStyle; - public RCTMGLLight(Context context) { + public RCTMLNLight(Context context) { super(context); } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { mMap = mapView.getMapboxMap(); setLight(); } @Override - public void removeFromMap(RCTMGLMapView mapView) { + public void removeFromMap(RCTMLNMapView mapView) { // ignore there's nothing to remove just update the light style } @@ -46,7 +46,7 @@ public void setReactStyle(ReadableMap reactStyle) { } private void setLight(Light light) { - RCTMGLStyleFactory.setLightLayerStyle(light, new RCTMGLStyle(getContext(), mReactStyle, mMap)); + RCTMLNStyleFactory.setLightLayerStyle(light, new RCTMLNStyle(getContext(), mReactStyle, mMap)); } private void setLight() { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/light/RCTMGLLightManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/light/RCTMLNLightManager.java similarity index 57% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/light/RCTMGLLightManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/light/RCTMLNLightManager.java index 069294ffc..265e19468 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/light/RCTMGLLightManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/light/RCTMLNLightManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.light; +package com.maplibre.rctmln.components.styles.light; import com.facebook.react.bridge.ReadableMap; import com.facebook.react.uimanager.ThemedReactContext; @@ -9,8 +9,8 @@ * Created by nickitaliano on 9/26/17. */ -public class RCTMGLLightManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLLight"; +public class RCTMLNLightManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNLight"; @Override public String getName() { @@ -18,12 +18,12 @@ public String getName() { } @Override - protected RCTMGLLight createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLLight(reactContext); + protected RCTMLNLight createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNLight(reactContext); } @ReactProp(name="reactStyle") - public void setReactStyle(RCTMGLLight light, ReadableMap reactStyle) { + public void setReactStyle(RCTMLNLight light, ReadableMap reactStyle) { light.setReactStyle(reactStyle); } } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLImageSource.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNImageSource.java similarity index 89% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLImageSource.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNImageSource.java index d39c22ef3..721b2cbcc 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLImageSource.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNImageSource.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import android.content.Context; import android.util.Log; @@ -18,14 +18,14 @@ * Created by nickitaliano on 11/29/17. */ -public class RCTMGLImageSource extends RCTSource { - public static final String LOG_TAG = "RCTMGLImageSource"; +public class RCTMLNImageSource extends RCTSource { + public static final String LOG_TAG = "RCTMLNImageSource"; private URL mURL; private int mResourceId; private LatLngQuad mCoordQuad; - public RCTMGLImageSource(Context context) { + public RCTMLNImageSource(Context context) { super(context); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLImageSourceManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNImageSourceManager.java similarity index 58% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLImageSourceManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNImageSourceManager.java index 0cbc830ed..a7046d734 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLImageSourceManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNImageSourceManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import android.content.Context; import android.view.View; @@ -9,15 +9,15 @@ import com.facebook.react.uimanager.annotations.ReactProp; import com.facebook.react.views.imagehelper.ImageSource; import com.mapbox.mapboxsdk.geometry.LatLngQuad; -import com.mapbox.rctmgl.utils.ConvertUtils; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.utils.ConvertUtils; +import com.maplibre.rctmln.utils.GeoJSONUtils; /** * Created by nickitaliano on 11/29/17. */ -public class RCTMGLImageSourceManager extends ViewGroupManager { - public static final String REACT_CLASS = "RCTMGLImageSource"; +public class RCTMLNImageSourceManager extends ViewGroupManager { + public static final String REACT_CLASS = "RCTMLNImageSource"; @Override public String getName() { @@ -25,42 +25,42 @@ public String getName() { } @Override - protected RCTMGLImageSource createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLImageSource(reactContext); + protected RCTMLNImageSource createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNImageSource(reactContext); } @Override - public View getChildAt(RCTMGLImageSource source, int childPosition) { + public View getChildAt(RCTMLNImageSource source, int childPosition) { return source.getLayerAt(childPosition); } @Override - public int getChildCount(RCTMGLImageSource source) { + public int getChildCount(RCTMLNImageSource source) { return source.getLayerCount(); } @Override - public void addView(RCTMGLImageSource source, View childView, int childPosition) { + public void addView(RCTMLNImageSource source, View childView, int childPosition) { source.addLayer(childView, childPosition); } @Override - public void removeViewAt(RCTMGLImageSource source, int childPosition) { + public void removeViewAt(RCTMLNImageSource source, int childPosition) { source.removeLayer(childPosition); } @ReactProp(name = "id") - public void setId(RCTMGLImageSource source, String id) { + public void setId(RCTMLNImageSource source, String id) { source.setID(id); } @ReactProp(name = "url") - public void setUrl(RCTMGLImageSource source, String url) { + public void setUrl(RCTMLNImageSource source, String url) { source.setURL(url); } @ReactProp(name = "coordinates") - public void setCoordinates(RCTMGLImageSource source, ReadableArray arr) { + public void setCoordinates(RCTMLNImageSource source, ReadableArray arr) { LatLngQuad quad = GeoJSONUtils.toLatLngQuad(arr); if (quad == null) { diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLRasterSource.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNRasterSource.java similarity index 85% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLRasterSource.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNRasterSource.java index 0bd920ddb..b471398c3 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLRasterSource.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNRasterSource.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import android.content.Context; @@ -11,10 +11,10 @@ * Created by nickitaliano on 9/25/17. */ -public class RCTMGLRasterSource extends RCTMGLTileSource { +public class RCTMLNRasterSource extends RCTMLNTileSource { private Integer mTileSize; - public RCTMGLRasterSource(Context context) { + public RCTMLNRasterSource(Context context) { super(context); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLRasterSourceManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNRasterSourceManager.java similarity index 60% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLRasterSourceManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNRasterSourceManager.java index be2392b51..8fa5751d2 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLRasterSourceManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNRasterSourceManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import com.facebook.react.bridge.ReactApplicationContext; import com.facebook.react.uimanager.ThemedReactContext; @@ -13,10 +13,10 @@ * Created by nickitaliano on 9/25/17. */ -public class RCTMGLRasterSourceManager extends RCTMGLTileSourceManager { - public static final String REACT_CLASS = "RCTMGLRasterSource"; +public class RCTMLNRasterSourceManager extends RCTMLNTileSourceManager { + public static final String REACT_CLASS = "RCTMLNRasterSource"; - public RCTMGLRasterSourceManager(ReactApplicationContext reactApplicationContext) { + public RCTMLNRasterSourceManager(ReactApplicationContext reactApplicationContext) { super(reactApplicationContext); } @@ -28,12 +28,12 @@ public String getName() { @Nonnull @Override - protected RCTMGLRasterSource createViewInstance(@Nonnull ThemedReactContext reactContext) { - return new RCTMGLRasterSource(reactContext); + protected RCTMLNRasterSource createViewInstance(@Nonnull ThemedReactContext reactContext) { + return new RCTMLNRasterSource(reactContext); } @ReactProp(name="tileSize") - public void setTileSize(RCTMGLRasterSource source, int tileSize) { + public void setTileSize(RCTMLNRasterSource source, int tileSize) { source.setTileSize(tileSize); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLShapeSource.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNShapeSource.java similarity index 93% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLShapeSource.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNShapeSource.java index 23f878050..340e56b38 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLShapeSource.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNShapeSource.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import android.content.Context; import android.graphics.Bitmap; @@ -18,13 +18,13 @@ import com.mapbox.mapboxsdk.style.sources.GeoJsonOptions; import com.mapbox.mapboxsdk.style.sources.GeoJsonSource; import com.mapbox.mapboxsdk.utils.BitmapUtils; -import com.mapbox.rctmgl.R; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.events.AndroidCallbackEvent; -import com.mapbox.rctmgl.events.FeatureClickEvent; -import com.mapbox.rctmgl.utils.ClusterPropertyEntry; -import com.mapbox.rctmgl.utils.DownloadMapImageTask; -import com.mapbox.rctmgl.utils.ImageEntry; +import com.maplibre.rctmln.R; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.events.AndroidCallbackEvent; +import com.maplibre.rctmln.events.FeatureClickEvent; +import com.maplibre.rctmln.utils.ClusterPropertyEntry; +import com.maplibre.rctmln.utils.DownloadMapImageTask; +import com.maplibre.rctmln.utils.ImageEntry; import java.net.URL; import java.util.ArrayList; @@ -36,9 +36,9 @@ * Created by nickitaliano on 9/19/17. */ -public class RCTMGLShapeSource extends RCTSource { +public class RCTMLNShapeSource extends RCTSource { private URL mURL; - private RCTMGLShapeSourceManager mManager; + private RCTMLNShapeSourceManager mManager; private String mShape; @@ -56,19 +56,19 @@ public class RCTMGLShapeSource extends RCTSource { private List> mImages; private List> mNativeImages; - public RCTMGLShapeSource(Context context, RCTMGLShapeSourceManager manager) { + public RCTMLNShapeSource(Context context, RCTMLNShapeSourceManager manager) { super(context); mManager = manager; } @Override - public void addToMap(final RCTMGLMapView mapView) { + public void addToMap(final RCTMLNMapView mapView) { // Wait for style before adding the source to the map mapView.getMapboxMap().getStyle(new Style.OnStyleLoaded() { @Override public void onStyleLoaded(@NonNull Style style) { MapboxMap map = mapView.getMapboxMap(); - RCTMGLShapeSource.super.addToMap(mapView); + RCTMLNShapeSource.super.addToMap(mapView); } }); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLShapeSourceManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNShapeSourceManager.java similarity index 76% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLShapeSourceManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNShapeSourceManager.java index 3fdf57c81..157e9b39b 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLShapeSourceManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNShapeSourceManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import android.content.Context; import android.graphics.drawable.BitmapDrawable; @@ -19,15 +19,15 @@ import com.facebook.react.uimanager.ViewGroupManager; import com.facebook.react.uimanager.annotations.ReactProp; import com.mapbox.mapboxsdk.style.expressions.Expression; -import com.mapbox.rctmgl.components.AbstractEventEmitter; -import com.mapbox.rctmgl.components.annotation.RCTMGLCallout; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.components.styles.layers.RCTLayer; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.utils.ClusterPropertyEntry; -import com.mapbox.rctmgl.utils.ExpressionParser; -import com.mapbox.rctmgl.utils.ImageEntry; -import com.mapbox.rctmgl.utils.ResourceUtils; +import com.maplibre.rctmln.components.AbstractEventEmitter; +import com.maplibre.rctmln.components.annotation.RCTMLNCallout; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.components.styles.layers.RCTLayer; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.utils.ClusterPropertyEntry; +import com.maplibre.rctmln.utils.ExpressionParser; +import com.maplibre.rctmln.utils.ImageEntry; +import com.maplibre.rctmln.utils.ResourceUtils; import java.net.MalformedURLException; import java.net.URL; @@ -40,13 +40,13 @@ * Created by nickitaliano on 9/19/17. */ -public class RCTMGLShapeSourceManager extends AbstractEventEmitter { - public static final String LOG_TAG = "RCTMGLShapeSourceManager"; - public static final String REACT_CLASS = "RCTMGLShapeSource"; +public class RCTMLNShapeSourceManager extends AbstractEventEmitter { + public static final String LOG_TAG = "RCTMLNShapeSourceManager"; + public static final String REACT_CLASS = "RCTMLNShapeSource"; private ReactApplicationContext mContext; - public RCTMGLShapeSourceManager(ReactApplicationContext context) { + public RCTMLNShapeSourceManager(ReactApplicationContext context) { super(context); mContext = context; } @@ -57,37 +57,37 @@ public String getName() { } @Override - protected RCTMGLShapeSource createViewInstance(ThemedReactContext reactContext) { - return new RCTMGLShapeSource(reactContext, this); + protected RCTMLNShapeSource createViewInstance(ThemedReactContext reactContext) { + return new RCTMLNShapeSource(reactContext, this); } @Override - public View getChildAt(RCTMGLShapeSource source, int childPosition) { + public View getChildAt(RCTMLNShapeSource source, int childPosition) { return source.getLayerAt(childPosition); } @Override - public int getChildCount(RCTMGLShapeSource source) { + public int getChildCount(RCTMLNShapeSource source) { return source.getLayerCount(); } @Override - public void addView(RCTMGLShapeSource source, View childView, int childPosition) { + public void addView(RCTMLNShapeSource source, View childView, int childPosition) { source.addLayer(childView, getChildCount(source)); } @Override - public void removeViewAt(RCTMGLShapeSource source, int childPosition) { + public void removeViewAt(RCTMLNShapeSource source, int childPosition) { source.removeLayer(childPosition); } @ReactProp(name = "id") - public void setId(RCTMGLShapeSource source, String id) { + public void setId(RCTMLNShapeSource source, String id) { source.setID(id); } @ReactProp(name = "url") - public void setURL(RCTMGLShapeSource source, String urlStr) { + public void setURL(RCTMLNShapeSource source, String urlStr) { try { source.setURL(new URL(urlStr)); } catch (MalformedURLException e) { @@ -96,27 +96,27 @@ public void setURL(RCTMGLShapeSource source, String urlStr) { } @ReactProp(name = "shape") - public void setGeometry(RCTMGLShapeSource source, String geoJSONStr) { + public void setGeometry(RCTMLNShapeSource source, String geoJSONStr) { source.setShape(geoJSONStr); } @ReactProp(name = "cluster") - public void setCluster(RCTMGLShapeSource source, int cluster) { + public void setCluster(RCTMLNShapeSource source, int cluster) { source.setCluster(cluster == 1); } @ReactProp(name = "clusterRadius") - public void setClusterRadius(RCTMGLShapeSource source, int radius) { + public void setClusterRadius(RCTMLNShapeSource source, int radius) { source.setClusterRadius(radius); } @ReactProp(name = "clusterMaxZoomLevel") - public void setClusterMaxZoomLevel(RCTMGLShapeSource source, int clusterMaxZoom) { + public void setClusterMaxZoomLevel(RCTMLNShapeSource source, int clusterMaxZoom) { source.setClusterMaxZoom(clusterMaxZoom); } @ReactProp(name = "clusterProperties") - public void setClusterProperties(RCTMGLShapeSource source, ReadableMap map) { + public void setClusterProperties(RCTMLNShapeSource source, ReadableMap map) { List> properties = new ArrayList<>(); ReadableMapKeySetIterator iterator = map.keySetIterator(); @@ -140,32 +140,32 @@ public void setClusterProperties(RCTMGLShapeSource source, ReadableMap map) { } @ReactProp(name = "maxZoomLevel") - public void setMaxZoomLevel(RCTMGLShapeSource source, int maxZoom) { + public void setMaxZoomLevel(RCTMLNShapeSource source, int maxZoom) { source.setMaxZoom(maxZoom); } @ReactProp(name = "buffer") - public void setBuffer(RCTMGLShapeSource source, int buffer) { + public void setBuffer(RCTMLNShapeSource source, int buffer) { source.setBuffer(buffer); } @ReactProp(name = "tolerance") - public void setTolerance(RCTMGLShapeSource source, double tolerance) { + public void setTolerance(RCTMLNShapeSource source, double tolerance) { source.setTolerance(tolerance); } @ReactProp(name = "lineMetrics") - public void setLineMetrics(RCTMGLShapeSource source, boolean lineMetrics) { + public void setLineMetrics(RCTMLNShapeSource source, boolean lineMetrics) { source.setLineMetrics(lineMetrics); } @ReactProp(name = "hasPressListener") - public void setHasPressListener(RCTMGLShapeSource source, boolean hasPressListener) { + public void setHasPressListener(RCTMLNShapeSource source, boolean hasPressListener) { source.setHasPressListener(hasPressListener); } @ReactProp(name="hitbox") - public void setHitbox(RCTMGLShapeSource source, ReadableMap map) { + public void setHitbox(RCTMLNShapeSource source, ReadableMap map) { source.setHitbox(map); } @@ -206,7 +206,7 @@ public Map getCommandsMap() { } @Override - public void receiveCommand(RCTMGLShapeSource source, int commandID, @Nullable ReadableArray args) { + public void receiveCommand(RCTMLNShapeSource source, int commandID, @Nullable ReadableArray args) { switch (commandID) { case METHOD_FEATURES: source.querySourceFeatures( diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLTileSource.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNTileSource.java similarity index 93% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLTileSource.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNTileSource.java index 8a9ed9e2f..bc870884e 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLTileSource.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNTileSource.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import android.content.Context; @@ -8,7 +8,7 @@ import java.util.Collection; @SuppressWarnings("unused") -public abstract class RCTMGLTileSource extends RCTSource { +public abstract class RCTMLNTileSource extends RCTSource { static final String TILE_SPEC_VERSION = "2.1.0"; private String mURL; @@ -20,7 +20,7 @@ public abstract class RCTMGLTileSource extends RCTSource { private boolean mIsTmsSource; - public RCTMGLTileSource(Context context) { + public RCTMLNTileSource(Context context) { super(context); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLTileSourceManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNTileSourceManager.java similarity index 89% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLTileSourceManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNTileSourceManager.java index 2f3ddc29f..a2160da30 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLTileSourceManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNTileSourceManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import android.view.View; @@ -6,14 +6,14 @@ import com.facebook.react.bridge.ReadableArray; import com.facebook.react.bridge.ReadableType; import com.facebook.react.uimanager.annotations.ReactProp; -import com.mapbox.rctmgl.components.AbstractEventEmitter; +import com.maplibre.rctmln.components.AbstractEventEmitter; import java.util.ArrayList; import java.util.List; -public abstract class RCTMGLTileSourceManager extends AbstractEventEmitter { +public abstract class RCTMLNTileSourceManager extends AbstractEventEmitter { - RCTMGLTileSourceManager(ReactApplicationContext reactApplicationContext) { + RCTMLNTileSourceManager(ReactApplicationContext reactApplicationContext) { super(reactApplicationContext); } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLVectorSource.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNVectorSource.java similarity index 85% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLVectorSource.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNVectorSource.java index de69eadc3..8604b3036 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLVectorSource.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNVectorSource.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import android.content.Context; import androidx.annotation.Nullable; @@ -10,8 +10,8 @@ import com.mapbox.geojson.FeatureCollection; import com.mapbox.mapboxsdk.style.expressions.Expression; import com.mapbox.mapboxsdk.style.sources.VectorSource; -import com.mapbox.rctmgl.events.AndroidCallbackEvent; -import com.mapbox.rctmgl.events.FeatureClickEvent; +import com.maplibre.rctmln.events.AndroidCallbackEvent; +import com.maplibre.rctmln.events.FeatureClickEvent; import java.util.List; @@ -19,10 +19,10 @@ * Created by nickitaliano on 9/8/17. */ -public class RCTMGLVectorSource extends RCTMGLTileSource { - private RCTMGLVectorSourceManager mManager; +public class RCTMLNVectorSource extends RCTMLNTileSource { + private RCTMLNVectorSourceManager mManager; - public RCTMGLVectorSource(Context context, RCTMGLVectorSourceManager manager) { + public RCTMLNVectorSource(Context context, RCTMLNVectorSourceManager manager) { super(context); mManager = manager; } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLVectorSourceManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNVectorSourceManager.java similarity index 72% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLVectorSourceManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNVectorSourceManager.java index 33019f2d9..ce1531a4d 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTMGLVectorSourceManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTMLNVectorSourceManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import androidx.annotation.Nullable; @@ -8,9 +8,9 @@ import com.facebook.react.common.MapBuilder; import com.facebook.react.uimanager.ThemedReactContext; import com.facebook.react.uimanager.annotations.ReactProp; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.utils.ConvertUtils; -import com.mapbox.rctmgl.utils.ExpressionParser; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.utils.ConvertUtils; +import com.maplibre.rctmln.utils.ExpressionParser; import javax.annotation.Nonnull; @@ -20,10 +20,10 @@ * Created by nickitaliano on 9/8/17. */ -public class RCTMGLVectorSourceManager extends RCTMGLTileSourceManager { - public static final String REACT_CLASS = "RCTMGLVectorSource"; +public class RCTMLNVectorSourceManager extends RCTMLNTileSourceManager { + public static final String REACT_CLASS = "RCTMLNVectorSource"; - public RCTMGLVectorSourceManager(ReactApplicationContext reactApplicationContext) { + public RCTMLNVectorSourceManager(ReactApplicationContext reactApplicationContext) { super(reactApplicationContext); } @@ -35,17 +35,17 @@ public String getName() { @Nonnull @Override - protected RCTMGLVectorSource createViewInstance(@Nonnull ThemedReactContext reactContext) { - return new RCTMGLVectorSource(reactContext, this); + protected RCTMLNVectorSource createViewInstance(@Nonnull ThemedReactContext reactContext) { + return new RCTMLNVectorSource(reactContext, this); } @ReactProp(name = "hasPressListener") - public void setHasPressListener(RCTMGLVectorSource source, boolean hasPressListener) { + public void setHasPressListener(RCTMLNVectorSource source, boolean hasPressListener) { source.setHasPressListener(hasPressListener); } @ReactProp(name="hitbox") - public void setHitbox(RCTMGLVectorSource source, ReadableMap map) { + public void setHitbox(RCTMLNVectorSource source, ReadableMap map) { source.setHitbox(map); } @@ -69,7 +69,7 @@ public Map getCommandsMap() { } @Override - public void receiveCommand(RCTMGLVectorSource vectorSource, int commandID, @Nullable ReadableArray args) { + public void receiveCommand(RCTMLNVectorSource vectorSource, int commandID, @Nullable ReadableArray args) { switch (commandID) { case METHOD_FEATURES: diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTSource.java b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTSource.java similarity index 94% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTSource.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTSource.java index 6b8d8c197..b963bca22 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/sources/RCTSource.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/components/styles/sources/RCTSource.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.components.styles.sources; +package com.maplibre.rctmln.components.styles.sources; import android.content.Context; import androidx.annotation.NonNull; @@ -14,9 +14,9 @@ import com.mapbox.mapboxsdk.maps.MapboxMap; import com.mapbox.mapboxsdk.maps.Style; import com.mapbox.mapboxsdk.style.sources.Source; -import com.mapbox.rctmgl.components.AbstractMapFeature; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.components.styles.layers.RCTLayer; +import com.maplibre.rctmln.components.AbstractMapFeature; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.components.styles.layers.RCTLayer; import java.util.ArrayList; import java.util.HashMap; @@ -34,7 +34,7 @@ public abstract class RCTSource extends AbstractMapFeature { public static final double DEFAULT_HITBOX_WIDTH = 44.0; public static final double DEFAULT_HITBOX_HEIGHT = 44.0; - protected RCTMGLMapView mMapView; + protected RCTMLNMapView mMapView; protected MapboxMap mMap; protected String mID; @@ -116,7 +116,7 @@ public int getLayerCount () { } @Override - public void addToMap(RCTMGLMapView mapView) { + public void addToMap(RCTMLNMapView mapView) { mMapView = mapView; mMap = mapView.getMapboxMap(); mMap.getStyle(new Style.OnStyleLoaded() { @@ -146,7 +146,7 @@ public void onStyleLoaded(@NonNull Style style) { } @Override - public void removeFromMap(RCTMGLMapView mapView) { + public void removeFromMap(RCTMLNMapView mapView) { if (mLayers.size() > 0) { for (int i = 0; i < mLayers.size(); i++) { RCTLayer layer = mLayers.get(i); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/AbstractEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/AbstractEvent.java similarity index 97% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/AbstractEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/AbstractEvent.java index f11a767ad..e9c1e3dc5 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/AbstractEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/AbstractEvent.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.view.View; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/AndroidCallbackEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/AndroidCallbackEvent.java similarity index 91% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/AndroidCallbackEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/AndroidCallbackEvent.java index 082935cc9..858ed28cc 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/AndroidCallbackEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/AndroidCallbackEvent.java @@ -1,10 +1,10 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.view.View; import com.facebook.react.bridge.WritableArray; import com.facebook.react.bridge.WritableMap; -import com.mapbox.rctmgl.events.constants.EventKeys; +import com.maplibre.rctmln.events.constants.EventKeys; /** * Created by nickitaliano on 10/3/17. diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/EventEmitter.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/EventEmitter.java similarity index 97% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/EventEmitter.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/EventEmitter.java index da009739e..48899805e 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/EventEmitter.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/EventEmitter.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.util.Log; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/FeatureClickEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/FeatureClickEvent.java similarity index 89% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/FeatureClickEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/FeatureClickEvent.java index cd5971a84..e5e5e5cb2 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/FeatureClickEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/FeatureClickEvent.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.graphics.PointF; import android.view.View; @@ -8,11 +8,11 @@ import com.facebook.react.bridge.WritableMap; import com.mapbox.geojson.Feature; import com.mapbox.mapboxsdk.geometry.LatLng; -import com.mapbox.rctmgl.components.styles.sources.RCTSource; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.events.constants.EventTypes; -import com.mapbox.rctmgl.utils.ConvertUtils; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.components.styles.sources.RCTSource; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.events.constants.EventTypes; +import com.maplibre.rctmln.utils.ConvertUtils; +import com.maplibre.rctmln.utils.GeoJSONUtils; import java.util.List; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/IEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/IEvent.java similarity index 90% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/IEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/IEvent.java index 378ea4095..6b11619d0 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/IEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/IEvent.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import com.facebook.react.bridge.WritableMap; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/ImageMissingEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/ImageMissingEvent.java similarity index 87% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/ImageMissingEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/ImageMissingEvent.java index da13915f4..d678d73d8 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/ImageMissingEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/ImageMissingEvent.java @@ -1,9 +1,9 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import com.facebook.react.bridge.WritableMap; import com.facebook.react.bridge.WritableNativeMap; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.events.constants.EventTypes; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.events.constants.EventTypes; import android.view.View; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/LocationEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/LocationEvent.java similarity index 89% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/LocationEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/LocationEvent.java index 91718dc3c..de23160d2 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/LocationEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/LocationEvent.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.location.Location; import androidx.annotation.NonNull; @@ -6,18 +6,18 @@ import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.WritableMap; import com.facebook.react.bridge.WritableNativeMap; -import com.mapbox.rctmgl.components.mapview.RCTMGLMapView; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.events.constants.EventTypes; +import com.maplibre.rctmln.components.mapview.RCTMLNMapView; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.events.constants.EventTypes; import java.util.UUID; public class LocationEvent implements IEvent { private UUID uuid; - private RCTMGLMapView mapView; + private RCTMLNMapView mapView; private Location location; - public LocationEvent(@NonNull Location location, RCTMGLMapView mapView) { + public LocationEvent(@NonNull Location location, RCTMLNMapView mapView) { this.mapView = mapView; this.location = location; this.uuid = UUID.randomUUID(); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/MapChangeEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/MapChangeEvent.java similarity index 85% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/MapChangeEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/MapChangeEvent.java index d7df52232..4e5c037dc 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/MapChangeEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/MapChangeEvent.java @@ -1,11 +1,11 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.view.View; import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.WritableMap; -import com.mapbox.rctmgl.events.constants.EventKeys; +import com.maplibre.rctmln.events.constants.EventKeys; /** * Created by nickitaliano on 8/27/17. @@ -40,7 +40,7 @@ public WritableMap getPayload() { public boolean canCoalesce() { // Make sure EventDispatcher never merges EventKeys.MAP_ONCHANGE events. // This event name is used to emit events with different - // com.mapbox.rctmgl.events.constants.EventTypes which are dispatched separately on + // com.maplibre.rctmln.events.constants.EventTypes which are dispatched separately on // the JS side return false; } diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/MapClickEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/MapClickEvent.java similarity index 87% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/MapClickEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/MapClickEvent.java index 2e439b93e..03da64af9 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/MapClickEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/MapClickEvent.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.graphics.PointF; import androidx.annotation.NonNull; @@ -8,9 +8,9 @@ import com.facebook.react.bridge.WritableNativeMap; import com.mapbox.mapboxsdk.geometry.LatLng; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.events.constants.EventTypes; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.events.constants.EventTypes; +import com.maplibre.rctmln.utils.GeoJSONUtils; /** * Created by nickitaliano on 8/23/17. diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/MapUserTrackingModeEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/MapUserTrackingModeEvent.java similarity index 81% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/MapUserTrackingModeEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/MapUserTrackingModeEvent.java index 6ed86ae3a..cd1a57e1a 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/MapUserTrackingModeEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/MapUserTrackingModeEvent.java @@ -1,12 +1,12 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.view.View; import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.WritableMap; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.events.constants.EventTypes; -import com.mapbox.rctmgl.location.UserTrackingMode; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.events.constants.EventTypes; +import com.maplibre.rctmln.location.UserTrackingMode; /** * Created by nickitaliano on 12/19/17. diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/OfflineEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/OfflineEvent.java similarity index 94% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/OfflineEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/OfflineEvent.java index fbd835587..9047625a3 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/OfflineEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/OfflineEvent.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import com.facebook.react.bridge.ReadableMap; import com.facebook.react.bridge.WritableMap; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/PointAnnotationClickEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/PointAnnotationClickEvent.java similarity index 75% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/PointAnnotationClickEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/PointAnnotationClickEvent.java index c2193f79b..101397c30 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/PointAnnotationClickEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/PointAnnotationClickEvent.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.graphics.PointF; import androidx.annotation.NonNull; @@ -8,22 +8,22 @@ import com.facebook.react.bridge.WritableNativeMap; import com.mapbox.mapboxsdk.plugins.markerview.MarkerView; import com.mapbox.mapboxsdk.geometry.LatLng; -import com.mapbox.rctmgl.components.annotation.RCTMGLPointAnnotation; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.events.constants.EventTypes; -import com.mapbox.rctmgl.utils.ConvertUtils; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.components.annotation.RCTMLNPointAnnotation; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.events.constants.EventTypes; +import com.maplibre.rctmln.utils.ConvertUtils; +import com.maplibre.rctmln.utils.GeoJSONUtils; /** * Created by nickitaliano on 10/11/17. */ public class PointAnnotationClickEvent extends MapClickEvent { - private RCTMGLPointAnnotation mView; + private RCTMLNPointAnnotation mView; private LatLng mTouchedLatLng; private PointF mScreenPoint; - public PointAnnotationClickEvent(RCTMGLPointAnnotation view, @NonNull LatLng latLng, @NonNull PointF screenPoint, String eventType) { + public PointAnnotationClickEvent(RCTMLNPointAnnotation view, @NonNull LatLng latLng, @NonNull PointF screenPoint, String eventType) { super(view, latLng, screenPoint, eventType); mView = view; mTouchedLatLng = latLng; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/PointAnnotationDragEvent.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/PointAnnotationDragEvent.java similarity index 77% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/PointAnnotationDragEvent.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/PointAnnotationDragEvent.java index cc6a26824..b4f2f91b4 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/PointAnnotationDragEvent.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/PointAnnotationDragEvent.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events; +package com.maplibre.rctmln.events; import android.graphics.PointF; import androidx.annotation.NonNull; @@ -8,18 +8,18 @@ import com.facebook.react.bridge.WritableNativeMap; import com.mapbox.mapboxsdk.plugins.markerview.MarkerView; import com.mapbox.mapboxsdk.geometry.LatLng; -import com.mapbox.rctmgl.components.annotation.RCTMGLPointAnnotation; -import com.mapbox.rctmgl.events.constants.EventKeys; -import com.mapbox.rctmgl.events.constants.EventTypes; -import com.mapbox.rctmgl.utils.ConvertUtils; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.components.annotation.RCTMLNPointAnnotation; +import com.maplibre.rctmln.events.constants.EventKeys; +import com.maplibre.rctmln.events.constants.EventTypes; +import com.maplibre.rctmln.utils.ConvertUtils; +import com.maplibre.rctmln.utils.GeoJSONUtils; public class PointAnnotationDragEvent extends MapClickEvent { - RCTMGLPointAnnotation mView; + RCTMLNPointAnnotation mView; private LatLng mTouchedLatLng; private PointF mScreenPoint; - public PointAnnotationDragEvent(RCTMGLPointAnnotation view, @NonNull LatLng latLng, @NonNull PointF screenPoint, String eventType) { + public PointAnnotationDragEvent(RCTMLNPointAnnotation view, @NonNull LatLng latLng, @NonNull PointF screenPoint, String eventType) { super(view, latLng, screenPoint, eventType); mView = view; mTouchedLatLng = latLng; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/constants/EventKeys.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/constants/EventKeys.java similarity index 97% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/constants/EventKeys.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/constants/EventKeys.java index f59c06ccb..d5eba78d4 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/constants/EventKeys.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/constants/EventKeys.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events.constants; +package com.maplibre.rctmln.events.constants; /** * Created by nickitaliano on 8/27/17. diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/constants/EventTypes.java b/android/rctmln/src/main/java/com/maplibre/rctmln/events/constants/EventTypes.java similarity index 98% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/events/constants/EventTypes.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/events/constants/EventTypes.java index aafc72695..a2926055a 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/events/constants/EventTypes.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/events/constants/EventTypes.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.events.constants; +package com.maplibre.rctmln.events.constants; /** * Created by nickitaliano on 8/24/17. diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/http/CustomHeadersInterceptor.java b/android/rctmln/src/main/java/com/maplibre/rctmln/http/CustomHeadersInterceptor.java similarity index 97% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/http/CustomHeadersInterceptor.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/http/CustomHeadersInterceptor.java index 14837aa59..a91a87a0f 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/http/CustomHeadersInterceptor.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/http/CustomHeadersInterceptor.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.http; +package com.maplibre.rctmln.http; import android.util.Log; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/LocationManager.java b/android/rctmln/src/main/java/com/maplibre/rctmln/location/LocationManager.java similarity index 99% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/location/LocationManager.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/location/LocationManager.java index 16dbb387f..e442e3660 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/LocationManager.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/location/LocationManager.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.location; +package com.maplibre.rctmln.location; import android.content.Context; import android.location.Location; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserLocation.java b/android/rctmln/src/main/java/com/maplibre/rctmln/location/UserLocation.java similarity index 97% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserLocation.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/location/UserLocation.java index 343bb3cb1..bbe27b4c7 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserLocation.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/location/UserLocation.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.location; +package com.maplibre.rctmln.location; import android.location.Location; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserLocationVerticalAlignment.java b/android/rctmln/src/main/java/com/maplibre/rctmln/location/UserLocationVerticalAlignment.java similarity index 84% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserLocationVerticalAlignment.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/location/UserLocationVerticalAlignment.java index 4303bcaf8..c25c5dc68 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserLocationVerticalAlignment.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/location/UserLocationVerticalAlignment.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.location; +package com.maplibre.rctmln.location; /** * Created by nickitaliano on 12/13/17. diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserTrackingMode.java b/android/rctmln/src/main/java/com/maplibre/rctmln/location/UserTrackingMode.java similarity index 97% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserTrackingMode.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/location/UserTrackingMode.java index dadc22a7b..2bffbabb3 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserTrackingMode.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/location/UserTrackingMode.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.location; +package com.maplibre.rctmln.location; /* import com.mapbox.mapboxsdk.plugins.locationlayer.modes.RenderMode; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserTrackingState.java b/android/rctmln/src/main/java/com/maplibre/rctmln/location/UserTrackingState.java similarity index 92% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserTrackingState.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/location/UserTrackingState.java index d6e6b8bef..304a8e897 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/location/UserTrackingState.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/location/UserTrackingState.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.location; +package com.maplibre.rctmln.location; /** * Created by nickitaliano on 12/13/17. diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLLocationModule.java b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNLocationModule.java similarity index 91% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLLocationModule.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNLocationModule.java index d4b8cb7d4..f508b5d96 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLLocationModule.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNLocationModule.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.modules; +package com.maplibre.rctmln.modules; import android.location.Location; import androidx.annotation.NonNull; @@ -12,13 +12,13 @@ import com.facebook.react.modules.core.RCTNativeAppEventEmitter; import com.mapbox.mapboxsdk.location.engine.LocationEngineCallback; import com.mapbox.mapboxsdk.location.engine.LocationEngineResult; -import com.mapbox.rctmgl.events.EventEmitter; -import com.mapbox.rctmgl.events.LocationEvent; -import com.mapbox.rctmgl.location.LocationManager; +import com.maplibre.rctmln.events.EventEmitter; +import com.maplibre.rctmln.events.LocationEvent; +import com.maplibre.rctmln.location.LocationManager; -@ReactModule(name = RCTMGLLocationModule.REACT_CLASS) -public class RCTMGLLocationModule extends ReactContextBaseJavaModule { - public static final String REACT_CLASS = "RCTMGLLocationModule"; +@ReactModule(name = RCTMLNLocationModule.REACT_CLASS) +public class RCTMLNLocationModule extends ReactContextBaseJavaModule { + public static final String REACT_CLASS = "RCTMLNLocationModule"; public static final String LOCATION_UPDATE = "MapboxUserLocationUpdate"; private boolean isEnabled; @@ -58,7 +58,7 @@ public void onLocationChange(Location location) { } }; - public RCTMGLLocationModule(ReactApplicationContext reactContext) { + public RCTMLNLocationModule(ReactApplicationContext reactContext) { super(reactContext); locationManager = LocationManager.getInstance(reactContext); reactContext.addLifecycleEventListener(lifecycleEventListener); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLLogging.java b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNLogging.java similarity index 93% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLLogging.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNLogging.java index dbf2ee751..3adf3219f 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLLogging.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNLogging.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.modules; +package com.maplibre.rctmln.modules; import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.ReactApplicationContext; @@ -11,12 +11,12 @@ import com.mapbox.mapboxsdk.log.LoggerDefinition; import android.util.Log; -@ReactModule(name = RCTMGLLogging.REACT_CLASS) -public class RCTMGLLogging extends ReactContextBaseJavaModule { - public static final String REACT_CLASS = "RCTMGLLogging"; +@ReactModule(name = RCTMLNLogging.REACT_CLASS) +public class RCTMLNLogging extends ReactContextBaseJavaModule { + public static final String REACT_CLASS = "RCTMLNLogging"; private ReactApplicationContext mReactContext; - public RCTMGLLogging(ReactApplicationContext reactApplicationContext) { + public RCTMLNLogging(ReactApplicationContext reactApplicationContext) { super(reactApplicationContext); mReactContext = reactApplicationContext; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLModule.java b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNModule.java similarity index 92% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLModule.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNModule.java index a09694a5e..84bd2c09f 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLModule.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNModule.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.modules; +package com.maplibre.rctmln.modules; import android.os.Handler; import android.util.Log; @@ -12,13 +12,13 @@ import com.mapbox.mapboxsdk.Mapbox; import com.mapbox.mapboxsdk.WellKnownTileServer; import com.mapbox.mapboxsdk.style.layers.Property; -import com.mapbox.rctmgl.components.camera.constants.CameraMode; -import com.mapbox.rctmgl.components.styles.RCTMGLStyleValue; -import com.mapbox.rctmgl.components.styles.sources.RCTSource; -import com.mapbox.rctmgl.events.constants.EventTypes; -import com.mapbox.rctmgl.http.CustomHeadersInterceptor; -import com.mapbox.rctmgl.location.UserLocationVerticalAlignment; -import com.mapbox.rctmgl.location.UserTrackingMode; +import com.maplibre.rctmln.components.camera.constants.CameraMode; +import com.maplibre.rctmln.components.styles.RCTMLNStyleValue; +import com.maplibre.rctmln.components.styles.sources.RCTSource; +import com.maplibre.rctmln.events.constants.EventTypes; +import com.maplibre.rctmln.http.CustomHeadersInterceptor; +import com.maplibre.rctmln.location.UserLocationVerticalAlignment; +import com.maplibre.rctmln.location.UserTrackingMode; import okhttp3.Dispatcher; import okhttp3.OkHttpClient; @@ -34,16 +34,16 @@ * Created by nickitaliano on 8/18/17. */ -@ReactModule(name = RCTMGLModule.REACT_CLASS) -public class RCTMGLModule extends ReactContextBaseJavaModule { - public static final String REACT_CLASS = "RCTMGLModule"; +@ReactModule(name = RCTMLNModule.REACT_CLASS) +public class RCTMLNModule extends ReactContextBaseJavaModule { + public static final String REACT_CLASS = "RCTMLNModule"; private static boolean customHeaderInterceptorAdded = false; private Handler mUiThreadHandler; private ReactApplicationContext mReactContext; - public RCTMGLModule(ReactApplicationContext reactApplicationContext) { + public RCTMLNModule(ReactApplicationContext reactApplicationContext) { super(reactApplicationContext); mReactContext = reactApplicationContext; } @@ -105,10 +105,10 @@ public Map getConstants() { // interpolation modes Map interpolationModes = new HashMap<>(); - interpolationModes.put("Exponential", RCTMGLStyleValue.InterpolationModeExponential); - interpolationModes.put("Categorical", RCTMGLStyleValue.InterpolationModeCategorical); - interpolationModes.put("Interval", RCTMGLStyleValue.InterpolationModeInterval); - interpolationModes.put("Identity", RCTMGLStyleValue.InterpolationModeIdentity); + interpolationModes.put("Exponential", RCTMLNStyleValue.InterpolationModeExponential); + interpolationModes.put("Categorical", RCTMLNStyleValue.InterpolationModeCategorical); + interpolationModes.put("Interval", RCTMLNStyleValue.InterpolationModeInterval); + interpolationModes.put("Identity", RCTMLNStyleValue.InterpolationModeIdentity); // line layer constants Map lineJoin = new HashMap<>(); @@ -226,18 +226,18 @@ public Map getConstants() { // offline region download states Map offlinePackDownloadStates = new HashMap<>(); - offlinePackDownloadStates.put("Inactive", RCTMGLOfflineModule.INACTIVE_REGION_DOWNLOAD_STATE); - offlinePackDownloadStates.put("Active", RCTMGLOfflineModule.ACTIVE_REGION_DOWNLOAD_STATE); - offlinePackDownloadStates.put("Complete", RCTMGLOfflineModule.COMPLETE_REGION_DOWNLOAD_STATE); + offlinePackDownloadStates.put("Inactive", RCTMLNOfflineModule.INACTIVE_REGION_DOWNLOAD_STATE); + offlinePackDownloadStates.put("Active", RCTMLNOfflineModule.ACTIVE_REGION_DOWNLOAD_STATE); + offlinePackDownloadStates.put("Complete", RCTMLNOfflineModule.COMPLETE_REGION_DOWNLOAD_STATE); // offline module callback names Map offlineModuleCallbackNames = new HashMap<>(); - offlineModuleCallbackNames.put("Error", RCTMGLOfflineModule.OFFLINE_ERROR); - offlineModuleCallbackNames.put("Progress", RCTMGLOfflineModule.OFFLINE_PROGRESS); + offlineModuleCallbackNames.put("Error", RCTMLNOfflineModule.OFFLINE_ERROR); + offlineModuleCallbackNames.put("Progress", RCTMLNOfflineModule.OFFLINE_PROGRESS); // location module callback names Map locationModuleCallbackNames = new HashMap<>(); - locationModuleCallbackNames.put("Update", RCTMGLLocationModule.LOCATION_UPDATE); + locationModuleCallbackNames.put("Update", RCTMLNLocationModule.LOCATION_UPDATE); return MapBuilder.builder() .put("StyleURL", styleURLS) diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLOfflineModule.java b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNOfflineModule.java similarity index 97% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLOfflineModule.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNOfflineModule.java index 80e714167..2154ad91a 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLOfflineModule.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNOfflineModule.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.modules; +package com.maplibre.rctmln.modules; import android.content.Context; import android.os.Handler; @@ -18,11 +18,11 @@ import com.mapbox.mapboxsdk.offline.OfflineRegionStatus; import com.mapbox.mapboxsdk.offline.OfflineTilePyramidRegionDefinition; import com.mapbox.mapboxsdk.storage.FileSource; -import com.mapbox.rctmgl.events.IEvent; -import com.mapbox.rctmgl.events.OfflineEvent; -import com.mapbox.rctmgl.events.constants.EventTypes; -import com.mapbox.rctmgl.utils.ConvertUtils; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.events.IEvent; +import com.maplibre.rctmln.events.OfflineEvent; +import com.maplibre.rctmln.events.constants.EventTypes; +import com.maplibre.rctmln.utils.ConvertUtils; +import com.maplibre.rctmln.utils.GeoJSONUtils; import com.mapbox.mapboxsdk.maps.Style; import org.json.JSONException; @@ -36,9 +36,9 @@ * Created by nickitaliano on 10/24/17. */ -@ReactModule(name = RCTMGLOfflineModule.REACT_CLASS) -public class RCTMGLOfflineModule extends ReactContextBaseJavaModule { - public static final String REACT_CLASS = "RCTMGLOfflineModule"; +@ReactModule(name = RCTMLNOfflineModule.REACT_CLASS) +public class RCTMLNOfflineModule extends ReactContextBaseJavaModule { + public static final String REACT_CLASS = "RCTMLNOfflineModule"; public static final int INACTIVE_REGION_DOWNLOAD_STATE = OfflineRegion.STATE_INACTIVE; public static final int ACTIVE_REGION_DOWNLOAD_STATE = OfflineRegion.STATE_ACTIVE; @@ -55,7 +55,7 @@ public class RCTMGLOfflineModule extends ReactContextBaseJavaModule { private final ReactContext mReactContext; private Double mProgressEventThrottle = 300.0; - public RCTMGLOfflineModule(ReactApplicationContext reactApplicationContext) { + public RCTMLNOfflineModule(ReactApplicationContext reactApplicationContext) { super(reactApplicationContext); mReactContext = reactApplicationContext; mContext = reactApplicationContext.getApplicationContext(); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLSnapshotModule.java b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNSnapshotModule.java similarity index 92% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLSnapshotModule.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNSnapshotModule.java index 54bd8f668..70fa286a7 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/modules/RCTMGLSnapshotModule.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/modules/RCTMLNSnapshotModule.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.modules; +package com.maplibre.rctmln.modules; import android.content.Context; import android.content.pm.PackageManager; @@ -23,8 +23,8 @@ import com.mapbox.mapboxsdk.snapshotter.MapSnapshot; import com.mapbox.mapboxsdk.snapshotter.MapSnapshotter; import com.mapbox.mapboxsdk.storage.FileSource; -import com.mapbox.rctmgl.utils.BitmapUtils; -import com.mapbox.rctmgl.utils.GeoJSONUtils; +import com.maplibre.rctmln.utils.BitmapUtils; +import com.maplibre.rctmln.utils.GeoJSONUtils; import java.io.IOException; import java.io.OutputStream; @@ -38,16 +38,16 @@ * Created by nickitaliano on 11/30/17. */ -@ReactModule(name = RCTMGLSnapshotModule.REACT_CLASS) -public class RCTMGLSnapshotModule extends ReactContextBaseJavaModule { - public static final String REACT_CLASS = "RCTMGLSnapshotModule"; +@ReactModule(name = RCTMLNSnapshotModule.REACT_CLASS) +public class RCTMLNSnapshotModule extends ReactContextBaseJavaModule { + public static final String REACT_CLASS = "RCTMLNSnapshotModule"; private ReactApplicationContext mContext; // prevents snapshotter from being GC'ed private Map mSnapshotterMap; - public RCTMGLSnapshotModule(ReactApplicationContext reactContext) { + public RCTMLNSnapshotModule(ReactApplicationContext reactContext) { super(reactContext); mContext = reactContext; mSnapshotterMap = new HashMap<>(); diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/BitmapUtils.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/BitmapUtils.java similarity index 99% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/BitmapUtils.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/BitmapUtils.java index 5551bd1e6..f8a93ab56 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/BitmapUtils.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/BitmapUtils.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import android.content.Context; import android.content.res.Resources; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ClusterPropertyEntry.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ClusterPropertyEntry.java similarity index 89% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ClusterPropertyEntry.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/ClusterPropertyEntry.java index bf726f872..a94360d70 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ClusterPropertyEntry.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ClusterPropertyEntry.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import com.mapbox.mapboxsdk.style.expressions.Expression; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ConvertUtils.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ConvertUtils.java similarity index 99% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ConvertUtils.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/ConvertUtils.java index 3c739dd5c..7aa042aa8 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ConvertUtils.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ConvertUtils.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import android.graphics.PointF; import android.graphics.RectF; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/DownloadMapImageTask.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/DownloadMapImageTask.java similarity index 99% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/DownloadMapImageTask.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/DownloadMapImageTask.java index c13fae5bc..507935ed8 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/DownloadMapImageTask.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/DownloadMapImageTask.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import android.content.Context; import android.content.res.Resources; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ExpressionParser.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ExpressionParser.java similarity index 98% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ExpressionParser.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/ExpressionParser.java index d63aa5130..d15c5c5ce 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ExpressionParser.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ExpressionParser.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import com.facebook.react.bridge.Dynamic; import com.facebook.react.bridge.ReadableArray; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/GeoJSONUtils.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/GeoJSONUtils.java similarity index 99% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/GeoJSONUtils.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/GeoJSONUtils.java index 69c917238..d113513dd 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/GeoJSONUtils.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/GeoJSONUtils.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.ReadableArray; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/GeoViewport.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/GeoViewport.java similarity index 97% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/GeoViewport.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/GeoViewport.java index 5580006d0..df4c6b592 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/GeoViewport.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/GeoViewport.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import android.graphics.PointF; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ImageEntry.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ImageEntry.java similarity index 93% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ImageEntry.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/ImageEntry.java index 3f12e832c..917f81c0d 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ImageEntry.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ImageEntry.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; public class ImageEntry { public String uri; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ResourceUtils.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ResourceUtils.java similarity index 95% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ResourceUtils.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/ResourceUtils.java index 6ba704bd7..d4bec0ce4 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/ResourceUtils.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/ResourceUtils.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import android.content.Context; import android.content.res.Resources; diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/SimpleEventCallback.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/SimpleEventCallback.java similarity index 80% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/SimpleEventCallback.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/SimpleEventCallback.java index 8a9f3a413..6fabb91b4 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/SimpleEventCallback.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/SimpleEventCallback.java @@ -1,9 +1,9 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import com.mapbox.mapboxsdk.maps.MapboxMap; -import com.mapbox.rctmgl.components.AbstractEventEmitter; -import com.mapbox.rctmgl.events.IEvent; +import com.maplibre.rctmln.components.AbstractEventEmitter; +import com.maplibre.rctmln.events.IEvent; /** * Created by nickitaliano on 8/31/17. diff --git a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/SphericalMercator.java b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/SphericalMercator.java similarity index 98% rename from android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/SphericalMercator.java rename to android/rctmln/src/main/java/com/maplibre/rctmln/utils/SphericalMercator.java index 7fa665439..0eee5ff3d 100644 --- a/android/rctmgl/src/main/java/com/mapbox/rctmgl/utils/SphericalMercator.java +++ b/android/rctmln/src/main/java/com/maplibre/rctmln/utils/SphericalMercator.java @@ -1,4 +1,4 @@ -package com.mapbox.rctmgl.utils; +package com.maplibre.rctmln.utils; import android.graphics.Point; import android.graphics.PointF; diff --git a/android/rctmgl/src/main/res/drawable-xxhdpi/red_marker.png b/android/rctmln/src/main/res/drawable-xxhdpi/red_marker.png similarity index 100% rename from android/rctmgl/src/main/res/drawable-xxhdpi/red_marker.png rename to android/rctmln/src/main/res/drawable-xxhdpi/red_marker.png diff --git a/android/rctmgl/src/main/res/drawable/empty.xml b/android/rctmln/src/main/res/drawable/empty.xml similarity index 100% rename from android/rctmgl/src/main/res/drawable/empty.xml rename to android/rctmln/src/main/res/drawable/empty.xml diff --git a/android/rctmgl/src/main/res/drawable/empty_drawable.png b/android/rctmln/src/main/res/drawable/empty_drawable.png similarity index 100% rename from android/rctmgl/src/main/res/drawable/empty_drawable.png rename to android/rctmln/src/main/res/drawable/empty_drawable.png diff --git a/android/rctmgl/src/main/res/layout/annotation.xml b/android/rctmln/src/main/res/layout/annotation.xml similarity index 100% rename from android/rctmgl/src/main/res/layout/annotation.xml rename to android/rctmln/src/main/res/layout/annotation.xml diff --git a/android/rctmln/src/main/res/values/strings.xml b/android/rctmln/src/main/res/values/strings.xml new file mode 100644 index 000000000..43880429c --- /dev/null +++ b/android/rctmln/src/main/res/values/strings.xml @@ -0,0 +1,3 @@ + + RCTMLN + diff --git a/android/settings.gradle b/android/settings.gradle index f08cd5202..87270ab06 100644 --- a/android/settings.gradle +++ b/android/settings.gradle @@ -1 +1 @@ -include ':rctmgl' +include ':rctmln' diff --git a/docs/Annotations.md b/docs/Annotations.md index 1c214fa27..0b37063e5 100644 --- a/docs/Annotations.md +++ b/docs/Annotations.md @@ -8,5 +8,5 @@ Comparsion of various annotations available in MapLibre React Native: |Control Z-index | ✓ |iOS: always on top, android: n/a |always on top | ✓ | |Clustering | ✓ | | | ✓ | |Style with expressions | ✓ | | | ✓ | -|iOS implementation | [MGLSymbolStyleLayer](https://maplibre.org/maplibre-gl-native/ios/api/Classes/MGLSymbolStyleLayer.html) |[MGLAnnotationView](https://maplibre.org/maplibre-gl-native/ios/api/Classes/MGLAnnotationView.html) |[MGLAnnotationView](https://maplibre.org/maplibre-gl-native/ios/api/Classes/MGLAnnotationView.html) |[MGLCircleStyleLayer](https://maplibre.org/maplibre-gl-native/ios/api/Classes/MGLCircleStyleLayer.html) | +|iOS implementation | [MLNSymbolStyleLayer](https://maplibre.org/maplibre-gl-native/ios/api/Classes/MLNSymbolStyleLayer.html) |[MLNAnnotationView](https://maplibre.org/maplibre-gl-native/ios/api/Classes/MLNAnnotationView.html) |[MLNAnnotationView](https://maplibre.org/maplibre-gl-native/ios/api/Classes/MLNAnnotationView.html) |[MLNCircleStyleLayer](https://maplibre.org/maplibre-gl-native/ios/api/Classes/MLNCircleStyleLayer.html) | |android implementation | [SymbolLayer](https://maplibre.org/maplibre-gl-native/android/api/com/mapbox/mapboxsdk/style/layers/SymbolLayer.html)|[annotation.Symbol](https://docs.mapbox.com/android/api/plugins/annotation/0.8.0/com/mapbox/mapboxsdk/plugins/annotation/Symbol.html)|[annotation.Marker](https://docs.mapbox.com/android/api/plugins/markerview/0.4.0/com/mapbox/mapboxsdk/plugins/markerview/MarkerView.html) |[CircleLayer](https://maplibre.org/maplibre-gl-native/android/api/com/mapbox/mapboxsdk/style/layers/CircleLayer.html)| diff --git a/docs/Callout.md b/docs/Callout.md index e815f2254..290463ece 100644 --- a/docs/Callout.md +++ b/docs/Callout.md @@ -7,7 +7,7 @@ | ---- | :--: | :-----: | :------: | :----------: | | title | `string` | `none` | `false` | String that get's displayed in the default callout. | | style | `ViewStyle` | `none` | `false` | Style property for the Animated.View wrapper, apply animations to this | -| containerStyle | `ViewStyle` | `none` | `false` | Style property for the native RCTMGLCallout container, set at your own risk. | +| containerStyle | `ViewStyle` | `none` | `false` | Style property for the native RCTMLNCallout container, set at your own risk. | | contentStyle | `ViewStyle` | `none` | `false` | Style property for the content bubble. | | tipStyle | `ViewStyle` | `none` | `false` | Style property for the triangle tip under the content. | | textStyle | `ViewStyle` | `none` | `false` | Style property for the title in the content bubble. | diff --git a/docs/CustomHttpHeaders.md b/docs/CustomHttpHeaders.md index 6286cd756..71379cbe0 100644 --- a/docs/CustomHttpHeaders.md +++ b/docs/CustomHttpHeaders.md @@ -14,14 +14,14 @@ None #### IOS -To enable this on iOS you need to call `[[MGLCustomHeaders sharedInstance] initHeaders]` pretty early in the lifecycle of the application. This will swizzle the custom method. +To enable this on iOS you need to call `[[MLNCustomHeaders sharedInstance] initHeaders]` pretty early in the lifecycle of the application. This will swizzle the custom method. Suggested location is `[AppDelegate application: didFinishLaunchingWithOptions:]` #### Working example (AppDelegate.m) ```obj-c // (1) Include the header file -#import "MGLCustomHeaders.h" +#import "MLNCustomHeaders.h" @implementation AppDelegate @@ -32,9 +32,9 @@ Suggested location is `[AppDelegate application: didFinishLaunchingWithOptions:] moduleName:@"SampleApp" initialProperties:nil]; // (2) Init headers, add swizzle method - [[MGLCustomHeaders sharedInstance] initHeaders]; + [[MLNCustomHeaders sharedInstance] initHeaders]; // (3*) Optionally you can add some global headers here - [[MGLCustomHeaders sharedInstance] addHeader:@"IP" forHeaderName:@"X-For-Real"]; + [[MLNCustomHeaders sharedInstance] addHeader:@"IP" forHeaderName:@"X-For-Real"]; ... return YES; diff --git a/docs/MapView.md b/docs/MapView.md index 506ba65b4..cc342d072 100644 --- a/docs/MapView.md +++ b/docs/MapView.md @@ -9,7 +9,7 @@ | style | `ViewProps['style']` | `none` | `false` | Style for wrapping React Native View | | styleURL | `string` | `none` | `false` | Style URL for map - notice, if non is set it _will_ default to `MapLibreGL.StyleURL.Default` | | styleJSON | `string` | `none` | `false` | StyleJSON for map - according to TileJSON specs: https://github.com/mapbox/tilejson-spec | -| preferredFramesPerSecond | `number` | `none` | `false` | iOS: The preferred frame rate at which the map view is rendered.
The default value for this property is MGLMapViewPreferredFramesPerSecondDefault,
which will adaptively set the preferred frame rate based on the capability of
the user’s device to maintain a smooth experience. This property can be set to arbitrary integer values.

Android: The maximum frame rate at which the map view is rendered, but it can't excess the ability of device hardware.
This property can be set to arbitrary integer values. | +| preferredFramesPerSecond | `number` | `none` | `false` | iOS: The preferred frame rate at which the map view is rendered.
The default value for this property is MLNMapViewPreferredFramesPerSecondDefault,
which will adaptively set the preferred frame rate based on the capability of
the user’s device to maintain a smooth experience. This property can be set to arbitrary integer values.

Android: The maximum frame rate at which the map view is rendered, but it can't excess the ability of device hardware.
This property can be set to arbitrary integer values. | | localizeLabels | `boolean` | `false` | `false` | Automatically change the language of the map labels to the system’s preferred language,
this is not something that can be toggled on/off | | zoomEnabled | `boolean` | `none` | `false` | Enable/Disable zoom on the map | | scrollEnabled | `boolean` | `true` | `false` | Enable/Disable scroll on the map | diff --git a/docs/docs.json b/docs/docs.json index c9017988c..3719c0b13 100644 --- a/docs/docs.json +++ b/docs/docs.json @@ -232,7 +232,7 @@ "required": false, "type": "ViewStyle", "default": "none", - "description": "Style property for the native RCTMGLCallout container, set at your own risk." + "description": "Style property for the native RCTMLNCallout container, set at your own risk." }, { "name": "contentStyle", @@ -2444,7 +2444,7 @@ "required": false, "type": "number", "default": "none", - "description": "iOS: The preferred frame rate at which the map view is rendered.\nThe default value for this property is MGLMapViewPreferredFramesPerSecondDefault,\nwhich will adaptively set the preferred frame rate based on the capability of\nthe user’s device to maintain a smooth experience. This property can be set to arbitrary integer values.\n\nAndroid: The maximum frame rate at which the map view is rendered, but it can't excess the ability of device hardware.\nThis property can be set to arbitrary integer values." + "description": "iOS: The preferred frame rate at which the map view is rendered.\nThe default value for this property is MLNMapViewPreferredFramesPerSecondDefault,\nwhich will adaptively set the preferred frame rate based on the capability of\nthe user’s device to maintain a smooth experience. This property can be set to arbitrary integer values.\n\nAndroid: The maximum frame rate at which the map view is rendered, but it can't excess the ability of device hardware.\nThis property can be set to arbitrary integer values." }, { "name": "localizeLabels", diff --git a/example/android/app/build.gradle b/example/android/app/build.gradle index 36ed79d1c..86a748c1f 100644 --- a/example/android/app/build.gradle +++ b/example/android/app/build.gradle @@ -106,7 +106,7 @@ android { } dependencies { - implementation project(':rctmgl') + implementation project(':rctmln') // The version of react-native is set by the React Native Gradle Plugin implementation("com.facebook.react:react-android") debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") diff --git a/example/android/app/src/main/java/com/rnmaplibreexample/MainApplication.java b/example/android/app/src/main/java/com/rnmaplibreexample/MainApplication.java index 269001ae9..b1d90ce8d 100644 --- a/example/android/app/src/main/java/com/rnmaplibreexample/MainApplication.java +++ b/example/android/app/src/main/java/com/rnmaplibreexample/MainApplication.java @@ -10,7 +10,7 @@ import com.facebook.soloader.SoLoader; import java.util.List; -import com.mapbox.rctmgl.RCTMGLPackage; +import com.maplibre.rctmln.RCTMLNPackage; public class MainApplication extends Application implements ReactApplication { @@ -27,7 +27,7 @@ protected List getPackages() { List packages = new PackageList(this).getPackages(); // Packages that cannot be autolinked yet can be added manually here, for example: // packages.add(new MyReactNativePackage()); - packages.add(new RCTMGLPackage()); + packages.add(new RCTMLNPackage()); return packages; } diff --git a/example/android/settings.gradle b/example/android/settings.gradle index 5e275aec0..acc6a92f2 100644 --- a/example/android/settings.gradle +++ b/example/android/settings.gradle @@ -1,7 +1,7 @@ rootProject.name = 'RNMaplibreExample' -include ':rctmgl' -project(':rctmgl').projectDir = new File(rootProject.projectDir, '../../android/rctmgl') +include ':rctmln' +project(':rctmln').projectDir = new File(rootProject.projectDir, '../../android/rctmln') apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings) includeBuild('../node_modules/@react-native/gradle-plugin') diff --git a/example/ios/Podfile b/example/ios/Podfile index 4c8c3727b..6259698e4 100644 --- a/example/ios/Podfile +++ b/example/ios/Podfile @@ -13,9 +13,9 @@ $RNMBGL_SPM_Spec = { url: "https://github.com/maplibre/maplibre-gl-native-distribution", requirement: { kind: "upToNextMajorVersion", - minimumVersion: "5.11.0" + minimumVersion: "6.4.0" }, - product_name: "Mapbox" + product_name: "MapLibre" } # We ingore warning except for RNMBGL @@ -84,7 +84,8 @@ target 'RNMaplibreExample' do config[:reactNativePath], :mac_catalyst_enabled => false ) - __apply_Xcode_12_5_M1_post_install_workaround(installer) + # This method has been removed in react native 0.73 + # __apply_Xcode_12_5_M1_post_install_workaround(installer) $RNMBGL.post_install(installer) end else diff --git a/example/ios/RNMaplibreExample.xcodeproj/project.pbxproj b/example/ios/RNMaplibreExample.xcodeproj/project.pbxproj index 7d5451919..531e612f8 100644 --- a/example/ios/RNMaplibreExample.xcodeproj/project.pbxproj +++ b/example/ios/RNMaplibreExample.xcodeproj/project.pbxproj @@ -3,16 +3,16 @@ archiveVersion = 1; classes = { }; - objectVersion = 52; + objectVersion = 54; objects = { /* Begin PBXBuildFile section */ 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; }; 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; + 1DC0AFC22BE58DCE00FBCA80 /* MapLibre in Frameworks */ = {isa = PBXBuildFile; productRef = 1DC0AFC12BE58DCE00FBCA80 /* MapLibre */; }; 51C0260825301F99008C5283 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 51C0260725301F99008C5283 /* LaunchScreen.storyboard */; }; AD8CDE4F410D2E699BE7E99D /* libPods-RNMaplibreExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A98F897FA1ECD18EB0F1C4DC /* libPods-RNMaplibreExample.a */; }; - E9DD059E29705D4C0010A116 /* Mapbox in Frameworks */ = {isa = PBXBuildFile; productRef = 80AC8CF095DA4835C83255C8 /* Mapbox */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ @@ -63,7 +63,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - E9DD059E29705D4C0010A116 /* Mapbox in Frameworks */, + 1DC0AFC22BE58DCE00FBCA80 /* MapLibre in Frameworks */, AD8CDE4F410D2E699BE7E99D /* libPods-RNMaplibreExample.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; @@ -197,7 +197,6 @@ 13B07F8C1A680F5B00A75B9A /* Frameworks */, 13B07F8E1A680F5B00A75B9A /* Resources */, 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, - E8948F16DF738C997C01FB08 /* [CP] Embed Pods Frameworks */, 7BC27FFD4688D6914F2322C7 /* [CP] Copy Pods Resources */, ); buildRules = ( @@ -206,7 +205,7 @@ ); name = RNMaplibreExample; packageProductDependencies = ( - 80AC8CF095DA4835C83255C8 /* Mapbox */, + 1DC0AFC12BE58DCE00FBCA80 /* MapLibre */, ); productName = RNMaplibreExample; productReference = 13B07F961A680F5B00A75B9A /* RNMaplibreExample.app */; @@ -268,7 +267,7 @@ ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh"; + shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh\n"; }; 7BC27FFD4688D6914F2322C7 /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; @@ -285,6 +284,9 @@ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome5_Brands.ttf", "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome5_Regular.ttf", "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome5_Solid.ttf", + "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome6_Brands.ttf", + "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome6_Regular.ttf", + "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/FontAwesome6_Solid.ttf", "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Fontisto.ttf", "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Foundation.ttf", "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Ionicons.ttf", @@ -293,7 +295,7 @@ "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Octicons.ttf", "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/SimpleLineIcons.ttf", "${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Zocial.ttf", - "${PODS_CONFIGURATION_BUILD_DIR}/React-Core/AccessibilityResources.bundle", + "${PODS_CONFIGURATION_BUILD_DIR}/React-Core/RCTI18nStrings.bundle", ); name = "[CP] Copy Pods Resources"; outputPaths = ( @@ -305,6 +307,9 @@ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome5_Brands.ttf", "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome5_Regular.ttf", "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome5_Solid.ttf", + "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome6_Brands.ttf", + "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome6_Regular.ttf", + "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/FontAwesome6_Solid.ttf", "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Fontisto.ttf", "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Foundation.ttf", "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Ionicons.ttf", @@ -313,7 +318,7 @@ "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Octicons.ttf", "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/SimpleLineIcons.ttf", "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Zocial.ttf", - "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/AccessibilityResources.bundle", + "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/RCTI18nStrings.bundle", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; @@ -342,28 +347,6 @@ shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; showEnvVarsInLog = 0; }; - E8948F16DF738C997C01FB08 /* [CP] Embed Pods Frameworks */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-RNMaplibreExample/Pods-RNMaplibreExample-frameworks.sh", - "${PODS_XCFRAMEWORKS_BUILD_DIR}/Flipper-DoubleConversion/double-conversion.framework/double-conversion", - "${PODS_XCFRAMEWORKS_BUILD_DIR}/Flipper-Glog/glog.framework/glog", - "${PODS_XCFRAMEWORKS_BUILD_DIR}/OpenSSL-Universal/OpenSSL.framework/OpenSSL", - ); - name = "[CP] Embed Pods Frameworks"; - outputPaths = ( - "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/double-conversion.framework", - "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/glog.framework", - "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/OpenSSL.framework", - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-RNMaplibreExample/Pods-RNMaplibreExample-frameworks.sh\"\n"; - showEnvVarsInLog = 0; - }; FD10A7F022414F080027D42C /* Start Packager */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; @@ -408,7 +391,7 @@ "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64; GCC_PREPROCESSOR_DEFINITIONS = ( "$(inherited)", - "FB_SONARKIT_ENABLED=1", + "FB_SONARKIT_ENABLED=0", ); INFOPLIST_FILE = RNMaplibreExample/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 11.0; @@ -457,7 +440,7 @@ buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; - CLANG_CXX_LANGUAGE_STANDARD = "c++17"; + CLANG_CXX_LANGUAGE_STANDARD = "c++20"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; @@ -514,8 +497,13 @@ ONLY_ACTIVE_ARCH = YES; OTHER_CFLAGS = "$(inherited)"; OTHER_CPLUSPLUSFLAGS = "$(inherited)"; + OTHER_LDFLAGS = ( + "$(inherited)", + " ", + ); REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native"; SDKROOT = iphoneos; + USE_HERMES = false; }; name = Debug; }; @@ -524,7 +512,7 @@ buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; - CLANG_CXX_LANGUAGE_STANDARD = "c++17"; + CLANG_CXX_LANGUAGE_STANDARD = "c++20"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; @@ -573,8 +561,13 @@ MTL_ENABLE_DEBUG_INFO = NO; OTHER_CFLAGS = "$(inherited)"; OTHER_CPLUSPLUSFLAGS = "$(inherited)"; + OTHER_LDFLAGS = ( + "$(inherited)", + " ", + ); REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native"; SDKROOT = iphoneos; + USE_HERMES = false; VALIDATE_PRODUCT = YES; }; name = Release; @@ -608,16 +601,16 @@ repositoryURL = "https://github.com/maplibre/maplibre-gl-native-distribution"; requirement = { kind = upToNextMajorVersion; - minimumVersion = 5.11.0; + minimumVersion = 6.4.0; }; }; /* End XCRemoteSwiftPackageReference section */ /* Begin XCSwiftPackageProductDependency section */ - 80AC8CF095DA4835C83255C8 /* Mapbox */ = { + 1DC0AFC12BE58DCE00FBCA80 /* MapLibre */ = { isa = XCSwiftPackageProductDependency; package = DB11E3B9346BB8DFEB4101D5 /* XCRemoteSwiftPackageReference "maplibre-gl-native-distribution" */; - productName = Mapbox; + productName = MapLibre; }; /* End XCSwiftPackageProductDependency section */ }; diff --git a/example/ios/RNMaplibreExample.xcworkspace/xcshareddata/swiftpm/Package.resolved b/example/ios/RNMaplibreExample.xcworkspace/xcshareddata/swiftpm/Package.resolved index 0911f5292..c38e00cec 100644 --- a/example/ios/RNMaplibreExample.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/example/ios/RNMaplibreExample.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -1,12 +1,13 @@ { + "originHash" : "e70d3525c8e2819a8b34f22909815dab5c700c25a06c32388f3930f7b3627768", "pins" : [ { "identity" : "maplibre-gl-native-distribution", "kind" : "remoteSourceControl", "location" : "https://github.com/maplibre/maplibre-gl-native-distribution", "state" : { - "revision" : "ffda61e298c1490d4860d5184e80d618aaadc089", - "version" : "5.13.0" + "revision" : "6d0071977ed1f2380c739715f82ac650f99b0824", + "version" : "6.4.0" } } ], diff --git a/example/ios/RNMaplibreExample/AppDelegate.m b/example/ios/RNMaplibreExample/AppDelegate.m index 8440c03ab..703cf11c8 100644 --- a/example/ios/RNMaplibreExample/AppDelegate.m +++ b/example/ios/RNMaplibreExample/AppDelegate.m @@ -9,7 +9,7 @@ #import -#ifdef FB_SONARKIT_ENABLED +#if FB_SONARKIT_ENABLED #import #import #import @@ -32,7 +32,7 @@ @implementation AppDelegate - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { - #ifdef FB_SONARKIT_ENABLED + #if FB_SONARKIT_ENABLED InitializeFlipper(application); #endif diff --git a/ios/RCTMGL.xcodeproj/project.pbxproj b/ios/RCTMGL.xcodeproj/project.pbxproj deleted file mode 100644 index 8a9ad1b5b..000000000 --- a/ios/RCTMGL.xcodeproj/project.pbxproj +++ /dev/null @@ -1,775 +0,0 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 46; - objects = { - -/* Begin PBXBuildFile section */ - 431CDACE229D61A6008BE92D /* RCTMGLUserLocation.m in Sources */ = {isa = PBXBuildFile; fileRef = 431CDACC229D61A6008BE92D /* RCTMGLUserLocation.m */; }; - 641DE8A8231019E8003B792D /* MGLCustomHeaders.m in Sources */ = {isa = PBXBuildFile; fileRef = 641DE8A7231019E8003B792D /* MGLCustomHeaders.m */; }; - C410D5D51F7AD0B300CF822A /* RCTMGLLight.m in Sources */ = {isa = PBXBuildFile; fileRef = C410D5D41F7AD0B300CF822A /* RCTMGLLight.m */; }; - C410D5D81F7AD0C100CF822A /* RCTMGLLightManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C410D5D71F7AD0C100CF822A /* RCTMGLLightManager.m */; }; - C416015020112B5200006116 /* RNMBImageUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = C416014F20112B5200006116 /* RNMBImageUtils.m */; }; - C42236A41F6B012000FA9C1C /* RCTMGLStyle.m in Sources */ = {isa = PBXBuildFile; fileRef = C42236A31F6B012000FA9C1C /* RCTMGLStyle.m */; }; - C42236A71F6C7F4E00FA9C1C /* RCTMGLFillExtrusionLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C42236A61F6C7F4E00FA9C1C /* RCTMGLFillExtrusionLayer.m */; }; - C42236AA1F6C7F6200FA9C1C /* RCTMGLFillExtrusionLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C42236A91F6C7F6200FA9C1C /* RCTMGLFillExtrusionLayerManager.m */; }; - C435A5F71F587D9100824A30 /* ViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C435A5F61F587D9100824A30 /* ViewManager.m */; }; - C43CA5061F507BCC000B9CB7 /* RCTMGLMapTouchEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = C43CA5051F507BCC000B9CB7 /* RCTMGLMapTouchEvent.m */; }; - C43CA50A1F50C145000B9CB7 /* RCTMGLEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = C43CA5091F50C145000B9CB7 /* RCTMGLEvent.m */; }; - C43CA50D1F53A4EF000B9CB7 /* RCTMGLEventTypes.m in Sources */ = {isa = PBXBuildFile; fileRef = C43CA50C1F53A4EF000B9CB7 /* RCTMGLEventTypes.m */; }; - C45339CD204780EB00888553 /* RCTMGLImageQueueOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = C45339CC204780EB00888553 /* RCTMGLImageQueueOperation.m */; }; - C470F5B81F9E79D400614A69 /* RCTMGLImageQueue.m in Sources */ = {isa = PBXBuildFile; fileRef = C470F5B71F9E79D400614A69 /* RCTMGLImageQueue.m */; }; - C470F6AC1FA11C9500614A69 /* MGLOfflineModule.m in Sources */ = {isa = PBXBuildFile; fileRef = C470F6AB1FA11C9500614A69 /* MGLOfflineModule.m */; }; - C490EE0220DC565000CB2E57 /* RCTMGLLocationModule.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE0120DC565000CB2E57 /* RCTMGLLocationModule.m */; }; - C490EE0520DC575100CB2E57 /* RCTMGLLocationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE0420DC575100CB2E57 /* RCTMGLLocationManager.m */; }; - C490EE0B20DC6B7C00CB2E57 /* RCTMGLLocation.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE0A20DC6B7C00CB2E57 /* RCTMGLLocation.m */; }; - C490EE0E20DD70AD00CB2E57 /* RCTMGLCamera.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE0D20DD70AD00CB2E57 /* RCTMGLCamera.m */; }; - C490EE1120DD710000CB2E57 /* RCTMGLCameraManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE1020DD710000CB2E57 /* RCTMGLCameraManager.m */; }; - C4C87A601F844C820064AE95 /* FilterParser.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87A5F1F844C820064AE95 /* FilterParser.m */; }; - C4C87B7B1F8FEBF50064AE95 /* RCTMGLPointAnnotationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87B7A1F8FEBF40064AE95 /* RCTMGLPointAnnotationManager.m */; }; - C4C87B7E1F8FEC090064AE95 /* RCTMGLPointAnnotation.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87B7D1F8FEC090064AE95 /* RCTMGLPointAnnotation.m */; }; - C4C87B911F9142FB0064AE95 /* RCTMGLCallout.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87B901F9142FB0064AE95 /* RCTMGLCallout.m */; }; - C4C87B941F9143DA0064AE95 /* RCTMGLCalloutManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87B931F9143DA0064AE95 /* RCTMGLCalloutManager.m */; }; - C4D144421F4E16F600396F26 /* RCTMGL.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D144411F4E16F600396F26 /* RCTMGL.m */; }; - C4D144431F4E16F600396F26 /* RCTMGL.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = C4D144401F4E16F600396F26 /* RCTMGL.h */; }; - C4D1444C1F4E178100396F26 /* RCTMGLMapView.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D1444B1F4E178100396F26 /* RCTMGLMapView.m */; }; - C4D1444F1F4E181100396F26 /* RCTMGLMapViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D1444E1F4E181100396F26 /* RCTMGLMapViewManager.m */; }; - C4D144531F4E190C00396F26 /* MGLModule.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D144521F4E190C00396F26 /* MGLModule.m */; }; - C4D144971F4E2F1100396F26 /* RCTMGLUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D144961F4E2F1100396F26 /* RCTMGLUtils.m */; }; - C4EA22191F675ACE00EF2500 /* RCTMGLStyleValue.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EA22181F675ACE00EF2500 /* RCTMGLStyleValue.m */; }; - C4EAF1201F5FC07E0016DEE8 /* CameraStop.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF11F1F5FC07E0016DEE8 /* CameraStop.m */; }; - C4EAF1241F606F7C0016DEE8 /* CameraMode.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1231F606F7C0016DEE8 /* CameraMode.m */; }; - C4EAF1271F6083C70016DEE8 /* CameraUpdateItem.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1261F6083C70016DEE8 /* CameraUpdateItem.m */; }; - C4EAF12A1F6084920016DEE8 /* CameraUpdateQueue.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1291F6084920016DEE8 /* CameraUpdateQueue.m */; }; - C4EAF17D1F6324970016DEE8 /* RCTMGLSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF17C1F6324970016DEE8 /* RCTMGLSource.m */; }; - C4EAF1801F6324A80016DEE8 /* RCTMGLLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF17F1F6324A80016DEE8 /* RCTMGLLayer.m */; }; - C4EAF1831F6336E20016DEE8 /* RCTMGLVectorSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1821F6336E20016DEE8 /* RCTMGLVectorSource.m */; }; - C4EAF1891F633C010016DEE8 /* RCTMGLVectorSourceManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1881F633C010016DEE8 /* RCTMGLVectorSourceManager.m */; }; - C4EAF18F1F633E020016DEE8 /* RCTMGLFillLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF18E1F633E020016DEE8 /* RCTMGLFillLayer.m */; }; - C4EAF1921F6341520016DEE8 /* RCTMGLFillLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1911F6341520016DEE8 /* RCTMGLFillLayerManager.m */; }; - C4FB10FE1F707A140055AE1F /* RCTMGLLineLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB10FD1F707A140055AE1F /* RCTMGLLineLayer.m */; }; - C4FB11011F707A280055AE1F /* RCTMGLLineLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11001F707A280055AE1F /* RCTMGLLineLayerManager.m */; }; - C4FB11041F709CDC0055AE1F /* RCTMGLCircleLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11031F709CDC0055AE1F /* RCTMGLCircleLayer.m */; }; - C4FB11071F709CEF0055AE1F /* RCTMGLCircleLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11061F709CEF0055AE1F /* RCTMGLCircleLayerManager.m */; }; - C4FB110A1F71D09E0055AE1F /* RCTMGLShapeSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11091F71D09E0055AE1F /* RCTMGLShapeSource.m */; }; - C4FB110D1F71D0B10055AE1F /* RCTMGLShapeSourceManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB110C1F71D0B10055AE1F /* RCTMGLShapeSourceManager.m */; }; - C4FB11101F71EC8D0055AE1F /* RCTMGLSymbolLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB110F1F71EC8D0055AE1F /* RCTMGLSymbolLayer.m */; }; - C4FB11131F71EC9F0055AE1F /* RCTMGLSymbolLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11121F71EC9F0055AE1F /* RCTMGLSymbolLayerManager.m */; }; - C4FB122D1F7972A00055AE1F /* RCTMGLRasterSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB122C1F7972A00055AE1F /* RCTMGLRasterSource.m */; }; - C4FB12301F7972B40055AE1F /* RCTMGLRasterSourceManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB122F1F7972B40055AE1F /* RCTMGLRasterSourceManager.m */; }; - C4FB12331F799F190055AE1F /* RCTMGLRasterLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB12321F799F190055AE1F /* RCTMGLRasterLayer.m */; }; - C4FB12361F799F280055AE1F /* RCTMGLRasterLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB12351F799F280055AE1F /* RCTMGLRasterLayerManager.m */; }; - C4FB12581F79C0270055AE1F /* RCTMGLBackgroundLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB12571F79C0270055AE1F /* RCTMGLBackgroundLayer.m */; }; - C4FB125B1F79C03E0055AE1F /* RCTMGLBackgroundLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB125A1F79C03E0055AE1F /* RCTMGLBackgroundLayerManager.m */; }; - C4FD1DBF1FCF54FB00213AF2 /* RCTMGLImageSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FD1DBE1FCF54FB00213AF2 /* RCTMGLImageSource.m */; }; - C4FD1DC21FCF550E00213AF2 /* RCTMGLImageSourceManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FD1DC11FCF550E00213AF2 /* RCTMGLImageSourceManager.m */; }; - C4FD1DC51FD1F04300213AF2 /* MGLSnapshotModule.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FD1DC41FD1F04200213AF2 /* MGLSnapshotModule.m */; }; - D8C1903323F5382C00223486 /* RCTMGLImages.m in Sources */ = {isa = PBXBuildFile; fileRef = D8C1903223F5382C00223486 /* RCTMGLImages.m */; }; - D8C1903523F53B0F00223486 /* RCTMGLImagesManager.m in Sources */ = {isa = PBXBuildFile; fileRef = D8C1903423F53B0F00223486 /* RCTMGLImagesManager.m */; }; - DF16042F233BFDD100A4231D /* RCTMGLTileSource.m in Sources */ = {isa = PBXBuildFile; fileRef = DF16042E233BFDD000A4231D /* RCTMGLTileSource.m */; }; - DF3CFC0622CFCE0500A83174 /* RCTMGLNativeUserLocation.m in Sources */ = {isa = PBXBuildFile; fileRef = DF3CFC0222CFCE0500A83174 /* RCTMGLNativeUserLocation.m */; }; - DF3CFC0722CFCE0500A83174 /* RCTMGLNativeUserLocationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = DF3CFC0322CFCE0500A83174 /* RCTMGLNativeUserLocationManager.m */; }; -/* End PBXBuildFile section */ - -/* Begin PBXCopyFilesBuildPhase section */ - C4D1443B1F4E16F600396F26 /* CopyFiles */ = { - isa = PBXCopyFilesBuildPhase; - buildActionMask = 2147483647; - dstPath = "include/$(PRODUCT_NAME)"; - dstSubfolderSpec = 16; - files = ( - C4D144431F4E16F600396F26 /* RCTMGL.h in CopyFiles */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXCopyFilesBuildPhase section */ - -/* Begin PBXFileReference section */ - 431CDACC229D61A6008BE92D /* RCTMGLUserLocation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLUserLocation.m; sourceTree = ""; }; - 431CDACD229D61A6008BE92D /* RCTMGLUserLocation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLUserLocation.h; sourceTree = ""; }; - 641DE8A6231019E8003B792D /* MGLCustomHeaders.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MGLCustomHeaders.h; sourceTree = ""; }; - 641DE8A7231019E8003B792D /* MGLCustomHeaders.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MGLCustomHeaders.m; sourceTree = ""; }; - C410D5D31F7AD0B300CF822A /* RCTMGLLight.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLLight.h; sourceTree = ""; }; - C410D5D41F7AD0B300CF822A /* RCTMGLLight.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLLight.m; sourceTree = ""; }; - C410D5D61F7AD0C100CF822A /* RCTMGLLightManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLLightManager.h; sourceTree = ""; }; - C410D5D71F7AD0C100CF822A /* RCTMGLLightManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLLightManager.m; sourceTree = ""; }; - C416014E20112B5200006116 /* RNMBImageUtils.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RNMBImageUtils.h; sourceTree = ""; }; - C416014F20112B5200006116 /* RNMBImageUtils.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNMBImageUtils.m; sourceTree = ""; }; - C42236A21F6B012000FA9C1C /* RCTMGLStyle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLStyle.h; sourceTree = ""; }; - C42236A31F6B012000FA9C1C /* RCTMGLStyle.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLStyle.m; sourceTree = ""; }; - C42236A51F6C7F4E00FA9C1C /* RCTMGLFillExtrusionLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLFillExtrusionLayer.h; sourceTree = ""; }; - C42236A61F6C7F4E00FA9C1C /* RCTMGLFillExtrusionLayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLFillExtrusionLayer.m; sourceTree = ""; }; - C42236A81F6C7F6200FA9C1C /* RCTMGLFillExtrusionLayerManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLFillExtrusionLayerManager.h; sourceTree = ""; }; - C42236A91F6C7F6200FA9C1C /* RCTMGLFillExtrusionLayerManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLFillExtrusionLayerManager.m; sourceTree = ""; }; - C435A5F51F587D9100824A30 /* ViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ViewManager.h; sourceTree = ""; }; - C435A5F61F587D9100824A30 /* ViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ViewManager.m; sourceTree = ""; }; - C43CA5041F507BCC000B9CB7 /* RCTMGLMapTouchEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLMapTouchEvent.h; sourceTree = ""; }; - C43CA5051F507BCC000B9CB7 /* RCTMGLMapTouchEvent.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLMapTouchEvent.m; sourceTree = ""; }; - C43CA5071F507D88000B9CB7 /* RCTMGLEventProtocol.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLEventProtocol.h; sourceTree = ""; }; - C43CA5081F50C145000B9CB7 /* RCTMGLEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLEvent.h; sourceTree = ""; }; - C43CA5091F50C145000B9CB7 /* RCTMGLEvent.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLEvent.m; sourceTree = ""; }; - C43CA50B1F53A4EF000B9CB7 /* RCTMGLEventTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLEventTypes.h; sourceTree = ""; }; - C43CA50C1F53A4EF000B9CB7 /* RCTMGLEventTypes.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLEventTypes.m; sourceTree = ""; }; - C45339CB204780EB00888553 /* RCTMGLImageQueueOperation.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLImageQueueOperation.h; sourceTree = ""; }; - C45339CC204780EB00888553 /* RCTMGLImageQueueOperation.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLImageQueueOperation.m; sourceTree = ""; }; - C470F5B61F9E79D400614A69 /* RCTMGLImageQueue.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLImageQueue.h; sourceTree = ""; }; - C470F5B71F9E79D400614A69 /* RCTMGLImageQueue.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLImageQueue.m; sourceTree = ""; }; - C470F6AA1FA11C9500614A69 /* MGLOfflineModule.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MGLOfflineModule.h; sourceTree = ""; }; - C470F6AB1FA11C9500614A69 /* MGLOfflineModule.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MGLOfflineModule.m; sourceTree = ""; }; - C490EE0020DC565000CB2E57 /* RCTMGLLocationModule.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLLocationModule.h; sourceTree = ""; }; - C490EE0120DC565000CB2E57 /* RCTMGLLocationModule.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLLocationModule.m; sourceTree = ""; }; - C490EE0320DC575100CB2E57 /* RCTMGLLocationManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLLocationManager.h; sourceTree = ""; }; - C490EE0420DC575100CB2E57 /* RCTMGLLocationManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLLocationManager.m; sourceTree = ""; }; - C490EE0620DC5CDB00CB2E57 /* RCTMGLLocationManagerDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLLocationManagerDelegate.h; sourceTree = ""; }; - C490EE0720DC66DD00CB2E57 /* RCTMGLLocation.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLLocation.h; sourceTree = ""; }; - C490EE0A20DC6B7C00CB2E57 /* RCTMGLLocation.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLLocation.m; sourceTree = ""; }; - C490EE0C20DD70AD00CB2E57 /* RCTMGLCamera.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLCamera.h; sourceTree = ""; }; - C490EE0D20DD70AD00CB2E57 /* RCTMGLCamera.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLCamera.m; sourceTree = ""; }; - C490EE0F20DD710000CB2E57 /* RCTMGLCameraManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLCameraManager.h; sourceTree = ""; }; - C490EE1020DD710000CB2E57 /* RCTMGLCameraManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLCameraManager.m; sourceTree = ""; }; - C4C87A5E1F844C820064AE95 /* FilterParser.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = FilterParser.h; sourceTree = ""; }; - C4C87A5F1F844C820064AE95 /* FilterParser.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = FilterParser.m; sourceTree = ""; }; - C4C87B791F8FEBF40064AE95 /* RCTMGLPointAnnotationManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLPointAnnotationManager.h; sourceTree = ""; }; - C4C87B7A1F8FEBF40064AE95 /* RCTMGLPointAnnotationManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLPointAnnotationManager.m; sourceTree = ""; }; - C4C87B7C1F8FEC080064AE95 /* RCTMGLPointAnnotation.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLPointAnnotation.h; sourceTree = ""; }; - C4C87B7D1F8FEC090064AE95 /* RCTMGLPointAnnotation.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLPointAnnotation.m; sourceTree = ""; }; - C4C87B8F1F9142FB0064AE95 /* RCTMGLCallout.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLCallout.h; sourceTree = ""; }; - C4C87B901F9142FB0064AE95 /* RCTMGLCallout.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLCallout.m; sourceTree = ""; }; - C4C87B921F9143DA0064AE95 /* RCTMGLCalloutManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLCalloutManager.h; sourceTree = ""; }; - C4C87B931F9143DA0064AE95 /* RCTMGLCalloutManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLCalloutManager.m; sourceTree = ""; }; - C4D1443D1F4E16F600396F26 /* libRCTMGL.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libRCTMGL.a; sourceTree = BUILT_PRODUCTS_DIR; }; - C4D144401F4E16F600396F26 /* RCTMGL.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGL.h; sourceTree = ""; }; - C4D144411F4E16F600396F26 /* RCTMGL.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGL.m; sourceTree = ""; }; - C4D1444A1F4E178100396F26 /* RCTMGLMapView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLMapView.h; sourceTree = ""; }; - C4D1444B1F4E178100396F26 /* RCTMGLMapView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLMapView.m; sourceTree = ""; }; - C4D1444D1F4E181100396F26 /* RCTMGLMapViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLMapViewManager.h; sourceTree = ""; }; - C4D1444E1F4E181100396F26 /* RCTMGLMapViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLMapViewManager.m; sourceTree = ""; }; - C4D144511F4E190C00396F26 /* MGLModule.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MGLModule.h; sourceTree = ""; }; - C4D144521F4E190C00396F26 /* MGLModule.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MGLModule.m; sourceTree = ""; }; - C4D144951F4E2F1100396F26 /* RCTMGLUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLUtils.h; sourceTree = ""; }; - C4D144961F4E2F1100396F26 /* RCTMGLUtils.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLUtils.m; sourceTree = ""; }; - C4EA22171F675ACE00EF2500 /* RCTMGLStyleValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLStyleValue.h; sourceTree = ""; }; - C4EA22181F675ACE00EF2500 /* RCTMGLStyleValue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLStyleValue.m; sourceTree = ""; }; - C4EAF11E1F5FC07E0016DEE8 /* CameraStop.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CameraStop.h; sourceTree = ""; }; - C4EAF11F1F5FC07E0016DEE8 /* CameraStop.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CameraStop.m; sourceTree = ""; }; - C4EAF1221F606F7C0016DEE8 /* CameraMode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CameraMode.h; sourceTree = ""; }; - C4EAF1231F606F7C0016DEE8 /* CameraMode.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CameraMode.m; sourceTree = ""; }; - C4EAF1251F6083C70016DEE8 /* CameraUpdateItem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CameraUpdateItem.h; sourceTree = ""; }; - C4EAF1261F6083C70016DEE8 /* CameraUpdateItem.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CameraUpdateItem.m; sourceTree = ""; }; - C4EAF1281F6084920016DEE8 /* CameraUpdateQueue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CameraUpdateQueue.h; sourceTree = ""; }; - C4EAF1291F6084920016DEE8 /* CameraUpdateQueue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CameraUpdateQueue.m; sourceTree = ""; }; - C4EAF17B1F6324970016DEE8 /* RCTMGLSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLSource.h; sourceTree = ""; }; - C4EAF17C1F6324970016DEE8 /* RCTMGLSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLSource.m; sourceTree = ""; }; - C4EAF17E1F6324A80016DEE8 /* RCTMGLLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLLayer.h; sourceTree = ""; }; - C4EAF17F1F6324A80016DEE8 /* RCTMGLLayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLLayer.m; sourceTree = ""; }; - C4EAF1811F6336E20016DEE8 /* RCTMGLVectorSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLVectorSource.h; sourceTree = ""; }; - C4EAF1821F6336E20016DEE8 /* RCTMGLVectorSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLVectorSource.m; sourceTree = ""; }; - C4EAF1871F633C010016DEE8 /* RCTMGLVectorSourceManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLVectorSourceManager.h; sourceTree = ""; }; - C4EAF1881F633C010016DEE8 /* RCTMGLVectorSourceManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLVectorSourceManager.m; sourceTree = ""; }; - C4EAF18D1F633E020016DEE8 /* RCTMGLFillLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLFillLayer.h; sourceTree = ""; }; - C4EAF18E1F633E020016DEE8 /* RCTMGLFillLayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLFillLayer.m; sourceTree = ""; }; - C4EAF1901F6341520016DEE8 /* RCTMGLFillLayerManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLFillLayerManager.h; sourceTree = ""; }; - C4EAF1911F6341520016DEE8 /* RCTMGLFillLayerManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLFillLayerManager.m; sourceTree = ""; }; - C4FB10FC1F707A140055AE1F /* RCTMGLLineLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLLineLayer.h; sourceTree = ""; }; - C4FB10FD1F707A140055AE1F /* RCTMGLLineLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLLineLayer.m; sourceTree = ""; }; - C4FB10FF1F707A280055AE1F /* RCTMGLLineLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLLineLayerManager.h; sourceTree = ""; }; - C4FB11001F707A280055AE1F /* RCTMGLLineLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLLineLayerManager.m; sourceTree = ""; }; - C4FB11021F709CDC0055AE1F /* RCTMGLCircleLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLCircleLayer.h; sourceTree = ""; }; - C4FB11031F709CDC0055AE1F /* RCTMGLCircleLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLCircleLayer.m; sourceTree = ""; }; - C4FB11051F709CEF0055AE1F /* RCTMGLCircleLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLCircleLayerManager.h; sourceTree = ""; }; - C4FB11061F709CEF0055AE1F /* RCTMGLCircleLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLCircleLayerManager.m; sourceTree = ""; }; - C4FB11081F71D09E0055AE1F /* RCTMGLShapeSource.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLShapeSource.h; sourceTree = ""; }; - C4FB11091F71D09E0055AE1F /* RCTMGLShapeSource.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLShapeSource.m; sourceTree = ""; }; - C4FB110B1F71D0B10055AE1F /* RCTMGLShapeSourceManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLShapeSourceManager.h; sourceTree = ""; }; - C4FB110C1F71D0B10055AE1F /* RCTMGLShapeSourceManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLShapeSourceManager.m; sourceTree = ""; }; - C4FB110E1F71EC8D0055AE1F /* RCTMGLSymbolLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLSymbolLayer.h; sourceTree = ""; }; - C4FB110F1F71EC8D0055AE1F /* RCTMGLSymbolLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLSymbolLayer.m; sourceTree = ""; }; - C4FB11111F71EC9F0055AE1F /* RCTMGLSymbolLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLSymbolLayerManager.h; sourceTree = ""; }; - C4FB11121F71EC9F0055AE1F /* RCTMGLSymbolLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLSymbolLayerManager.m; sourceTree = ""; }; - C4FB122B1F7972A00055AE1F /* RCTMGLRasterSource.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLRasterSource.h; sourceTree = ""; }; - C4FB122C1F7972A00055AE1F /* RCTMGLRasterSource.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLRasterSource.m; sourceTree = ""; }; - C4FB122E1F7972B40055AE1F /* RCTMGLRasterSourceManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLRasterSourceManager.h; sourceTree = ""; }; - C4FB122F1F7972B40055AE1F /* RCTMGLRasterSourceManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLRasterSourceManager.m; sourceTree = ""; }; - C4FB12311F799F190055AE1F /* RCTMGLRasterLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLRasterLayer.h; sourceTree = ""; }; - C4FB12321F799F190055AE1F /* RCTMGLRasterLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLRasterLayer.m; sourceTree = ""; }; - C4FB12341F799F280055AE1F /* RCTMGLRasterLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLRasterLayerManager.h; sourceTree = ""; }; - C4FB12351F799F280055AE1F /* RCTMGLRasterLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLRasterLayerManager.m; sourceTree = ""; }; - C4FB12561F79C0270055AE1F /* RCTMGLBackgroundLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLBackgroundLayer.h; sourceTree = ""; }; - C4FB12571F79C0270055AE1F /* RCTMGLBackgroundLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLBackgroundLayer.m; sourceTree = ""; }; - C4FB12591F79C03E0055AE1F /* RCTMGLBackgroundLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLBackgroundLayerManager.h; sourceTree = ""; }; - C4FB125A1F79C03E0055AE1F /* RCTMGLBackgroundLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLBackgroundLayerManager.m; sourceTree = ""; }; - C4FD1DBD1FCF54FB00213AF2 /* RCTMGLImageSource.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLImageSource.h; sourceTree = ""; }; - C4FD1DBE1FCF54FB00213AF2 /* RCTMGLImageSource.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLImageSource.m; sourceTree = ""; }; - C4FD1DC01FCF550E00213AF2 /* RCTMGLImageSourceManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLImageSourceManager.h; sourceTree = ""; }; - C4FD1DC11FCF550E00213AF2 /* RCTMGLImageSourceManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLImageSourceManager.m; sourceTree = ""; }; - C4FD1DC31FD1F04200213AF2 /* MGLSnapshotModule.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MGLSnapshotModule.h; sourceTree = ""; }; - C4FD1DC41FD1F04200213AF2 /* MGLSnapshotModule.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MGLSnapshotModule.m; sourceTree = ""; }; - D8C1903123F5382C00223486 /* RCTMGLImages.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLImages.h; sourceTree = ""; }; - D8C1903223F5382C00223486 /* RCTMGLImages.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLImages.m; sourceTree = ""; }; - D8C1903423F53B0F00223486 /* RCTMGLImagesManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMGLImagesManager.m; sourceTree = ""; }; - D8C1903623F53B3C00223486 /* RCTMGLImagesManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMGLImagesManager.h; sourceTree = ""; }; - DF16042D233BFDD000A4231D /* RCTMGLTileSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLTileSource.h; sourceTree = ""; }; - DF16042E233BFDD000A4231D /* RCTMGLTileSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLTileSource.m; sourceTree = ""; }; - DF3CFC0222CFCE0500A83174 /* RCTMGLNativeUserLocation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLNativeUserLocation.m; sourceTree = ""; }; - DF3CFC0322CFCE0500A83174 /* RCTMGLNativeUserLocationManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMGLNativeUserLocationManager.m; sourceTree = ""; }; - DF3CFC0422CFCE0500A83174 /* RCTMGLNativeUserLocationManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLNativeUserLocationManager.h; sourceTree = ""; }; - DF3CFC0522CFCE0500A83174 /* RCTMGLNativeUserLocation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMGLNativeUserLocation.h; sourceTree = ""; }; -/* End PBXFileReference section */ - -/* Begin PBXFrameworksBuildPhase section */ - C4D1443A1F4E16F600396F26 /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - C410D5D21F7AD0A200CF822A /* Light */ = { - isa = PBXGroup; - children = ( - C410D5D31F7AD0B300CF822A /* RCTMGLLight.h */, - C410D5D41F7AD0B300CF822A /* RCTMGLLight.m */, - C410D5D61F7AD0C100CF822A /* RCTMGLLightManager.h */, - C410D5D71F7AD0C100CF822A /* RCTMGLLightManager.m */, - ); - name = Light; - sourceTree = ""; - }; - C42219B21FEB1FD600EE9E35 /* Location */ = { - isa = PBXGroup; - children = ( - 431CDACD229D61A6008BE92D /* RCTMGLUserLocation.h */, - 431CDACC229D61A6008BE92D /* RCTMGLUserLocation.m */, - C490EE0320DC575100CB2E57 /* RCTMGLLocationManager.h */, - C490EE0420DC575100CB2E57 /* RCTMGLLocationManager.m */, - C490EE0620DC5CDB00CB2E57 /* RCTMGLLocationManagerDelegate.h */, - C490EE0720DC66DD00CB2E57 /* RCTMGLLocation.h */, - C490EE0A20DC6B7C00CB2E57 /* RCTMGLLocation.m */, - ); - name = Location; - sourceTree = ""; - }; - C43773B91F56024900AF6D71 /* Components */ = { - isa = PBXGroup; - children = ( - D8C1903023F537D300223486 /* Images */, - C435A5F51F587D9100824A30 /* ViewManager.h */, - C435A5F61F587D9100824A30 /* ViewManager.m */, - C4C87B781F8FEB4D0064AE95 /* Annotations */, - C4EAF0EE1F5FAEB50016DEE8 /* Camera */, - DF3CFC0122CFCD8B00A83174 /* Location */, - C43773BA1F56025800AF6D71 /* MapView */, - C4EAF1781F6320A40016DEE8 /* Styles */, - ); - name = Components; - sourceTree = ""; - }; - C43773BA1F56025800AF6D71 /* MapView */ = { - isa = PBXGroup; - children = ( - C4D1444A1F4E178100396F26 /* RCTMGLMapView.h */, - C4D1444B1F4E178100396F26 /* RCTMGLMapView.m */, - C4D1444D1F4E181100396F26 /* RCTMGLMapViewManager.h */, - C4D1444E1F4E181100396F26 /* RCTMGLMapViewManager.m */, - ); - name = MapView; - sourceTree = ""; - }; - C43773BD1F5603AA00AF6D71 /* Constants */ = { - isa = PBXGroup; - children = ( - C43CA50B1F53A4EF000B9CB7 /* RCTMGLEventTypes.h */, - C43CA50C1F53A4EF000B9CB7 /* RCTMGLEventTypes.m */, - ); - name = Constants; - sourceTree = ""; - }; - C43CA5031F507B8D000B9CB7 /* Events */ = { - isa = PBXGroup; - children = ( - C43CA5041F507BCC000B9CB7 /* RCTMGLMapTouchEvent.h */, - C43CA5051F507BCC000B9CB7 /* RCTMGLMapTouchEvent.m */, - C43CA5071F507D88000B9CB7 /* RCTMGLEventProtocol.h */, - C43CA5081F50C145000B9CB7 /* RCTMGLEvent.h */, - C43CA5091F50C145000B9CB7 /* RCTMGLEvent.m */, - C43773BD1F5603AA00AF6D71 /* Constants */, - ); - name = Events; - sourceTree = ""; - }; - C4C87B781F8FEB4D0064AE95 /* Annotations */ = { - isa = PBXGroup; - children = ( - C4C87B791F8FEBF40064AE95 /* RCTMGLPointAnnotationManager.h */, - C4C87B7A1F8FEBF40064AE95 /* RCTMGLPointAnnotationManager.m */, - C4C87B7C1F8FEC080064AE95 /* RCTMGLPointAnnotation.h */, - C4C87B7D1F8FEC090064AE95 /* RCTMGLPointAnnotation.m */, - C4C87B8F1F9142FB0064AE95 /* RCTMGLCallout.h */, - C4C87B901F9142FB0064AE95 /* RCTMGLCallout.m */, - C4C87B921F9143DA0064AE95 /* RCTMGLCalloutManager.h */, - C4C87B931F9143DA0064AE95 /* RCTMGLCalloutManager.m */, - ); - name = Annotations; - sourceTree = ""; - }; - C4D144341F4E16F600396F26 = { - isa = PBXGroup; - children = ( - C4D1443F1F4E16F600396F26 /* RCTMGL */, - C4D1443E1F4E16F600396F26 /* Products */, - ); - sourceTree = ""; - }; - C4D1443E1F4E16F600396F26 /* Products */ = { - isa = PBXGroup; - children = ( - C4D1443D1F4E16F600396F26 /* libRCTMGL.a */, - ); - name = Products; - sourceTree = ""; - }; - C4D1443F1F4E16F600396F26 /* RCTMGL */ = { - isa = PBXGroup; - children = ( - C42219B21FEB1FD600EE9E35 /* Location */, - C43773B91F56024900AF6D71 /* Components */, - C43CA5031F507B8D000B9CB7 /* Events */, - C4D144941F4E2EC800396F26 /* Utils */, - C4D144501F4E188F00396F26 /* Modules */, - C4D144401F4E16F600396F26 /* RCTMGL.h */, - C4D144411F4E16F600396F26 /* RCTMGL.m */, - ); - path = RCTMGL; - sourceTree = ""; - }; - C4D144501F4E188F00396F26 /* Modules */ = { - isa = PBXGroup; - children = ( - 641DE8A6231019E8003B792D /* MGLCustomHeaders.h */, - 641DE8A7231019E8003B792D /* MGLCustomHeaders.m */, - C4D144511F4E190C00396F26 /* MGLModule.h */, - C4D144521F4E190C00396F26 /* MGLModule.m */, - C470F6AA1FA11C9500614A69 /* MGLOfflineModule.h */, - C470F6AB1FA11C9500614A69 /* MGLOfflineModule.m */, - C4FD1DC31FD1F04200213AF2 /* MGLSnapshotModule.h */, - C4FD1DC41FD1F04200213AF2 /* MGLSnapshotModule.m */, - C490EE0020DC565000CB2E57 /* RCTMGLLocationModule.h */, - C490EE0120DC565000CB2E57 /* RCTMGLLocationModule.m */, - ); - name = Modules; - sourceTree = ""; - }; - C4D144941F4E2EC800396F26 /* Utils */ = { - isa = PBXGroup; - children = ( - C4D144951F4E2F1100396F26 /* RCTMGLUtils.h */, - C4D144961F4E2F1100396F26 /* RCTMGLUtils.m */, - C4C87A5E1F844C820064AE95 /* FilterParser.h */, - C4C87A5F1F844C820064AE95 /* FilterParser.m */, - C470F5B61F9E79D400614A69 /* RCTMGLImageQueue.h */, - C470F5B71F9E79D400614A69 /* RCTMGLImageQueue.m */, - C416014E20112B5200006116 /* RNMBImageUtils.h */, - C416014F20112B5200006116 /* RNMBImageUtils.m */, - C45339CB204780EB00888553 /* RCTMGLImageQueueOperation.h */, - C45339CC204780EB00888553 /* RCTMGLImageQueueOperation.m */, - ); - name = Utils; - sourceTree = ""; - }; - C4EAF0EE1F5FAEB50016DEE8 /* Camera */ = { - isa = PBXGroup; - children = ( - C4EAF1211F606F610016DEE8 /* Constants */, - C4EAF11E1F5FC07E0016DEE8 /* CameraStop.h */, - C4EAF11F1F5FC07E0016DEE8 /* CameraStop.m */, - C4EAF1251F6083C70016DEE8 /* CameraUpdateItem.h */, - C4EAF1261F6083C70016DEE8 /* CameraUpdateItem.m */, - C4EAF1281F6084920016DEE8 /* CameraUpdateQueue.h */, - C4EAF1291F6084920016DEE8 /* CameraUpdateQueue.m */, - C490EE0C20DD70AD00CB2E57 /* RCTMGLCamera.h */, - C490EE0D20DD70AD00CB2E57 /* RCTMGLCamera.m */, - C490EE0F20DD710000CB2E57 /* RCTMGLCameraManager.h */, - C490EE1020DD710000CB2E57 /* RCTMGLCameraManager.m */, - ); - name = Camera; - sourceTree = ""; - }; - C4EAF1211F606F610016DEE8 /* Constants */ = { - isa = PBXGroup; - children = ( - C4EAF1221F606F7C0016DEE8 /* CameraMode.h */, - C4EAF1231F606F7C0016DEE8 /* CameraMode.m */, - ); - name = Constants; - sourceTree = ""; - }; - C4EAF1781F6320A40016DEE8 /* Styles */ = { - isa = PBXGroup; - children = ( - C42236A21F6B012000FA9C1C /* RCTMGLStyle.h */, - C42236A31F6B012000FA9C1C /* RCTMGLStyle.m */, - C410D5D21F7AD0A200CF822A /* Light */, - C4EAF17A1F6320B10016DEE8 /* Layers */, - C4EAF1791F6320AA0016DEE8 /* Sources */, - C4EA22171F675ACE00EF2500 /* RCTMGLStyleValue.h */, - C4EA22181F675ACE00EF2500 /* RCTMGLStyleValue.m */, - ); - name = Styles; - sourceTree = ""; - }; - C4EAF1791F6320AA0016DEE8 /* Sources */ = { - isa = PBXGroup; - children = ( - C4EAF17B1F6324970016DEE8 /* RCTMGLSource.h */, - C4EAF17C1F6324970016DEE8 /* RCTMGLSource.m */, - C4EAF1811F6336E20016DEE8 /* RCTMGLVectorSource.h */, - C4EAF1821F6336E20016DEE8 /* RCTMGLVectorSource.m */, - C4EAF1871F633C010016DEE8 /* RCTMGLVectorSourceManager.h */, - C4EAF1881F633C010016DEE8 /* RCTMGLVectorSourceManager.m */, - C4FB11081F71D09E0055AE1F /* RCTMGLShapeSource.h */, - C4FB11091F71D09E0055AE1F /* RCTMGLShapeSource.m */, - C4FB110B1F71D0B10055AE1F /* RCTMGLShapeSourceManager.h */, - C4FB110C1F71D0B10055AE1F /* RCTMGLShapeSourceManager.m */, - DF16042D233BFDD000A4231D /* RCTMGLTileSource.h */, - DF16042E233BFDD000A4231D /* RCTMGLTileSource.m */, - C4FB122B1F7972A00055AE1F /* RCTMGLRasterSource.h */, - C4FB122C1F7972A00055AE1F /* RCTMGLRasterSource.m */, - C4FB122E1F7972B40055AE1F /* RCTMGLRasterSourceManager.h */, - C4FB122F1F7972B40055AE1F /* RCTMGLRasterSourceManager.m */, - C4FD1DBD1FCF54FB00213AF2 /* RCTMGLImageSource.h */, - C4FD1DBE1FCF54FB00213AF2 /* RCTMGLImageSource.m */, - C4FD1DC01FCF550E00213AF2 /* RCTMGLImageSourceManager.h */, - C4FD1DC11FCF550E00213AF2 /* RCTMGLImageSourceManager.m */, - ); - name = Sources; - sourceTree = ""; - }; - C4EAF17A1F6320B10016DEE8 /* Layers */ = { - isa = PBXGroup; - children = ( - C4EAF17E1F6324A80016DEE8 /* RCTMGLLayer.h */, - C4EAF17F1F6324A80016DEE8 /* RCTMGLLayer.m */, - C4EAF18D1F633E020016DEE8 /* RCTMGLFillLayer.h */, - C4EAF18E1F633E020016DEE8 /* RCTMGLFillLayer.m */, - C4EAF1901F6341520016DEE8 /* RCTMGLFillLayerManager.h */, - C4EAF1911F6341520016DEE8 /* RCTMGLFillLayerManager.m */, - C42236A51F6C7F4E00FA9C1C /* RCTMGLFillExtrusionLayer.h */, - C42236A61F6C7F4E00FA9C1C /* RCTMGLFillExtrusionLayer.m */, - C42236A81F6C7F6200FA9C1C /* RCTMGLFillExtrusionLayerManager.h */, - C42236A91F6C7F6200FA9C1C /* RCTMGLFillExtrusionLayerManager.m */, - C4FB10FC1F707A140055AE1F /* RCTMGLLineLayer.h */, - C4FB10FD1F707A140055AE1F /* RCTMGLLineLayer.m */, - C4FB10FF1F707A280055AE1F /* RCTMGLLineLayerManager.h */, - C4FB11001F707A280055AE1F /* RCTMGLLineLayerManager.m */, - C4FB11021F709CDC0055AE1F /* RCTMGLCircleLayer.h */, - C4FB11031F709CDC0055AE1F /* RCTMGLCircleLayer.m */, - C4FB11051F709CEF0055AE1F /* RCTMGLCircleLayerManager.h */, - C4FB11061F709CEF0055AE1F /* RCTMGLCircleLayerManager.m */, - C4FB110E1F71EC8D0055AE1F /* RCTMGLSymbolLayer.h */, - C4FB110F1F71EC8D0055AE1F /* RCTMGLSymbolLayer.m */, - C4FB11111F71EC9F0055AE1F /* RCTMGLSymbolLayerManager.h */, - C4FB11121F71EC9F0055AE1F /* RCTMGLSymbolLayerManager.m */, - C4FB12311F799F190055AE1F /* RCTMGLRasterLayer.h */, - C4FB12321F799F190055AE1F /* RCTMGLRasterLayer.m */, - C4FB12341F799F280055AE1F /* RCTMGLRasterLayerManager.h */, - C4FB12351F799F280055AE1F /* RCTMGLRasterLayerManager.m */, - C4FB12561F79C0270055AE1F /* RCTMGLBackgroundLayer.h */, - C4FB12571F79C0270055AE1F /* RCTMGLBackgroundLayer.m */, - C4FB12591F79C03E0055AE1F /* RCTMGLBackgroundLayerManager.h */, - C4FB125A1F79C03E0055AE1F /* RCTMGLBackgroundLayerManager.m */, - ); - name = Layers; - sourceTree = ""; - }; - D8C1903023F537D300223486 /* Images */ = { - isa = PBXGroup; - children = ( - D8C1903123F5382C00223486 /* RCTMGLImages.h */, - D8C1903223F5382C00223486 /* RCTMGLImages.m */, - D8C1903623F53B3C00223486 /* RCTMGLImagesManager.h */, - D8C1903423F53B0F00223486 /* RCTMGLImagesManager.m */, - ); - name = Images; - }; - DF3CFC0122CFCD8B00A83174 /* Location */ = { - isa = PBXGroup; - children = ( - DF3CFC0522CFCE0500A83174 /* RCTMGLNativeUserLocation.h */, - DF3CFC0222CFCE0500A83174 /* RCTMGLNativeUserLocation.m */, - DF3CFC0422CFCE0500A83174 /* RCTMGLNativeUserLocationManager.h */, - DF3CFC0322CFCE0500A83174 /* RCTMGLNativeUserLocationManager.m */, - ); - name = Location; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXNativeTarget section */ - C4D1443C1F4E16F600396F26 /* RCTMGL */ = { - isa = PBXNativeTarget; - buildConfigurationList = C4D144461F4E16F600396F26 /* Build configuration list for PBXNativeTarget "RCTMGL" */; - buildPhases = ( - C4D144391F4E16F600396F26 /* Sources */, - C4D1443A1F4E16F600396F26 /* Frameworks */, - C4D1443B1F4E16F600396F26 /* CopyFiles */, - ); - buildRules = ( - ); - dependencies = ( - ); - name = RCTMGL; - productName = RCTMGL; - productReference = C4D1443D1F4E16F600396F26 /* libRCTMGL.a */; - productType = "com.apple.product-type.library.static"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - C4D144351F4E16F600396F26 /* Project object */ = { - isa = PBXProject; - attributes = { - LastUpgradeCheck = 0830; - ORGANIZATIONNAME = "Mapbox Inc"; - TargetAttributes = { - C4D1443C1F4E16F600396F26 = { - CreatedOnToolsVersion = 8.3.3; - ProvisioningStyle = Automatic; - }; - }; - }; - buildConfigurationList = C4D144381F4E16F600396F26 /* Build configuration list for PBXProject "RCTMGL" */; - compatibilityVersion = "Xcode 3.2"; - developmentRegion = English; - hasScannedForEncodings = 0; - knownRegions = ( - English, - en, - ); - mainGroup = C4D144341F4E16F600396F26; - productRefGroup = C4D1443E1F4E16F600396F26 /* Products */; - projectDirPath = ""; - projectRoot = ""; - targets = ( - C4D1443C1F4E16F600396F26 /* RCTMGL */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXSourcesBuildPhase section */ - C4D144391F4E16F600396F26 /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - C470F6AC1FA11C9500614A69 /* MGLOfflineModule.m in Sources */, - DF3CFC0722CFCE0500A83174 /* RCTMGLNativeUserLocationManager.m in Sources */, - C4FB12581F79C0270055AE1F /* RCTMGLBackgroundLayer.m in Sources */, - C4EAF1801F6324A80016DEE8 /* RCTMGLLayer.m in Sources */, - C4C87B7E1F8FEC090064AE95 /* RCTMGLPointAnnotation.m in Sources */, - C4EAF1271F6083C70016DEE8 /* CameraUpdateItem.m in Sources */, - C470F5B81F9E79D400614A69 /* RCTMGLImageQueue.m in Sources */, - C45339CD204780EB00888553 /* RCTMGLImageQueueOperation.m in Sources */, - DF16042F233BFDD100A4231D /* RCTMGLTileSource.m in Sources */, - C4D144531F4E190C00396F26 /* MGLModule.m in Sources */, - C4C87B7B1F8FEBF50064AE95 /* RCTMGLPointAnnotationManager.m in Sources */, - C43CA50A1F50C145000B9CB7 /* RCTMGLEvent.m in Sources */, - C4EA22191F675ACE00EF2500 /* RCTMGLStyleValue.m in Sources */, - C4FB110A1F71D09E0055AE1F /* RCTMGLShapeSource.m in Sources */, - C4FB11101F71EC8D0055AE1F /* RCTMGLSymbolLayer.m in Sources */, - C4FB125B1F79C03E0055AE1F /* RCTMGLBackgroundLayerManager.m in Sources */, - C4EAF18F1F633E020016DEE8 /* RCTMGLFillLayer.m in Sources */, - C4C87B911F9142FB0064AE95 /* RCTMGLCallout.m in Sources */, - C42236AA1F6C7F6200FA9C1C /* RCTMGLFillExtrusionLayerManager.m in Sources */, - C4FB12331F799F190055AE1F /* RCTMGLRasterLayer.m in Sources */, - C4D1444C1F4E178100396F26 /* RCTMGLMapView.m in Sources */, - C410D5D51F7AD0B300CF822A /* RCTMGLLight.m in Sources */, - C490EE0520DC575100CB2E57 /* RCTMGLLocationManager.m in Sources */, - C42236A41F6B012000FA9C1C /* RCTMGLStyle.m in Sources */, - C4FD1DC21FCF550E00213AF2 /* RCTMGLImageSourceManager.m in Sources */, - C4D1444F1F4E181100396F26 /* RCTMGLMapViewManager.m in Sources */, - C4FB12361F799F280055AE1F /* RCTMGLRasterLayerManager.m in Sources */, - C4FB110D1F71D0B10055AE1F /* RCTMGLShapeSourceManager.m in Sources */, - C490EE0B20DC6B7C00CB2E57 /* RCTMGLLocation.m in Sources */, - D8C1903323F5382C00223486 /* RCTMGLImages.m in Sources */, - C4EAF1921F6341520016DEE8 /* RCTMGLFillLayerManager.m in Sources */, - C4D144971F4E2F1100396F26 /* RCTMGLUtils.m in Sources */, - C43CA50D1F53A4EF000B9CB7 /* RCTMGLEventTypes.m in Sources */, - C4EAF1201F5FC07E0016DEE8 /* CameraStop.m in Sources */, - C4FB11071F709CEF0055AE1F /* RCTMGLCircleLayerManager.m in Sources */, - C4EAF1241F606F7C0016DEE8 /* CameraMode.m in Sources */, - C4D144421F4E16F600396F26 /* RCTMGL.m in Sources */, - C42236A71F6C7F4E00FA9C1C /* RCTMGLFillExtrusionLayer.m in Sources */, - C490EE0E20DD70AD00CB2E57 /* RCTMGLCamera.m in Sources */, - C4FB11011F707A280055AE1F /* RCTMGLLineLayerManager.m in Sources */, - C43CA5061F507BCC000B9CB7 /* RCTMGLMapTouchEvent.m in Sources */, - C4FB12301F7972B40055AE1F /* RCTMGLRasterSourceManager.m in Sources */, - C416015020112B5200006116 /* RNMBImageUtils.m in Sources */, - C4FB10FE1F707A140055AE1F /* RCTMGLLineLayer.m in Sources */, - C4EAF1831F6336E20016DEE8 /* RCTMGLVectorSource.m in Sources */, - C4EAF1891F633C010016DEE8 /* RCTMGLVectorSourceManager.m in Sources */, - DF3CFC0622CFCE0500A83174 /* RCTMGLNativeUserLocation.m in Sources */, - C490EE1120DD710000CB2E57 /* RCTMGLCameraManager.m in Sources */, - 431CDACE229D61A6008BE92D /* RCTMGLUserLocation.m in Sources */, - C4FD1DC51FD1F04300213AF2 /* MGLSnapshotModule.m in Sources */, - C4FB122D1F7972A00055AE1F /* RCTMGLRasterSource.m in Sources */, - C4C87B941F9143DA0064AE95 /* RCTMGLCalloutManager.m in Sources */, - C410D5D81F7AD0C100CF822A /* RCTMGLLightManager.m in Sources */, - C4EAF17D1F6324970016DEE8 /* RCTMGLSource.m in Sources */, - C490EE0220DC565000CB2E57 /* RCTMGLLocationModule.m in Sources */, - C4FB11131F71EC9F0055AE1F /* RCTMGLSymbolLayerManager.m in Sources */, - D8C1903523F53B0F00223486 /* RCTMGLImagesManager.m in Sources */, - 641DE8A8231019E8003B792D /* MGLCustomHeaders.m in Sources */, - C4C87A601F844C820064AE95 /* FilterParser.m in Sources */, - C4FD1DBF1FCF54FB00213AF2 /* RCTMGLImageSource.m in Sources */, - C4EAF12A1F6084920016DEE8 /* CameraUpdateQueue.m in Sources */, - C4FB11041F709CDC0055AE1F /* RCTMGLCircleLayer.m in Sources */, - C435A5F71F587D9100824A30 /* ViewManager.m in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin XCBuildConfiguration section */ - C4D144441F4E16F600396F26 /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - ENABLE_TESTABILITY = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_DYNAMIC_NO_PIC = NO; - GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PREPROCESSOR_DEFINITIONS = ( - "DEBUG=1", - "$(inherited)", - ); - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - HEADER_SEARCH_PATHS = "$(SRCROOT)/../../../react-native/React"; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; - MTL_ENABLE_DEBUG_INFO = YES; - ONLY_ACTIVE_ARCH = YES; - SDKROOT = iphoneos; - }; - name = Debug; - }; - C4D144451F4E16F600396F26 /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - HEADER_SEARCH_PATHS = "$(SRCROOT)/../../../react-native/React"; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; - MTL_ENABLE_DEBUG_INFO = NO; - SDKROOT = iphoneos; - VALIDATE_PRODUCT = YES; - }; - name = Release; - }; - C4D144471F4E16F600396F26 /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - FRAMEWORK_SEARCH_PATHS = "$(SRCROOT)"; - HEADER_SEARCH_PATHS = "$(SRCROOT)/../../../react-native/React/**"; - OTHER_LDFLAGS = "-ObjC"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SKIP_INSTALL = YES; - }; - name = Debug; - }; - C4D144481F4E16F600396F26 /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - FRAMEWORK_SEARCH_PATHS = "$(SRCROOT)"; - HEADER_SEARCH_PATHS = "$(SRCROOT)/../../../react-native/React/**"; - OTHER_LDFLAGS = "-ObjC"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SKIP_INSTALL = YES; - }; - name = Release; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - C4D144381F4E16F600396F26 /* Build configuration list for PBXProject "RCTMGL" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - C4D144441F4E16F600396F26 /* Debug */, - C4D144451F4E16F600396F26 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - C4D144461F4E16F600396F26 /* Build configuration list for PBXNativeTarget "RCTMGL" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - C4D144471F4E16F600396F26 /* Debug */, - C4D144481F4E16F600396F26 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; -/* End XCConfigurationList section */ - }; - rootObject = C4D144351F4E16F600396F26 /* Project object */; -} diff --git a/ios/RCTMGL/MGLFaux3DUserLocationAnnotationView.h b/ios/RCTMGL/MGLFaux3DUserLocationAnnotationView.h deleted file mode 100644 index 53cf46151..000000000 --- a/ios/RCTMGL/MGLFaux3DUserLocationAnnotationView.h +++ /dev/null @@ -1,23 +0,0 @@ -// -// MGLFaux3DUserLocationAnnotationView.h -// RCTMGL -// -// Created by Nick Italiano on 12/20/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import -@import Mapbox; - -extern const CGFloat MGLUserLocationAnnotationDotSize; -extern const CGFloat MGLUserLocationAnnotationHaloSize; - -extern const CGFloat MGLUserLocationAnnotationPuckSize; -extern const CGFloat MGLUserLocationAnnotationArrowSize; - -// Threshold in radians between heading indicator rotation updates. -extern const CGFloat MGLUserLocationHeadingUpdateThreshold; - -@interface MGLFaux3DUserLocationAnnotationView : MGLUserLocationAnnotationView - -@end diff --git a/ios/RCTMGL/MGLUserLocationHeadingBeamLayer.h b/ios/RCTMGL/MGLUserLocationHeadingBeamLayer.h deleted file mode 100644 index 4003f7e12..000000000 --- a/ios/RCTMGL/MGLUserLocationHeadingBeamLayer.h +++ /dev/null @@ -1,11 +0,0 @@ -#import -#import "MGLUserLocationHeadingIndicator.h" -@import Mapbox; - -@interface MGLUserLocationHeadingBeamLayer : CALayer - -- (MGLUserLocationHeadingBeamLayer *)initWithUserLocationAnnotationView:(MGLUserLocationAnnotationView *)userLocationView; -- (void)updateHeadingAccuracy:(CLLocationDirection)accuracy; -- (void)updateTintColor:(CGColorRef)color; - -@end diff --git a/ios/RCTMGL/RCTMGLBackgroundLayer.h b/ios/RCTMGL/RCTMGLBackgroundLayer.h deleted file mode 100644 index ed264d318..000000000 --- a/ios/RCTMGL/RCTMGLBackgroundLayer.h +++ /dev/null @@ -1,14 +0,0 @@ -// -// RCTMGLBackgroundLayer.h -// RCTMGL -// -// Created by Nick Italiano on 9/25/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import "RCTMGLLayer.h" -@import Mapbox; - -@interface RCTMGLBackgroundLayer : RCTMGLLayer - -@end diff --git a/ios/RCTMGL/RCTMGLBackgroundLayer.m b/ios/RCTMGL/RCTMGLBackgroundLayer.m deleted file mode 100644 index 3321fa797..000000000 --- a/ios/RCTMGL/RCTMGLBackgroundLayer.m +++ /dev/null @@ -1,27 +0,0 @@ -// -// RCTMGLBackgroundLayer.m -// RCTMGL -// -// Created by Nick Italiano on 9/25/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import "RCTMGLBackgroundLayer.h" -#import "RCTMGLStyle.h" - -@implementation RCTMGLBackgroundLayer - -- (MGLStyleLayer*)makeLayer:(MGLStyle*)style -{ - return [[MGLBackgroundStyleLayer alloc] initWithIdentifier:self.id]; -} - -- (void)addStyles -{ - RCTMGLStyle *style = [[RCTMGLStyle alloc] initWithMGLStyle:self.style]; - style.bridge = self.bridge; - [style backgroundLayer:(MGLBackgroundStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; - }]; -} - -@end diff --git a/ios/RCTMGL/RCTMGLCalloutManager.m b/ios/RCTMGL/RCTMGLCalloutManager.m deleted file mode 100644 index 4be9a0e9e..000000000 --- a/ios/RCTMGL/RCTMGLCalloutManager.m +++ /dev/null @@ -1,21 +0,0 @@ -// -// RCTMGLCalloutViewManager.m -// RCTMGL -// -// Created by Nick Italiano on 10/13/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import "RCTMGLCalloutManager.h" -#import "RCTMGLCallout.h" - -@implementation RCTMGLCalloutManager - -RCT_EXPORT_MODULE() - -- (UIView *)view -{ - return [[RCTMGLCallout alloc] init]; -} - -@end diff --git a/ios/RCTMGL/RCTMGLCircleLayer.h b/ios/RCTMGL/RCTMGLCircleLayer.h deleted file mode 100644 index 3bcc9bb48..000000000 --- a/ios/RCTMGL/RCTMGLCircleLayer.h +++ /dev/null @@ -1,13 +0,0 @@ -// -// RCTMGLCircleLayer.h -// RCTMGL -// -// Created by Nick Italiano on 9/18/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import "RCTMGLVectorLayer.h" - -@interface RCTMGLCircleLayer : RCTMGLVectorLayer - -@end diff --git a/ios/RCTMGL/RCTMGLFillExtrusionLayer.h b/ios/RCTMGL/RCTMGLFillExtrusionLayer.h deleted file mode 100644 index 90e8821af..000000000 --- a/ios/RCTMGL/RCTMGLFillExtrusionLayer.h +++ /dev/null @@ -1,14 +0,0 @@ -// -// RCTMGLFillExtrusionLayer.h -// RCTMGL -// -// Created by Nick Italiano on 9/15/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import "RCTMGLVectorLayer.h" -@import Mapbox; - -@interface RCTMGLFillExtrusionLayer : RCTMGLVectorLayer - -@end diff --git a/ios/RCTMGL/RCTMGLFillLayer.h b/ios/RCTMGL/RCTMGLFillLayer.h deleted file mode 100644 index d00fec4cd..000000000 --- a/ios/RCTMGL/RCTMGLFillLayer.h +++ /dev/null @@ -1,14 +0,0 @@ -// -// RCTMGLFillLayer.h -// RCTMGL -// -// Created by Nick Italiano on 9/8/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import "RCTMGLVectorLayer.h" -@import Mapbox; - -@interface RCTMGLFillLayer : RCTMGLVectorLayer - -@end diff --git a/ios/RCTMGL/RCTMGLHeatmapLayer.h b/ios/RCTMGL/RCTMGLHeatmapLayer.h deleted file mode 100644 index b2dec1f71..000000000 --- a/ios/RCTMGL/RCTMGLHeatmapLayer.h +++ /dev/null @@ -1,12 +0,0 @@ -// -// RCTMGLHeatmapLayer.h -// RCTMGL -// -// Created by Dheeraj Yalamanchili on 6/8/19. -// - -#import "RCTMGLVectorLayer.h" - -@interface RCTMGLHeatmapLayer : RCTMGLVectorLayer - -@end diff --git a/ios/RCTMGL/RCTMGLHeatmapLayer.m b/ios/RCTMGL/RCTMGLHeatmapLayer.m deleted file mode 100644 index 9009205eb..000000000 --- a/ios/RCTMGL/RCTMGLHeatmapLayer.m +++ /dev/null @@ -1,30 +0,0 @@ -// -// RCTMGLHeatmapLayer.m -// RCTMGL -// -// Created by Dheeraj Yalamanchili on 6/8/2019 - -#import "RCTMGLHeatmapLayer.h" -#import "RCTMGLStyle.h" - -@implementation RCTMGLHeatmapLayer - -- (MGLHeatmapStyleLayer*)makeLayer:(MGLStyle*)style -{ - MGLSource *source = [self layerWithSourceIDInStyle:style]; - if (source == nil) { return nil; } - MGLHeatmapStyleLayer *layer = [[MGLHeatmapStyleLayer alloc] initWithIdentifier:self.id source:source]; - layer.sourceLayerIdentifier = self.sourceLayerID; - return layer; -} - -- (void)addStyles -{ - RCTMGLStyle *style = [[RCTMGLStyle alloc] initWithMGLStyle:self.style]; - style.bridge = self.bridge; - [style heatmapLayer:(MGLHeatmapStyleLayer *)self.styleLayer withReactStyle:self.reactStyle isValid:^{ - return [self isAddedToMap]; - }]; -} - -@end diff --git a/ios/RCTMGL/RCTMGLHeatmapLayerManager.h b/ios/RCTMGL/RCTMGLHeatmapLayerManager.h deleted file mode 100644 index 1ad776969..000000000 --- a/ios/RCTMGL/RCTMGLHeatmapLayerManager.h +++ /dev/null @@ -1,12 +0,0 @@ -// -// RCTMGLHeatmapLayerManager.h -// RCTMGL -// -// Created by Dheeraj Yalamanchili on 6/8/19. -// - -#import "ViewManager.h" - -@interface RCTMGLHeatmapLayerManager : ViewManager - -@end diff --git a/ios/RCTMGL/RCTMGLImagesManager.h b/ios/RCTMGL/RCTMGLImagesManager.h deleted file mode 100644 index 0f52cd557..000000000 --- a/ios/RCTMGL/RCTMGLImagesManager.h +++ /dev/null @@ -1,5 +0,0 @@ -#import "ViewManager.h" - -@interface RCTMGLImagesManager : ViewManager - -@end diff --git a/ios/RCTMGL/RCTMGLLineLayer.h b/ios/RCTMGL/RCTMGLLineLayer.h deleted file mode 100644 index 27dade82d..000000000 --- a/ios/RCTMGL/RCTMGLLineLayer.h +++ /dev/null @@ -1,14 +0,0 @@ -// -// RCTMGLLineLayer.h -// RCTMGL -// -// Created by Nick Italiano on 9/18/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import "RCTMGLVectorLayer.h" -@import Mapbox; - -@interface RCTMGLLineLayer : RCTMGLVectorLayer - -@end diff --git a/ios/RCTMGL/RCTMGLLocationManager.h b/ios/RCTMGL/RCTMGLLocationManager.h deleted file mode 100644 index 13846a7fc..000000000 --- a/ios/RCTMGL/RCTMGLLocationManager.h +++ /dev/null @@ -1,30 +0,0 @@ -// -// RCTMGLLocationManager.h -// RCTMGL -// -// Created by Nick Italiano on 6/21/18. -// Copyright © 2018 Mapbox Inc. All rights reserved. -// - -#import - -#import "RCTMGLLocation.h" -#import "RCTMGLLocationManagerDelegate.h" - -typedef void (^RCTMGLLocationBlock)(RCTMGLLocation *location); - -@interface RCTMGLLocationManager : NSObject - -@property (nonatomic, strong) id delegate; - -+ (id)sharedInstance; - -- (void)start:(CLLocationDistance)minDisplacement; -- (void)stop; -- (void)setMinDisplacement:(CLLocationDistance)minDisplacement; -- (BOOL)isEnabled; -- (RCTMGLLocation *)getLastKnownLocation; -- (void)addListener:(RCTMGLLocationBlock)listener; -- (void)removeListener:(RCTMGLLocationBlock)listener; - -@end diff --git a/ios/RCTMGL/RCTMGLLocationManagerDelegate.h b/ios/RCTMGL/RCTMGLLocationManagerDelegate.h deleted file mode 100644 index 03bed36a8..000000000 --- a/ios/RCTMGL/RCTMGLLocationManagerDelegate.h +++ /dev/null @@ -1,20 +0,0 @@ -// -// RCTMGLLocationManagerDelegate.h -// RCTMGL -// -// Created by Nick Italiano on 6/21/18. -// Copyright © 2018 Mapbox Inc. All rights reserved. -// - -#import - -#import "RCTMGLLocation.h" - -@class RCTMGLLocationManager; - -@protocol RCTMGLLocationManagerDelegate - -- (void)locationManager:(RCTMGLLocationManager *)locationManager didUpdateLocation:(RCTMGLLocation *)location; - -@end - diff --git a/ios/RCTMGL/RCTMGLLogging.h b/ios/RCTMGL/RCTMGLLogging.h deleted file mode 100644 index 85d37b07f..000000000 --- a/ios/RCTMGL/RCTMGLLogging.h +++ /dev/null @@ -1,18 +0,0 @@ -#ifndef RCTMGLLogging_h -#define RCTMGLLogging_h - -#import -#import - - -@class MGLLoggingConfiguration; - -@interface RCTMGLLogging : RCTEventEmitter - -@property (nonatomic, nonnull) MGLLoggingConfiguration* loggingConfiguration; - -- (void)setLoggingLevel:(nonnull NSString*) logLevel; - -@end - -#endif /* RCTMGLLogging_h */ diff --git a/ios/RCTMGL/RCTMGLNativeUserLocationManager.h b/ios/RCTMGL/RCTMGLNativeUserLocationManager.h deleted file mode 100644 index 5258a4d6f..000000000 --- a/ios/RCTMGL/RCTMGLNativeUserLocationManager.h +++ /dev/null @@ -1,5 +0,0 @@ -#import "ViewManager.h" - -@interface RCTMGLNativeUserLocationManager : ViewManager - -@end diff --git a/ios/RCTMGL/RCTMGLNativeUserLocationManager.m b/ios/RCTMGL/RCTMGLNativeUserLocationManager.m deleted file mode 100644 index 9eb42f6fd..000000000 --- a/ios/RCTMGL/RCTMGLNativeUserLocationManager.m +++ /dev/null @@ -1,25 +0,0 @@ -#import "RCTMGLNativeUserLocationManager.h" -#import "RCTMGLNativeUserLocation.h" - -@implementation RCTMGLNativeUserLocationManager - -RCT_EXPORT_MODULE(RCTMGLNativeUserLocation) -RCT_EXPORT_VIEW_PROPERTY(iosShowsUserHeadingIndicator, BOOL) - - -#pragma - View Properties - - -#pragma Methods - -- (BOOL)requiresMainQueueSetup -{ - return YES; -} - -- (UIView *)view -{ - return [[RCTMGLNativeUserLocation alloc] init]; -} - -@end diff --git a/ios/RCTMGL/RCTMGLRasterLayer.h b/ios/RCTMGL/RCTMGLRasterLayer.h deleted file mode 100644 index af4742122..000000000 --- a/ios/RCTMGL/RCTMGLRasterLayer.h +++ /dev/null @@ -1,14 +0,0 @@ -// -// RCTMGLRasterLayer.h -// RCTMGL -// -// Created by Nick Italiano on 9/25/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import "RCTMGLLayer.h" -@import Mapbox; - -@interface RCTMGLRasterLayer : RCTMGLLayer - -@end diff --git a/ios/RCTMGL/RCTMGLRasterLayer.m b/ios/RCTMGL/RCTMGLRasterLayer.m deleted file mode 100644 index aacc1437f..000000000 --- a/ios/RCTMGL/RCTMGLRasterLayer.m +++ /dev/null @@ -1,30 +0,0 @@ -// -// RCTMGLRasterLayer.m -// RCTMGL -// -// Created by Nick Italiano on 9/25/17. -// Copyright © 2017 Mapbox Inc. All rights reserved. -// - -#import "RCTMGLRasterLayer.h" -#import "RCTMGLStyle.h" - -@implementation RCTMGLRasterLayer - -- (MGLStyleLayer*)makeLayer:(MGLStyle*)style -{ - MGLSource *source = [style sourceWithIdentifier:self.sourceID]; - if (source == nil) { return nil; } - MGLRasterStyleLayer *layer = [[MGLRasterStyleLayer alloc] initWithIdentifier:self.id source:source]; - return layer; -} - -- (void)addStyles -{ - RCTMGLStyle *style = [[RCTMGLStyle alloc] initWithMGLStyle:self.style]; - style.bridge = self.bridge; - [style rasterLayer:(MGLRasterStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; - }]; -} - -@end diff --git a/ios/RCTMGL/RCTMGLStyle.h b/ios/RCTMGL/RCTMGLStyle.h deleted file mode 100644 index 0576d4605..000000000 --- a/ios/RCTMGL/RCTMGLStyle.h +++ /dev/null @@ -1,222 +0,0 @@ -// DO NOT MODIFY -// THIS FILE IS AUTOGENERATED - -#import "RCTMGLStyle.h" -#import "RCTMGLStyleValue.h" -#import - -@import Mapbox; - -@interface RCTMGLStyle : NSObject - -@property (nonatomic, weak) RCTBridge *bridge; -@property (nonatomic, strong) MGLStyle *style; - -- (id)initWithMGLStyle:(MGLStyle*)mglStyle; - -- (void)fillLayer:(MGLFillStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; -- (void)lineLayer:(MGLLineStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; -- (void)symbolLayer:(MGLSymbolStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; -- (void)circleLayer:(MGLCircleStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; -- (void)heatmapLayer:(MGLHeatmapStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; -- (void)fillExtrusionLayer:(MGLFillExtrusionStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; -- (void)rasterLayer:(MGLRasterStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; -- (void)hillshadeLayer:(MGLHillshadeStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; -- (void)backgroundLayer:(MGLBackgroundStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; -- (void)lightLayer:(MGLLight *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; - -- (void)setFillSortKey:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillStyleLayerVisibility:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillAntialias:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillOpacity:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillOpacityTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillColor:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillColorTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillOutlineColor:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillOutlineColorTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillTranslate:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillTranslateTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillTranslateAnchor:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillPattern:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillPatternTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineCap:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineJoin:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineMiterLimit:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineRoundLimit:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineSortKey:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineStyleLayerVisibility:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineOpacity:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineOpacityTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineColor:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineColorTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineTranslate:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineTranslateTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineTranslateAnchor:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineWidth:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineWidthTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineGapWidth:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineGapWidthTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineOffset:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineOffsetTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineBlur:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineBlurTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineDasharray:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineDasharrayTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLinePattern:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLinePatternTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setLineGradient:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setSymbolPlacement:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setSymbolSpacing:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setSymbolAvoidEdges:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setSymbolSortKey:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setSymbolZOrder:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconAllowOverlap:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconIgnorePlacement:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconOptional:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconRotationAlignment:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconSize:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconTextFit:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconTextFitPadding:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconImage:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconRotate:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconPadding:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconKeepUpright:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconOffset:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconPitchAlignment:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextPitchAlignment:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextRotationAlignment:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextField:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextFont:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextSize:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextMaxWidth:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextLineHeight:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextLetterSpacing:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextJustify:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextRadialOffset:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextVariableAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextMaxAngle:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextWritingMode:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextRotate:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextPadding:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextKeepUpright:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextTransform:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextOffset:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextAllowOverlap:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextIgnorePlacement:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextOptional:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setSymbolStyleLayerVisibility:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconOpacity:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconOpacityTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconColor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconColorTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconHaloColor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconHaloColorTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconHaloWidth:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconHaloWidthTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconHaloBlur:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconHaloBlurTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconTranslate:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconTranslateTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIconTranslateAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextOpacity:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextOpacityTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextColor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextColorTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextHaloColor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextHaloColorTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextHaloWidth:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextHaloWidthTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextHaloBlur:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextHaloBlurTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextTranslate:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextTranslateTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setTextTranslateAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleSortKey:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleStyleLayerVisibility:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleRadius:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleRadiusTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleColor:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleColorTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleBlur:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleBlurTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleOpacity:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleOpacityTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleTranslate:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleTranslateTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleTranslateAnchor:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCirclePitchScale:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCirclePitchAlignment:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleStrokeWidth:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleStrokeWidthTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleStrokeColor:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleStrokeColorTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleStrokeOpacity:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setCircleStrokeOpacityTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHeatmapStyleLayerVisibility:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHeatmapRadius:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHeatmapRadiusTransition:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHeatmapWeight:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHeatmapIntensity:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHeatmapIntensityTransition:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHeatmapColor:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHeatmapOpacity:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHeatmapOpacityTransition:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionStyleLayerVisibility:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionOpacity:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionOpacityTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionColor:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionColorTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionTranslate:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionTranslateTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionTranslateAnchor:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionPattern:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionPatternTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionHeight:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionHeightTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionBase:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setFillExtrusionBaseTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterStyleLayerVisibility:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterOpacity:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterOpacityTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterHueRotate:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterHueRotateTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterBrightnessMin:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterBrightnessMinTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterBrightnessMax:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterBrightnessMaxTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterSaturation:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterSaturationTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterContrast:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterContrastTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterResampling:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setRasterFadeDuration:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeStyleLayerVisibility:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeIlluminationDirection:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeIlluminationAnchor:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeExaggeration:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeExaggerationTransition:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeShadowColor:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeShadowColorTransition:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeHighlightColor:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeHighlightColorTransition:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeAccentColor:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setHillshadeAccentColorTransition:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setBackgroundStyleLayerVisibility:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setBackgroundColor:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setBackgroundColorTransition:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setBackgroundPattern:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setBackgroundPatternTransition:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setBackgroundOpacity:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setBackgroundOpacityTransition:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setAnchor:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setPosition:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setPositionTransition:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setColor:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setColorTransition:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIntensity:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; -- (void)setIntensityTransition:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; - - -@end diff --git a/ios/RCTMGL/RCTMGLTileSource.m b/ios/RCTMGL/RCTMGLTileSource.m deleted file mode 100644 index a775cbc98..000000000 --- a/ios/RCTMGL/RCTMGLTileSource.m +++ /dev/null @@ -1,31 +0,0 @@ -// -// BaseSource.m -// RCTMGL -// - -#import "RCTMGLTileSource.h" - -@implementation RCTMGLTileSource - -- (NSDictionary*)getOptions { - NSMutableDictionary *options = [[NSMutableDictionary alloc] init]; - - if (self.maxZoomLevel != nil) { - options[MGLTileSourceOptionMaximumZoomLevel] = self.maxZoomLevel; - } - - if (self.minZoomLevel != nil) { - options[MGLTileSourceOptionMinimumZoomLevel] = self.minZoomLevel; - } - - if (self.tms) { - options[MGLTileSourceOptionTileCoordinateSystem] = [NSNumber numberWithUnsignedInteger:MGLTileCoordinateSystemTMS]; - } - - if (self.attribution != nil) { - options[MGLTileSourceOptionAttributionHTMLString] = self.attribution; - } - - return options; -} -@end diff --git a/ios/RCTMGL/RCTMGLUserLocation.h b/ios/RCTMGL/RCTMGLUserLocation.h deleted file mode 100644 index bae840eb8..000000000 --- a/ios/RCTMGL/RCTMGLUserLocation.h +++ /dev/null @@ -1,15 +0,0 @@ -// -// RCTMGLUserLocation.h -// RCTMGL - -#import -#import -#import - -@interface RCTMGLUserLocation : NSObject - -+ (id)sharedInstance; - -- (MGLUserLocationAnnotationView*)hiddenUserAnnotation; - -@end diff --git a/ios/RCTMLN.xcodeproj/project.pbxproj b/ios/RCTMLN.xcodeproj/project.pbxproj new file mode 100644 index 000000000..029fec98a --- /dev/null +++ b/ios/RCTMLN.xcodeproj/project.pbxproj @@ -0,0 +1,775 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 431CDACE229D61A6008BE92D /* RCTMLNUserLocation.m in Sources */ = {isa = PBXBuildFile; fileRef = 431CDACC229D61A6008BE92D /* RCTMLNUserLocation.m */; }; + 641DE8A8231019E8003B792D /* MLNCustomHeaders.m in Sources */ = {isa = PBXBuildFile; fileRef = 641DE8A7231019E8003B792D /* MLNCustomHeaders.m */; }; + C410D5D51F7AD0B300CF822A /* RCTMLNLight.m in Sources */ = {isa = PBXBuildFile; fileRef = C410D5D41F7AD0B300CF822A /* RCTMLNLight.m */; }; + C410D5D81F7AD0C100CF822A /* RCTMLNLightManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C410D5D71F7AD0C100CF822A /* RCTMLNLightManager.m */; }; + C416015020112B5200006116 /* RNMBImageUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = C416014F20112B5200006116 /* RNMBImageUtils.m */; }; + C42236A41F6B012000FA9C1C /* RCTMLNStyle.m in Sources */ = {isa = PBXBuildFile; fileRef = C42236A31F6B012000FA9C1C /* RCTMLNStyle.m */; }; + C42236A71F6C7F4E00FA9C1C /* RCTMLNFillExtrusionLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C42236A61F6C7F4E00FA9C1C /* RCTMLNFillExtrusionLayer.m */; }; + C42236AA1F6C7F6200FA9C1C /* RCTMLNFillExtrusionLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C42236A91F6C7F6200FA9C1C /* RCTMLNFillExtrusionLayerManager.m */; }; + C435A5F71F587D9100824A30 /* ViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C435A5F61F587D9100824A30 /* ViewManager.m */; }; + C43CA5061F507BCC000B9CB7 /* RCTMLNMapTouchEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = C43CA5051F507BCC000B9CB7 /* RCTMLNMapTouchEvent.m */; }; + C43CA50A1F50C145000B9CB7 /* RCTMLNEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = C43CA5091F50C145000B9CB7 /* RCTMLNEvent.m */; }; + C43CA50D1F53A4EF000B9CB7 /* RCTMLNEventTypes.m in Sources */ = {isa = PBXBuildFile; fileRef = C43CA50C1F53A4EF000B9CB7 /* RCTMLNEventTypes.m */; }; + C45339CD204780EB00888553 /* RCTMLNImageQueueOperation.m in Sources */ = {isa = PBXBuildFile; fileRef = C45339CC204780EB00888553 /* RCTMLNImageQueueOperation.m */; }; + C470F5B81F9E79D400614A69 /* RCTMLNImageQueue.m in Sources */ = {isa = PBXBuildFile; fileRef = C470F5B71F9E79D400614A69 /* RCTMLNImageQueue.m */; }; + C470F6AC1FA11C9500614A69 /* MLNOfflineModule.m in Sources */ = {isa = PBXBuildFile; fileRef = C470F6AB1FA11C9500614A69 /* MLNOfflineModule.m */; }; + C490EE0220DC565000CB2E57 /* RCTMLNLocationModule.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE0120DC565000CB2E57 /* RCTMLNLocationModule.m */; }; + C490EE0520DC575100CB2E57 /* RCTMLNLocationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE0420DC575100CB2E57 /* RCTMLNLocationManager.m */; }; + C490EE0B20DC6B7C00CB2E57 /* RCTMLNLocation.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE0A20DC6B7C00CB2E57 /* RCTMLNLocation.m */; }; + C490EE0E20DD70AD00CB2E57 /* RCTMLNCamera.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE0D20DD70AD00CB2E57 /* RCTMLNCamera.m */; }; + C490EE1120DD710000CB2E57 /* RCTMLNCameraManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C490EE1020DD710000CB2E57 /* RCTMLNCameraManager.m */; }; + C4C87A601F844C820064AE95 /* FilterParser.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87A5F1F844C820064AE95 /* FilterParser.m */; }; + C4C87B7B1F8FEBF50064AE95 /* RCTMLNPointAnnotationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87B7A1F8FEBF40064AE95 /* RCTMLNPointAnnotationManager.m */; }; + C4C87B7E1F8FEC090064AE95 /* RCTMLNPointAnnotation.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87B7D1F8FEC090064AE95 /* RCTMLNPointAnnotation.m */; }; + C4C87B911F9142FB0064AE95 /* RCTMLNCallout.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87B901F9142FB0064AE95 /* RCTMLNCallout.m */; }; + C4C87B941F9143DA0064AE95 /* RCTMLNCalloutManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4C87B931F9143DA0064AE95 /* RCTMLNCalloutManager.m */; }; + C4D144421F4E16F600396F26 /* RCTMLN.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D144411F4E16F600396F26 /* RCTMLN.m */; }; + C4D144431F4E16F600396F26 /* RCTMLN.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = C4D144401F4E16F600396F26 /* RCTMLN.h */; }; + C4D1444C1F4E178100396F26 /* RCTMLNMapView.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D1444B1F4E178100396F26 /* RCTMLNMapView.m */; }; + C4D1444F1F4E181100396F26 /* RCTMLNMapViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D1444E1F4E181100396F26 /* RCTMLNMapViewManager.m */; }; + C4D144531F4E190C00396F26 /* MLNModule.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D144521F4E190C00396F26 /* MLNModule.m */; }; + C4D144971F4E2F1100396F26 /* RCTMLNUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = C4D144961F4E2F1100396F26 /* RCTMLNUtils.m */; }; + C4EA22191F675ACE00EF2500 /* RCTMLNStyleValue.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EA22181F675ACE00EF2500 /* RCTMLNStyleValue.m */; }; + C4EAF1201F5FC07E0016DEE8 /* CameraStop.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF11F1F5FC07E0016DEE8 /* CameraStop.m */; }; + C4EAF1241F606F7C0016DEE8 /* CameraMode.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1231F606F7C0016DEE8 /* CameraMode.m */; }; + C4EAF1271F6083C70016DEE8 /* CameraUpdateItem.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1261F6083C70016DEE8 /* CameraUpdateItem.m */; }; + C4EAF12A1F6084920016DEE8 /* CameraUpdateQueue.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1291F6084920016DEE8 /* CameraUpdateQueue.m */; }; + C4EAF17D1F6324970016DEE8 /* RCTMLNSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF17C1F6324970016DEE8 /* RCTMLNSource.m */; }; + C4EAF1801F6324A80016DEE8 /* RCTMLNLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF17F1F6324A80016DEE8 /* RCTMLNLayer.m */; }; + C4EAF1831F6336E20016DEE8 /* RCTMLNVectorSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1821F6336E20016DEE8 /* RCTMLNVectorSource.m */; }; + C4EAF1891F633C010016DEE8 /* RCTMLNVectorSourceManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1881F633C010016DEE8 /* RCTMLNVectorSourceManager.m */; }; + C4EAF18F1F633E020016DEE8 /* RCTMLNFillLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF18E1F633E020016DEE8 /* RCTMLNFillLayer.m */; }; + C4EAF1921F6341520016DEE8 /* RCTMLNFillLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4EAF1911F6341520016DEE8 /* RCTMLNFillLayerManager.m */; }; + C4FB10FE1F707A140055AE1F /* RCTMLNLineLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB10FD1F707A140055AE1F /* RCTMLNLineLayer.m */; }; + C4FB11011F707A280055AE1F /* RCTMLNLineLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11001F707A280055AE1F /* RCTMLNLineLayerManager.m */; }; + C4FB11041F709CDC0055AE1F /* RCTMLNCircleLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11031F709CDC0055AE1F /* RCTMLNCircleLayer.m */; }; + C4FB11071F709CEF0055AE1F /* RCTMLNCircleLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11061F709CEF0055AE1F /* RCTMLNCircleLayerManager.m */; }; + C4FB110A1F71D09E0055AE1F /* RCTMLNShapeSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11091F71D09E0055AE1F /* RCTMLNShapeSource.m */; }; + C4FB110D1F71D0B10055AE1F /* RCTMLNShapeSourceManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB110C1F71D0B10055AE1F /* RCTMLNShapeSourceManager.m */; }; + C4FB11101F71EC8D0055AE1F /* RCTMLNSymbolLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB110F1F71EC8D0055AE1F /* RCTMLNSymbolLayer.m */; }; + C4FB11131F71EC9F0055AE1F /* RCTMLNSymbolLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB11121F71EC9F0055AE1F /* RCTMLNSymbolLayerManager.m */; }; + C4FB122D1F7972A00055AE1F /* RCTMLNRasterSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB122C1F7972A00055AE1F /* RCTMLNRasterSource.m */; }; + C4FB12301F7972B40055AE1F /* RCTMLNRasterSourceManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB122F1F7972B40055AE1F /* RCTMLNRasterSourceManager.m */; }; + C4FB12331F799F190055AE1F /* RCTMLNRasterLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB12321F799F190055AE1F /* RCTMLNRasterLayer.m */; }; + C4FB12361F799F280055AE1F /* RCTMLNRasterLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB12351F799F280055AE1F /* RCTMLNRasterLayerManager.m */; }; + C4FB12581F79C0270055AE1F /* RCTMLNBackgroundLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB12571F79C0270055AE1F /* RCTMLNBackgroundLayer.m */; }; + C4FB125B1F79C03E0055AE1F /* RCTMLNBackgroundLayerManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FB125A1F79C03E0055AE1F /* RCTMLNBackgroundLayerManager.m */; }; + C4FD1DBF1FCF54FB00213AF2 /* RCTMLNImageSource.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FD1DBE1FCF54FB00213AF2 /* RCTMLNImageSource.m */; }; + C4FD1DC21FCF550E00213AF2 /* RCTMLNImageSourceManager.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FD1DC11FCF550E00213AF2 /* RCTMLNImageSourceManager.m */; }; + C4FD1DC51FD1F04300213AF2 /* MLNSnapshotModule.m in Sources */ = {isa = PBXBuildFile; fileRef = C4FD1DC41FD1F04200213AF2 /* MLNSnapshotModule.m */; }; + D8C1903323F5382C00223486 /* RCTMLNImages.m in Sources */ = {isa = PBXBuildFile; fileRef = D8C1903223F5382C00223486 /* RCTMLNImages.m */; }; + D8C1903523F53B0F00223486 /* RCTMLNImagesManager.m in Sources */ = {isa = PBXBuildFile; fileRef = D8C1903423F53B0F00223486 /* RCTMLNImagesManager.m */; }; + DF16042F233BFDD100A4231D /* RCTMLNTileSource.m in Sources */ = {isa = PBXBuildFile; fileRef = DF16042E233BFDD000A4231D /* RCTMLNTileSource.m */; }; + DF3CFC0622CFCE0500A83174 /* RCTMLNNativeUserLocation.m in Sources */ = {isa = PBXBuildFile; fileRef = DF3CFC0222CFCE0500A83174 /* RCTMLNNativeUserLocation.m */; }; + DF3CFC0722CFCE0500A83174 /* RCTMLNNativeUserLocationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = DF3CFC0322CFCE0500A83174 /* RCTMLNNativeUserLocationManager.m */; }; +/* End PBXBuildFile section */ + +/* Begin PBXCopyFilesBuildPhase section */ + C4D1443B1F4E16F600396F26 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = "include/$(PRODUCT_NAME)"; + dstSubfolderSpec = 16; + files = ( + C4D144431F4E16F600396F26 /* RCTMLN.h in CopyFiles */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXCopyFilesBuildPhase section */ + +/* Begin PBXFileReference section */ + 431CDACC229D61A6008BE92D /* RCTMLNUserLocation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNUserLocation.m; sourceTree = ""; }; + 431CDACD229D61A6008BE92D /* RCTMLNUserLocation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNUserLocation.h; sourceTree = ""; }; + 641DE8A6231019E8003B792D /* MLNCustomHeaders.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MLNCustomHeaders.h; sourceTree = ""; }; + 641DE8A7231019E8003B792D /* MLNCustomHeaders.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MLNCustomHeaders.m; sourceTree = ""; }; + C410D5D31F7AD0B300CF822A /* RCTMLNLight.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNLight.h; sourceTree = ""; }; + C410D5D41F7AD0B300CF822A /* RCTMLNLight.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNLight.m; sourceTree = ""; }; + C410D5D61F7AD0C100CF822A /* RCTMLNLightManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNLightManager.h; sourceTree = ""; }; + C410D5D71F7AD0C100CF822A /* RCTMLNLightManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNLightManager.m; sourceTree = ""; }; + C416014E20112B5200006116 /* RNMBImageUtils.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RNMBImageUtils.h; sourceTree = ""; }; + C416014F20112B5200006116 /* RNMBImageUtils.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNMBImageUtils.m; sourceTree = ""; }; + C42236A21F6B012000FA9C1C /* RCTMLNStyle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNStyle.h; sourceTree = ""; }; + C42236A31F6B012000FA9C1C /* RCTMLNStyle.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNStyle.m; sourceTree = ""; }; + C42236A51F6C7F4E00FA9C1C /* RCTMLNFillExtrusionLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNFillExtrusionLayer.h; sourceTree = ""; }; + C42236A61F6C7F4E00FA9C1C /* RCTMLNFillExtrusionLayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNFillExtrusionLayer.m; sourceTree = ""; }; + C42236A81F6C7F6200FA9C1C /* RCTMLNFillExtrusionLayerManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNFillExtrusionLayerManager.h; sourceTree = ""; }; + C42236A91F6C7F6200FA9C1C /* RCTMLNFillExtrusionLayerManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNFillExtrusionLayerManager.m; sourceTree = ""; }; + C435A5F51F587D9100824A30 /* ViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ViewManager.h; sourceTree = ""; }; + C435A5F61F587D9100824A30 /* ViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ViewManager.m; sourceTree = ""; }; + C43CA5041F507BCC000B9CB7 /* RCTMLNMapTouchEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNMapTouchEvent.h; sourceTree = ""; }; + C43CA5051F507BCC000B9CB7 /* RCTMLNMapTouchEvent.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNMapTouchEvent.m; sourceTree = ""; }; + C43CA5071F507D88000B9CB7 /* RCTMLNEventProtocol.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNEventProtocol.h; sourceTree = ""; }; + C43CA5081F50C145000B9CB7 /* RCTMLNEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNEvent.h; sourceTree = ""; }; + C43CA5091F50C145000B9CB7 /* RCTMLNEvent.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNEvent.m; sourceTree = ""; }; + C43CA50B1F53A4EF000B9CB7 /* RCTMLNEventTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNEventTypes.h; sourceTree = ""; }; + C43CA50C1F53A4EF000B9CB7 /* RCTMLNEventTypes.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNEventTypes.m; sourceTree = ""; }; + C45339CB204780EB00888553 /* RCTMLNImageQueueOperation.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNImageQueueOperation.h; sourceTree = ""; }; + C45339CC204780EB00888553 /* RCTMLNImageQueueOperation.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNImageQueueOperation.m; sourceTree = ""; }; + C470F5B61F9E79D400614A69 /* RCTMLNImageQueue.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNImageQueue.h; sourceTree = ""; }; + C470F5B71F9E79D400614A69 /* RCTMLNImageQueue.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNImageQueue.m; sourceTree = ""; }; + C470F6AA1FA11C9500614A69 /* MLNOfflineModule.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MLNOfflineModule.h; sourceTree = ""; }; + C470F6AB1FA11C9500614A69 /* MLNOfflineModule.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MLNOfflineModule.m; sourceTree = ""; }; + C490EE0020DC565000CB2E57 /* RCTMLNLocationModule.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNLocationModule.h; sourceTree = ""; }; + C490EE0120DC565000CB2E57 /* RCTMLNLocationModule.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNLocationModule.m; sourceTree = ""; }; + C490EE0320DC575100CB2E57 /* RCTMLNLocationManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNLocationManager.h; sourceTree = ""; }; + C490EE0420DC575100CB2E57 /* RCTMLNLocationManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNLocationManager.m; sourceTree = ""; }; + C490EE0620DC5CDB00CB2E57 /* RCTMLNLocationManagerDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNLocationManagerDelegate.h; sourceTree = ""; }; + C490EE0720DC66DD00CB2E57 /* RCTMLNLocation.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNLocation.h; sourceTree = ""; }; + C490EE0A20DC6B7C00CB2E57 /* RCTMLNLocation.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNLocation.m; sourceTree = ""; }; + C490EE0C20DD70AD00CB2E57 /* RCTMLNCamera.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNCamera.h; sourceTree = ""; }; + C490EE0D20DD70AD00CB2E57 /* RCTMLNCamera.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNCamera.m; sourceTree = ""; }; + C490EE0F20DD710000CB2E57 /* RCTMLNCameraManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNCameraManager.h; sourceTree = ""; }; + C490EE1020DD710000CB2E57 /* RCTMLNCameraManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNCameraManager.m; sourceTree = ""; }; + C4C87A5E1F844C820064AE95 /* FilterParser.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = FilterParser.h; sourceTree = ""; }; + C4C87A5F1F844C820064AE95 /* FilterParser.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = FilterParser.m; sourceTree = ""; }; + C4C87B791F8FEBF40064AE95 /* RCTMLNPointAnnotationManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNPointAnnotationManager.h; sourceTree = ""; }; + C4C87B7A1F8FEBF40064AE95 /* RCTMLNPointAnnotationManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNPointAnnotationManager.m; sourceTree = ""; }; + C4C87B7C1F8FEC080064AE95 /* RCTMLNPointAnnotation.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNPointAnnotation.h; sourceTree = ""; }; + C4C87B7D1F8FEC090064AE95 /* RCTMLNPointAnnotation.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNPointAnnotation.m; sourceTree = ""; }; + C4C87B8F1F9142FB0064AE95 /* RCTMLNCallout.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNCallout.h; sourceTree = ""; }; + C4C87B901F9142FB0064AE95 /* RCTMLNCallout.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNCallout.m; sourceTree = ""; }; + C4C87B921F9143DA0064AE95 /* RCTMLNCalloutManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNCalloutManager.h; sourceTree = ""; }; + C4C87B931F9143DA0064AE95 /* RCTMLNCalloutManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNCalloutManager.m; sourceTree = ""; }; + C4D1443D1F4E16F600396F26 /* libRCTMLN.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libRCTMLN.a; sourceTree = BUILT_PRODUCTS_DIR; }; + C4D144401F4E16F600396F26 /* RCTMLN.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLN.h; sourceTree = ""; }; + C4D144411F4E16F600396F26 /* RCTMLN.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLN.m; sourceTree = ""; }; + C4D1444A1F4E178100396F26 /* RCTMLNMapView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNMapView.h; sourceTree = ""; }; + C4D1444B1F4E178100396F26 /* RCTMLNMapView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNMapView.m; sourceTree = ""; }; + C4D1444D1F4E181100396F26 /* RCTMLNMapViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNMapViewManager.h; sourceTree = ""; }; + C4D1444E1F4E181100396F26 /* RCTMLNMapViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNMapViewManager.m; sourceTree = ""; }; + C4D144511F4E190C00396F26 /* MLNModule.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MLNModule.h; sourceTree = ""; }; + C4D144521F4E190C00396F26 /* MLNModule.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MLNModule.m; sourceTree = ""; }; + C4D144951F4E2F1100396F26 /* RCTMLNUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNUtils.h; sourceTree = ""; }; + C4D144961F4E2F1100396F26 /* RCTMLNUtils.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNUtils.m; sourceTree = ""; }; + C4EA22171F675ACE00EF2500 /* RCTMLNStyleValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNStyleValue.h; sourceTree = ""; }; + C4EA22181F675ACE00EF2500 /* RCTMLNStyleValue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNStyleValue.m; sourceTree = ""; }; + C4EAF11E1F5FC07E0016DEE8 /* CameraStop.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CameraStop.h; sourceTree = ""; }; + C4EAF11F1F5FC07E0016DEE8 /* CameraStop.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CameraStop.m; sourceTree = ""; }; + C4EAF1221F606F7C0016DEE8 /* CameraMode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CameraMode.h; sourceTree = ""; }; + C4EAF1231F606F7C0016DEE8 /* CameraMode.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CameraMode.m; sourceTree = ""; }; + C4EAF1251F6083C70016DEE8 /* CameraUpdateItem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CameraUpdateItem.h; sourceTree = ""; }; + C4EAF1261F6083C70016DEE8 /* CameraUpdateItem.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CameraUpdateItem.m; sourceTree = ""; }; + C4EAF1281F6084920016DEE8 /* CameraUpdateQueue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CameraUpdateQueue.h; sourceTree = ""; }; + C4EAF1291F6084920016DEE8 /* CameraUpdateQueue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CameraUpdateQueue.m; sourceTree = ""; }; + C4EAF17B1F6324970016DEE8 /* RCTMLNSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNSource.h; sourceTree = ""; }; + C4EAF17C1F6324970016DEE8 /* RCTMLNSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNSource.m; sourceTree = ""; }; + C4EAF17E1F6324A80016DEE8 /* RCTMLNLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNLayer.h; sourceTree = ""; }; + C4EAF17F1F6324A80016DEE8 /* RCTMLNLayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNLayer.m; sourceTree = ""; }; + C4EAF1811F6336E20016DEE8 /* RCTMLNVectorSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNVectorSource.h; sourceTree = ""; }; + C4EAF1821F6336E20016DEE8 /* RCTMLNVectorSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNVectorSource.m; sourceTree = ""; }; + C4EAF1871F633C010016DEE8 /* RCTMLNVectorSourceManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNVectorSourceManager.h; sourceTree = ""; }; + C4EAF1881F633C010016DEE8 /* RCTMLNVectorSourceManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNVectorSourceManager.m; sourceTree = ""; }; + C4EAF18D1F633E020016DEE8 /* RCTMLNFillLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNFillLayer.h; sourceTree = ""; }; + C4EAF18E1F633E020016DEE8 /* RCTMLNFillLayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNFillLayer.m; sourceTree = ""; }; + C4EAF1901F6341520016DEE8 /* RCTMLNFillLayerManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNFillLayerManager.h; sourceTree = ""; }; + C4EAF1911F6341520016DEE8 /* RCTMLNFillLayerManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNFillLayerManager.m; sourceTree = ""; }; + C4FB10FC1F707A140055AE1F /* RCTMLNLineLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNLineLayer.h; sourceTree = ""; }; + C4FB10FD1F707A140055AE1F /* RCTMLNLineLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNLineLayer.m; sourceTree = ""; }; + C4FB10FF1F707A280055AE1F /* RCTMLNLineLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNLineLayerManager.h; sourceTree = ""; }; + C4FB11001F707A280055AE1F /* RCTMLNLineLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNLineLayerManager.m; sourceTree = ""; }; + C4FB11021F709CDC0055AE1F /* RCTMLNCircleLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNCircleLayer.h; sourceTree = ""; }; + C4FB11031F709CDC0055AE1F /* RCTMLNCircleLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNCircleLayer.m; sourceTree = ""; }; + C4FB11051F709CEF0055AE1F /* RCTMLNCircleLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNCircleLayerManager.h; sourceTree = ""; }; + C4FB11061F709CEF0055AE1F /* RCTMLNCircleLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNCircleLayerManager.m; sourceTree = ""; }; + C4FB11081F71D09E0055AE1F /* RCTMLNShapeSource.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNShapeSource.h; sourceTree = ""; }; + C4FB11091F71D09E0055AE1F /* RCTMLNShapeSource.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNShapeSource.m; sourceTree = ""; }; + C4FB110B1F71D0B10055AE1F /* RCTMLNShapeSourceManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNShapeSourceManager.h; sourceTree = ""; }; + C4FB110C1F71D0B10055AE1F /* RCTMLNShapeSourceManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNShapeSourceManager.m; sourceTree = ""; }; + C4FB110E1F71EC8D0055AE1F /* RCTMLNSymbolLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNSymbolLayer.h; sourceTree = ""; }; + C4FB110F1F71EC8D0055AE1F /* RCTMLNSymbolLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNSymbolLayer.m; sourceTree = ""; }; + C4FB11111F71EC9F0055AE1F /* RCTMLNSymbolLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNSymbolLayerManager.h; sourceTree = ""; }; + C4FB11121F71EC9F0055AE1F /* RCTMLNSymbolLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNSymbolLayerManager.m; sourceTree = ""; }; + C4FB122B1F7972A00055AE1F /* RCTMLNRasterSource.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNRasterSource.h; sourceTree = ""; }; + C4FB122C1F7972A00055AE1F /* RCTMLNRasterSource.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNRasterSource.m; sourceTree = ""; }; + C4FB122E1F7972B40055AE1F /* RCTMLNRasterSourceManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNRasterSourceManager.h; sourceTree = ""; }; + C4FB122F1F7972B40055AE1F /* RCTMLNRasterSourceManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNRasterSourceManager.m; sourceTree = ""; }; + C4FB12311F799F190055AE1F /* RCTMLNRasterLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNRasterLayer.h; sourceTree = ""; }; + C4FB12321F799F190055AE1F /* RCTMLNRasterLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNRasterLayer.m; sourceTree = ""; }; + C4FB12341F799F280055AE1F /* RCTMLNRasterLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNRasterLayerManager.h; sourceTree = ""; }; + C4FB12351F799F280055AE1F /* RCTMLNRasterLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNRasterLayerManager.m; sourceTree = ""; }; + C4FB12561F79C0270055AE1F /* RCTMLNBackgroundLayer.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNBackgroundLayer.h; sourceTree = ""; }; + C4FB12571F79C0270055AE1F /* RCTMLNBackgroundLayer.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNBackgroundLayer.m; sourceTree = ""; }; + C4FB12591F79C03E0055AE1F /* RCTMLNBackgroundLayerManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNBackgroundLayerManager.h; sourceTree = ""; }; + C4FB125A1F79C03E0055AE1F /* RCTMLNBackgroundLayerManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNBackgroundLayerManager.m; sourceTree = ""; }; + C4FD1DBD1FCF54FB00213AF2 /* RCTMLNImageSource.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNImageSource.h; sourceTree = ""; }; + C4FD1DBE1FCF54FB00213AF2 /* RCTMLNImageSource.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNImageSource.m; sourceTree = ""; }; + C4FD1DC01FCF550E00213AF2 /* RCTMLNImageSourceManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNImageSourceManager.h; sourceTree = ""; }; + C4FD1DC11FCF550E00213AF2 /* RCTMLNImageSourceManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNImageSourceManager.m; sourceTree = ""; }; + C4FD1DC31FD1F04200213AF2 /* MLNSnapshotModule.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MLNSnapshotModule.h; sourceTree = ""; }; + C4FD1DC41FD1F04200213AF2 /* MLNSnapshotModule.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MLNSnapshotModule.m; sourceTree = ""; }; + D8C1903123F5382C00223486 /* RCTMLNImages.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNImages.h; sourceTree = ""; }; + D8C1903223F5382C00223486 /* RCTMLNImages.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNImages.m; sourceTree = ""; }; + D8C1903423F53B0F00223486 /* RCTMLNImagesManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RCTMLNImagesManager.m; sourceTree = ""; }; + D8C1903623F53B3C00223486 /* RCTMLNImagesManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RCTMLNImagesManager.h; sourceTree = ""; }; + DF16042D233BFDD000A4231D /* RCTMLNTileSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNTileSource.h; sourceTree = ""; }; + DF16042E233BFDD000A4231D /* RCTMLNTileSource.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNTileSource.m; sourceTree = ""; }; + DF3CFC0222CFCE0500A83174 /* RCTMLNNativeUserLocation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNNativeUserLocation.m; sourceTree = ""; }; + DF3CFC0322CFCE0500A83174 /* RCTMLNNativeUserLocationManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTMLNNativeUserLocationManager.m; sourceTree = ""; }; + DF3CFC0422CFCE0500A83174 /* RCTMLNNativeUserLocationManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNNativeUserLocationManager.h; sourceTree = ""; }; + DF3CFC0522CFCE0500A83174 /* RCTMLNNativeUserLocation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTMLNNativeUserLocation.h; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + C4D1443A1F4E16F600396F26 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + C410D5D21F7AD0A200CF822A /* Light */ = { + isa = PBXGroup; + children = ( + C410D5D31F7AD0B300CF822A /* RCTMLNLight.h */, + C410D5D41F7AD0B300CF822A /* RCTMLNLight.m */, + C410D5D61F7AD0C100CF822A /* RCTMLNLightManager.h */, + C410D5D71F7AD0C100CF822A /* RCTMLNLightManager.m */, + ); + name = Light; + sourceTree = ""; + }; + C42219B21FEB1FD600EE9E35 /* Location */ = { + isa = PBXGroup; + children = ( + 431CDACD229D61A6008BE92D /* RCTMLNUserLocation.h */, + 431CDACC229D61A6008BE92D /* RCTMLNUserLocation.m */, + C490EE0320DC575100CB2E57 /* RCTMLNLocationManager.h */, + C490EE0420DC575100CB2E57 /* RCTMLNLocationManager.m */, + C490EE0620DC5CDB00CB2E57 /* RCTMLNLocationManagerDelegate.h */, + C490EE0720DC66DD00CB2E57 /* RCTMLNLocation.h */, + C490EE0A20DC6B7C00CB2E57 /* RCTMLNLocation.m */, + ); + name = Location; + sourceTree = ""; + }; + C43773B91F56024900AF6D71 /* Components */ = { + isa = PBXGroup; + children = ( + D8C1903023F537D300223486 /* Images */, + C435A5F51F587D9100824A30 /* ViewManager.h */, + C435A5F61F587D9100824A30 /* ViewManager.m */, + C4C87B781F8FEB4D0064AE95 /* Annotations */, + C4EAF0EE1F5FAEB50016DEE8 /* Camera */, + DF3CFC0122CFCD8B00A83174 /* Location */, + C43773BA1F56025800AF6D71 /* MapView */, + C4EAF1781F6320A40016DEE8 /* Styles */, + ); + name = Components; + sourceTree = ""; + }; + C43773BA1F56025800AF6D71 /* MapView */ = { + isa = PBXGroup; + children = ( + C4D1444A1F4E178100396F26 /* RCTMLNMapView.h */, + C4D1444B1F4E178100396F26 /* RCTMLNMapView.m */, + C4D1444D1F4E181100396F26 /* RCTMLNMapViewManager.h */, + C4D1444E1F4E181100396F26 /* RCTMLNMapViewManager.m */, + ); + name = MapView; + sourceTree = ""; + }; + C43773BD1F5603AA00AF6D71 /* Constants */ = { + isa = PBXGroup; + children = ( + C43CA50B1F53A4EF000B9CB7 /* RCTMLNEventTypes.h */, + C43CA50C1F53A4EF000B9CB7 /* RCTMLNEventTypes.m */, + ); + name = Constants; + sourceTree = ""; + }; + C43CA5031F507B8D000B9CB7 /* Events */ = { + isa = PBXGroup; + children = ( + C43CA5041F507BCC000B9CB7 /* RCTMLNMapTouchEvent.h */, + C43CA5051F507BCC000B9CB7 /* RCTMLNMapTouchEvent.m */, + C43CA5071F507D88000B9CB7 /* RCTMLNEventProtocol.h */, + C43CA5081F50C145000B9CB7 /* RCTMLNEvent.h */, + C43CA5091F50C145000B9CB7 /* RCTMLNEvent.m */, + C43773BD1F5603AA00AF6D71 /* Constants */, + ); + name = Events; + sourceTree = ""; + }; + C4C87B781F8FEB4D0064AE95 /* Annotations */ = { + isa = PBXGroup; + children = ( + C4C87B791F8FEBF40064AE95 /* RCTMLNPointAnnotationManager.h */, + C4C87B7A1F8FEBF40064AE95 /* RCTMLNPointAnnotationManager.m */, + C4C87B7C1F8FEC080064AE95 /* RCTMLNPointAnnotation.h */, + C4C87B7D1F8FEC090064AE95 /* RCTMLNPointAnnotation.m */, + C4C87B8F1F9142FB0064AE95 /* RCTMLNCallout.h */, + C4C87B901F9142FB0064AE95 /* RCTMLNCallout.m */, + C4C87B921F9143DA0064AE95 /* RCTMLNCalloutManager.h */, + C4C87B931F9143DA0064AE95 /* RCTMLNCalloutManager.m */, + ); + name = Annotations; + sourceTree = ""; + }; + C4D144341F4E16F600396F26 = { + isa = PBXGroup; + children = ( + C4D1443F1F4E16F600396F26 /* RCTMLN */, + C4D1443E1F4E16F600396F26 /* Products */, + ); + sourceTree = ""; + }; + C4D1443E1F4E16F600396F26 /* Products */ = { + isa = PBXGroup; + children = ( + C4D1443D1F4E16F600396F26 /* libRCTMLN.a */, + ); + name = Products; + sourceTree = ""; + }; + C4D1443F1F4E16F600396F26 /* RCTMLN */ = { + isa = PBXGroup; + children = ( + C42219B21FEB1FD600EE9E35 /* Location */, + C43773B91F56024900AF6D71 /* Components */, + C43CA5031F507B8D000B9CB7 /* Events */, + C4D144941F4E2EC800396F26 /* Utils */, + C4D144501F4E188F00396F26 /* Modules */, + C4D144401F4E16F600396F26 /* RCTMLN.h */, + C4D144411F4E16F600396F26 /* RCTMLN.m */, + ); + path = RCTMLN; + sourceTree = ""; + }; + C4D144501F4E188F00396F26 /* Modules */ = { + isa = PBXGroup; + children = ( + 641DE8A6231019E8003B792D /* MLNCustomHeaders.h */, + 641DE8A7231019E8003B792D /* MLNCustomHeaders.m */, + C4D144511F4E190C00396F26 /* MLNModule.h */, + C4D144521F4E190C00396F26 /* MLNModule.m */, + C470F6AA1FA11C9500614A69 /* MLNOfflineModule.h */, + C470F6AB1FA11C9500614A69 /* MLNOfflineModule.m */, + C4FD1DC31FD1F04200213AF2 /* MLNSnapshotModule.h */, + C4FD1DC41FD1F04200213AF2 /* MLNSnapshotModule.m */, + C490EE0020DC565000CB2E57 /* RCTMLNLocationModule.h */, + C490EE0120DC565000CB2E57 /* RCTMLNLocationModule.m */, + ); + name = Modules; + sourceTree = ""; + }; + C4D144941F4E2EC800396F26 /* Utils */ = { + isa = PBXGroup; + children = ( + C4D144951F4E2F1100396F26 /* RCTMLNUtils.h */, + C4D144961F4E2F1100396F26 /* RCTMLNUtils.m */, + C4C87A5E1F844C820064AE95 /* FilterParser.h */, + C4C87A5F1F844C820064AE95 /* FilterParser.m */, + C470F5B61F9E79D400614A69 /* RCTMLNImageQueue.h */, + C470F5B71F9E79D400614A69 /* RCTMLNImageQueue.m */, + C416014E20112B5200006116 /* RNMBImageUtils.h */, + C416014F20112B5200006116 /* RNMBImageUtils.m */, + C45339CB204780EB00888553 /* RCTMLNImageQueueOperation.h */, + C45339CC204780EB00888553 /* RCTMLNImageQueueOperation.m */, + ); + name = Utils; + sourceTree = ""; + }; + C4EAF0EE1F5FAEB50016DEE8 /* Camera */ = { + isa = PBXGroup; + children = ( + C4EAF1211F606F610016DEE8 /* Constants */, + C4EAF11E1F5FC07E0016DEE8 /* CameraStop.h */, + C4EAF11F1F5FC07E0016DEE8 /* CameraStop.m */, + C4EAF1251F6083C70016DEE8 /* CameraUpdateItem.h */, + C4EAF1261F6083C70016DEE8 /* CameraUpdateItem.m */, + C4EAF1281F6084920016DEE8 /* CameraUpdateQueue.h */, + C4EAF1291F6084920016DEE8 /* CameraUpdateQueue.m */, + C490EE0C20DD70AD00CB2E57 /* RCTMLNCamera.h */, + C490EE0D20DD70AD00CB2E57 /* RCTMLNCamera.m */, + C490EE0F20DD710000CB2E57 /* RCTMLNCameraManager.h */, + C490EE1020DD710000CB2E57 /* RCTMLNCameraManager.m */, + ); + name = Camera; + sourceTree = ""; + }; + C4EAF1211F606F610016DEE8 /* Constants */ = { + isa = PBXGroup; + children = ( + C4EAF1221F606F7C0016DEE8 /* CameraMode.h */, + C4EAF1231F606F7C0016DEE8 /* CameraMode.m */, + ); + name = Constants; + sourceTree = ""; + }; + C4EAF1781F6320A40016DEE8 /* Styles */ = { + isa = PBXGroup; + children = ( + C42236A21F6B012000FA9C1C /* RCTMLNStyle.h */, + C42236A31F6B012000FA9C1C /* RCTMLNStyle.m */, + C410D5D21F7AD0A200CF822A /* Light */, + C4EAF17A1F6320B10016DEE8 /* Layers */, + C4EAF1791F6320AA0016DEE8 /* Sources */, + C4EA22171F675ACE00EF2500 /* RCTMLNStyleValue.h */, + C4EA22181F675ACE00EF2500 /* RCTMLNStyleValue.m */, + ); + name = Styles; + sourceTree = ""; + }; + C4EAF1791F6320AA0016DEE8 /* Sources */ = { + isa = PBXGroup; + children = ( + C4EAF17B1F6324970016DEE8 /* RCTMLNSource.h */, + C4EAF17C1F6324970016DEE8 /* RCTMLNSource.m */, + C4EAF1811F6336E20016DEE8 /* RCTMLNVectorSource.h */, + C4EAF1821F6336E20016DEE8 /* RCTMLNVectorSource.m */, + C4EAF1871F633C010016DEE8 /* RCTMLNVectorSourceManager.h */, + C4EAF1881F633C010016DEE8 /* RCTMLNVectorSourceManager.m */, + C4FB11081F71D09E0055AE1F /* RCTMLNShapeSource.h */, + C4FB11091F71D09E0055AE1F /* RCTMLNShapeSource.m */, + C4FB110B1F71D0B10055AE1F /* RCTMLNShapeSourceManager.h */, + C4FB110C1F71D0B10055AE1F /* RCTMLNShapeSourceManager.m */, + DF16042D233BFDD000A4231D /* RCTMLNTileSource.h */, + DF16042E233BFDD000A4231D /* RCTMLNTileSource.m */, + C4FB122B1F7972A00055AE1F /* RCTMLNRasterSource.h */, + C4FB122C1F7972A00055AE1F /* RCTMLNRasterSource.m */, + C4FB122E1F7972B40055AE1F /* RCTMLNRasterSourceManager.h */, + C4FB122F1F7972B40055AE1F /* RCTMLNRasterSourceManager.m */, + C4FD1DBD1FCF54FB00213AF2 /* RCTMLNImageSource.h */, + C4FD1DBE1FCF54FB00213AF2 /* RCTMLNImageSource.m */, + C4FD1DC01FCF550E00213AF2 /* RCTMLNImageSourceManager.h */, + C4FD1DC11FCF550E00213AF2 /* RCTMLNImageSourceManager.m */, + ); + name = Sources; + sourceTree = ""; + }; + C4EAF17A1F6320B10016DEE8 /* Layers */ = { + isa = PBXGroup; + children = ( + C4EAF17E1F6324A80016DEE8 /* RCTMLNLayer.h */, + C4EAF17F1F6324A80016DEE8 /* RCTMLNLayer.m */, + C4EAF18D1F633E020016DEE8 /* RCTMLNFillLayer.h */, + C4EAF18E1F633E020016DEE8 /* RCTMLNFillLayer.m */, + C4EAF1901F6341520016DEE8 /* RCTMLNFillLayerManager.h */, + C4EAF1911F6341520016DEE8 /* RCTMLNFillLayerManager.m */, + C42236A51F6C7F4E00FA9C1C /* RCTMLNFillExtrusionLayer.h */, + C42236A61F6C7F4E00FA9C1C /* RCTMLNFillExtrusionLayer.m */, + C42236A81F6C7F6200FA9C1C /* RCTMLNFillExtrusionLayerManager.h */, + C42236A91F6C7F6200FA9C1C /* RCTMLNFillExtrusionLayerManager.m */, + C4FB10FC1F707A140055AE1F /* RCTMLNLineLayer.h */, + C4FB10FD1F707A140055AE1F /* RCTMLNLineLayer.m */, + C4FB10FF1F707A280055AE1F /* RCTMLNLineLayerManager.h */, + C4FB11001F707A280055AE1F /* RCTMLNLineLayerManager.m */, + C4FB11021F709CDC0055AE1F /* RCTMLNCircleLayer.h */, + C4FB11031F709CDC0055AE1F /* RCTMLNCircleLayer.m */, + C4FB11051F709CEF0055AE1F /* RCTMLNCircleLayerManager.h */, + C4FB11061F709CEF0055AE1F /* RCTMLNCircleLayerManager.m */, + C4FB110E1F71EC8D0055AE1F /* RCTMLNSymbolLayer.h */, + C4FB110F1F71EC8D0055AE1F /* RCTMLNSymbolLayer.m */, + C4FB11111F71EC9F0055AE1F /* RCTMLNSymbolLayerManager.h */, + C4FB11121F71EC9F0055AE1F /* RCTMLNSymbolLayerManager.m */, + C4FB12311F799F190055AE1F /* RCTMLNRasterLayer.h */, + C4FB12321F799F190055AE1F /* RCTMLNRasterLayer.m */, + C4FB12341F799F280055AE1F /* RCTMLNRasterLayerManager.h */, + C4FB12351F799F280055AE1F /* RCTMLNRasterLayerManager.m */, + C4FB12561F79C0270055AE1F /* RCTMLNBackgroundLayer.h */, + C4FB12571F79C0270055AE1F /* RCTMLNBackgroundLayer.m */, + C4FB12591F79C03E0055AE1F /* RCTMLNBackgroundLayerManager.h */, + C4FB125A1F79C03E0055AE1F /* RCTMLNBackgroundLayerManager.m */, + ); + name = Layers; + sourceTree = ""; + }; + D8C1903023F537D300223486 /* Images */ = { + isa = PBXGroup; + children = ( + D8C1903123F5382C00223486 /* RCTMLNImages.h */, + D8C1903223F5382C00223486 /* RCTMLNImages.m */, + D8C1903623F53B3C00223486 /* RCTMLNImagesManager.h */, + D8C1903423F53B0F00223486 /* RCTMLNImagesManager.m */, + ); + name = Images; + }; + DF3CFC0122CFCD8B00A83174 /* Location */ = { + isa = PBXGroup; + children = ( + DF3CFC0522CFCE0500A83174 /* RCTMLNNativeUserLocation.h */, + DF3CFC0222CFCE0500A83174 /* RCTMLNNativeUserLocation.m */, + DF3CFC0422CFCE0500A83174 /* RCTMLNNativeUserLocationManager.h */, + DF3CFC0322CFCE0500A83174 /* RCTMLNNativeUserLocationManager.m */, + ); + name = Location; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + C4D1443C1F4E16F600396F26 /* RCTMLN */ = { + isa = PBXNativeTarget; + buildConfigurationList = C4D144461F4E16F600396F26 /* Build configuration list for PBXNativeTarget "RCTMLN" */; + buildPhases = ( + C4D144391F4E16F600396F26 /* Sources */, + C4D1443A1F4E16F600396F26 /* Frameworks */, + C4D1443B1F4E16F600396F26 /* CopyFiles */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = RCTMLN; + productName = RCTMLN; + productReference = C4D1443D1F4E16F600396F26 /* libRCTMLN.a */; + productType = "com.apple.product-type.library.static"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + C4D144351F4E16F600396F26 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 0830; + ORGANIZATIONNAME = "Mapbox Inc"; + TargetAttributes = { + C4D1443C1F4E16F600396F26 = { + CreatedOnToolsVersion = 8.3.3; + ProvisioningStyle = Automatic; + }; + }; + }; + buildConfigurationList = C4D144381F4E16F600396F26 /* Build configuration list for PBXProject "RCTMLN" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + English, + en, + ); + mainGroup = C4D144341F4E16F600396F26; + productRefGroup = C4D1443E1F4E16F600396F26 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + C4D1443C1F4E16F600396F26 /* RCTMLN */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXSourcesBuildPhase section */ + C4D144391F4E16F600396F26 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + C470F6AC1FA11C9500614A69 /* MLNOfflineModule.m in Sources */, + DF3CFC0722CFCE0500A83174 /* RCTMLNNativeUserLocationManager.m in Sources */, + C4FB12581F79C0270055AE1F /* RCTMLNBackgroundLayer.m in Sources */, + C4EAF1801F6324A80016DEE8 /* RCTMLNLayer.m in Sources */, + C4C87B7E1F8FEC090064AE95 /* RCTMLNPointAnnotation.m in Sources */, + C4EAF1271F6083C70016DEE8 /* CameraUpdateItem.m in Sources */, + C470F5B81F9E79D400614A69 /* RCTMLNImageQueue.m in Sources */, + C45339CD204780EB00888553 /* RCTMLNImageQueueOperation.m in Sources */, + DF16042F233BFDD100A4231D /* RCTMLNTileSource.m in Sources */, + C4D144531F4E190C00396F26 /* MLNModule.m in Sources */, + C4C87B7B1F8FEBF50064AE95 /* RCTMLNPointAnnotationManager.m in Sources */, + C43CA50A1F50C145000B9CB7 /* RCTMLNEvent.m in Sources */, + C4EA22191F675ACE00EF2500 /* RCTMLNStyleValue.m in Sources */, + C4FB110A1F71D09E0055AE1F /* RCTMLNShapeSource.m in Sources */, + C4FB11101F71EC8D0055AE1F /* RCTMLNSymbolLayer.m in Sources */, + C4FB125B1F79C03E0055AE1F /* RCTMLNBackgroundLayerManager.m in Sources */, + C4EAF18F1F633E020016DEE8 /* RCTMLNFillLayer.m in Sources */, + C4C87B911F9142FB0064AE95 /* RCTMLNCallout.m in Sources */, + C42236AA1F6C7F6200FA9C1C /* RCTMLNFillExtrusionLayerManager.m in Sources */, + C4FB12331F799F190055AE1F /* RCTMLNRasterLayer.m in Sources */, + C4D1444C1F4E178100396F26 /* RCTMLNMapView.m in Sources */, + C410D5D51F7AD0B300CF822A /* RCTMLNLight.m in Sources */, + C490EE0520DC575100CB2E57 /* RCTMLNLocationManager.m in Sources */, + C42236A41F6B012000FA9C1C /* RCTMLNStyle.m in Sources */, + C4FD1DC21FCF550E00213AF2 /* RCTMLNImageSourceManager.m in Sources */, + C4D1444F1F4E181100396F26 /* RCTMLNMapViewManager.m in Sources */, + C4FB12361F799F280055AE1F /* RCTMLNRasterLayerManager.m in Sources */, + C4FB110D1F71D0B10055AE1F /* RCTMLNShapeSourceManager.m in Sources */, + C490EE0B20DC6B7C00CB2E57 /* RCTMLNLocation.m in Sources */, + D8C1903323F5382C00223486 /* RCTMLNImages.m in Sources */, + C4EAF1921F6341520016DEE8 /* RCTMLNFillLayerManager.m in Sources */, + C4D144971F4E2F1100396F26 /* RCTMLNUtils.m in Sources */, + C43CA50D1F53A4EF000B9CB7 /* RCTMLNEventTypes.m in Sources */, + C4EAF1201F5FC07E0016DEE8 /* CameraStop.m in Sources */, + C4FB11071F709CEF0055AE1F /* RCTMLNCircleLayerManager.m in Sources */, + C4EAF1241F606F7C0016DEE8 /* CameraMode.m in Sources */, + C4D144421F4E16F600396F26 /* RCTMLN.m in Sources */, + C42236A71F6C7F4E00FA9C1C /* RCTMLNFillExtrusionLayer.m in Sources */, + C490EE0E20DD70AD00CB2E57 /* RCTMLNCamera.m in Sources */, + C4FB11011F707A280055AE1F /* RCTMLNLineLayerManager.m in Sources */, + C43CA5061F507BCC000B9CB7 /* RCTMLNMapTouchEvent.m in Sources */, + C4FB12301F7972B40055AE1F /* RCTMLNRasterSourceManager.m in Sources */, + C416015020112B5200006116 /* RNMBImageUtils.m in Sources */, + C4FB10FE1F707A140055AE1F /* RCTMLNLineLayer.m in Sources */, + C4EAF1831F6336E20016DEE8 /* RCTMLNVectorSource.m in Sources */, + C4EAF1891F633C010016DEE8 /* RCTMLNVectorSourceManager.m in Sources */, + DF3CFC0622CFCE0500A83174 /* RCTMLNNativeUserLocation.m in Sources */, + C490EE1120DD710000CB2E57 /* RCTMLNCameraManager.m in Sources */, + 431CDACE229D61A6008BE92D /* RCTMLNUserLocation.m in Sources */, + C4FD1DC51FD1F04300213AF2 /* MLNSnapshotModule.m in Sources */, + C4FB122D1F7972A00055AE1F /* RCTMLNRasterSource.m in Sources */, + C4C87B941F9143DA0064AE95 /* RCTMLNCalloutManager.m in Sources */, + C410D5D81F7AD0C100CF822A /* RCTMLNLightManager.m in Sources */, + C4EAF17D1F6324970016DEE8 /* RCTMLNSource.m in Sources */, + C490EE0220DC565000CB2E57 /* RCTMLNLocationModule.m in Sources */, + C4FB11131F71EC9F0055AE1F /* RCTMLNSymbolLayerManager.m in Sources */, + D8C1903523F53B0F00223486 /* RCTMLNImagesManager.m in Sources */, + 641DE8A8231019E8003B792D /* MLNCustomHeaders.m in Sources */, + C4C87A601F844C820064AE95 /* FilterParser.m in Sources */, + C4FD1DBF1FCF54FB00213AF2 /* RCTMLNImageSource.m in Sources */, + C4EAF12A1F6084920016DEE8 /* CameraUpdateQueue.m in Sources */, + C4FB11041F709CDC0055AE1F /* RCTMLNCircleLayer.m in Sources */, + C435A5F71F587D9100824A30 /* ViewManager.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin XCBuildConfiguration section */ + C4D144441F4E16F600396F26 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + HEADER_SEARCH_PATHS = "$(SRCROOT)/../../../react-native/React"; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + }; + name = Debug; + }; + C4D144451F4E16F600396F26 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + HEADER_SEARCH_PATHS = "$(SRCROOT)/../../../react-native/React"; + IPHONEOS_DEPLOYMENT_TARGET = 8.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + C4D144471F4E16F600396F26 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + FRAMEWORK_SEARCH_PATHS = "$(SRCROOT)"; + HEADER_SEARCH_PATHS = "$(SRCROOT)/../../../react-native/React/**"; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Debug; + }; + C4D144481F4E16F600396F26 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + FRAMEWORK_SEARCH_PATHS = "$(SRCROOT)"; + HEADER_SEARCH_PATHS = "$(SRCROOT)/../../../react-native/React/**"; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + C4D144381F4E16F600396F26 /* Build configuration list for PBXProject "RCTMLN" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + C4D144441F4E16F600396F26 /* Debug */, + C4D144451F4E16F600396F26 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + C4D144461F4E16F600396F26 /* Build configuration list for PBXNativeTarget "RCTMLN" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + C4D144471F4E16F600396F26 /* Debug */, + C4D144481F4E16F600396F26 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = C4D144351F4E16F600396F26 /* Project object */; +} diff --git a/ios/RCTMGL/CameraMode.h b/ios/RCTMLN/CameraMode.h similarity index 97% rename from ios/RCTMGL/CameraMode.h rename to ios/RCTMLN/CameraMode.h index b46750698..f16b437d6 100644 --- a/ios/RCTMGL/CameraMode.h +++ b/ios/RCTMLN/CameraMode.h @@ -1,6 +1,6 @@ // // CameraMode.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/6/17. // Copyright © 2017 Mapbox Inc. All rights reserved. diff --git a/ios/RCTMGL/CameraMode.m b/ios/RCTMLN/CameraMode.m similarity index 97% rename from ios/RCTMGL/CameraMode.m rename to ios/RCTMLN/CameraMode.m index b27df6caf..f7317c3dd 100644 --- a/ios/RCTMGL/CameraMode.m +++ b/ios/RCTMLN/CameraMode.m @@ -1,6 +1,6 @@ // // CameraMode.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/6/17. // Copyright © 2017 Mapbox Inc. All rights reserved. diff --git a/ios/RCTMGL/CameraStop.h b/ios/RCTMLN/CameraStop.h similarity index 83% rename from ios/RCTMGL/CameraStop.h rename to ios/RCTMLN/CameraStop.h index 398643542..fa7105b3f 100644 --- a/ios/RCTMGL/CameraStop.h +++ b/ios/RCTMLN/CameraStop.h @@ -1,13 +1,13 @@ // // CameraStop.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/5/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -@import Mapbox; -#import "RCTMGLCamera.h" +@import MapLibre; +#import "RCTMLNCamera.h" @interface CameraStop : NSObject @@ -18,7 +18,7 @@ @property (nonatomic, assign) NSTimeInterval duration; @property (nonatomic, assign) CLLocationCoordinate2D coordinate; -@property (nonatomic, assign) MGLCoordinateBounds bounds; +@property (nonatomic, assign) MLNCoordinateBounds bounds; @property (nonatomic, assign) UIEdgeInsets padding; + (CameraStop*)fromDictionary:(NSDictionary*)args; diff --git a/ios/RCTMGL/CameraStop.m b/ios/RCTMLN/CameraStop.m similarity index 86% rename from ios/RCTMGL/CameraStop.m rename to ios/RCTMLN/CameraStop.m index 0aaf23c8d..eec659525 100644 --- a/ios/RCTMGL/CameraStop.m +++ b/ios/RCTMLN/CameraStop.m @@ -1,6 +1,6 @@ // // CameraStop.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/5/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,8 +8,8 @@ #import "CameraStop.h" #import "CameraMode.h" -#import "RCTMGLUtils.h" -#import "RCTMGLCamera.h" +#import "RCTMLNUtils.h" +#import "RCTMLNCamera.h" @implementation CameraStop @@ -31,7 +31,7 @@ - (void)setMode:(NSNumber *)mode -(id)init { if (self = [super init]) { self.coordinate = kCLLocationCoordinate2DInvalid; - self.bounds = MGLCoordinateBoundsMake(kCLLocationCoordinate2DInvalid, kCLLocationCoordinate2DInvalid); + self.bounds = MLNCoordinateBoundsMake(kCLLocationCoordinate2DInvalid, kCLLocationCoordinate2DInvalid); } return self; } @@ -50,7 +50,7 @@ + (CameraStop*)fromDictionary:(NSDictionary *)args } if (args[@"centerCoordinate"]) { - stop.coordinate = [RCTMGLUtils fromFeature:args[@"centerCoordinate"]]; + stop.coordinate = [RCTMLNUtils fromFeature:args[@"centerCoordinate"]]; } if (args[@"zoom"]) { @@ -62,7 +62,7 @@ + (CameraStop*)fromDictionary:(NSDictionary *)args } if (args[@"bounds"]) { - stop.bounds = [RCTMGLUtils fromFeatureCollection:args[@"bounds"]]; + stop.bounds = [RCTMLNUtils fromFeatureCollection:args[@"bounds"]]; } CGFloat paddingTop = args[@"paddingTop"] ? [args[@"paddingTop"] floatValue] : 0.0; @@ -73,7 +73,7 @@ + (CameraStop*)fromDictionary:(NSDictionary *)args NSTimeInterval duration = 2.0; if (args[@"duration"]) { - duration = [RCTMGLUtils fromMS:args[@"duration"]]; + duration = [RCTMLNUtils fromMS:args[@"duration"]]; } stop.duration = duration; diff --git a/ios/RCTMGL/CameraUpdateItem.h b/ios/RCTMLN/CameraUpdateItem.h similarity index 75% rename from ios/RCTMGL/CameraUpdateItem.h rename to ios/RCTMLN/CameraUpdateItem.h index f9be54388..b71f02587 100644 --- a/ios/RCTMGL/CameraUpdateItem.h +++ b/ios/RCTMLN/CameraUpdateItem.h @@ -1,18 +1,18 @@ // // CameraUpdateItem.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/6/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import "CameraStop.h" -#import "RCTMGLMapView.h" +#import "RCTMLNMapView.h" @interface CameraUpdateItem : NSObject @property (nonatomic, strong) CameraStop* _Nonnull cameraStop; -- (void)execute:(RCTMGLMapView* _Nonnull)mapView withCompletionHandler:(nullable void (^)(void))completionHandler; +- (void)execute:(RCTMLNMapView* _Nonnull)mapView withCompletionHandler:(nullable void (^)(void))completionHandler; @end diff --git a/ios/RCTMGL/CameraUpdateItem.m b/ios/RCTMLN/CameraUpdateItem.m similarity index 84% rename from ios/RCTMGL/CameraUpdateItem.m rename to ios/RCTMLN/CameraUpdateItem.m index 64018a59b..6e274142c 100644 --- a/ios/RCTMGL/CameraUpdateItem.m +++ b/ios/RCTMLN/CameraUpdateItem.m @@ -1,6 +1,6 @@ // // CameraUpdateItem.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/6/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -10,24 +10,24 @@ #import "CameraMode.h" -@interface MGLMapView(FlyToWithPadding) -- (void)_flyToCamera:(MGLMapCamera *)camera edgePadding:(UIEdgeInsets)insets withDuration:(NSTimeInterval)duration peakAltitude:(CLLocationDistance)peakAltitude completionHandler:(nullable void (^)(void))completion; +@interface MLNMapView(FlyToWithPadding) +- (void)_flyToCamera:(MLNMapCamera *)camera edgePadding:(UIEdgeInsets)insets withDuration:(NSTimeInterval)duration peakAltitude:(CLLocationDistance)peakAltitude completionHandler:(nullable void (^)(void))completion; @end -@interface RCTMGLCameraWithPadding : MGLMapCamera +@interface RCTMLNCameraWithPadding : MLNMapCamera -@property (nonatomic) MGLMapCamera* _Nonnull camera; +@property (nonatomic) MLNMapCamera* _Nonnull camera; @property (nonatomic) UIEdgeInsets boundsPadding; @end -@implementation RCTMGLCameraWithPadding +@implementation RCTMLNCameraWithPadding @end @implementation CameraUpdateItem -- (void)execute:(RCTMGLMapView *)mapView withCompletionHandler:(void (^)(void))completionHandler +- (void)execute:(RCTMLNMapView *)mapView withCompletionHandler:(void (^)(void))completionHandler { if (_cameraStop.mode == [NSNumber numberWithInt:RCT_MAPBOX_CAMERA_MODE_FLIGHT]) { [self _flyToCamera:mapView withCompletionHandler:completionHandler]; @@ -40,9 +40,9 @@ - (void)execute:(RCTMGLMapView *)mapView withCompletionHandler:(void (^)(void))c } } -- (void)_flyToCamera:(RCTMGLMapView*)mapView withCompletionHandler:(void (^)(void))completionHandler +- (void)_flyToCamera:(RCTMLNMapView*)mapView withCompletionHandler:(void (^)(void))completionHandler { - RCTMGLCameraWithPadding *nextCamera = [self _makeCamera:mapView]; + RCTMLNCameraWithPadding *nextCamera = [self _makeCamera:mapView]; if ([mapView respondsToSelector:@selector(_flyToCamera:edgePadding:withDuration:peakAltitude:completionHandler:)]) { [mapView @@ -59,9 +59,9 @@ - (void)_flyToCamera:(RCTMGLMapView*)mapView withCompletionHandler:(void (^)(voi } } -- (void)_moveCamera:(RCTMGLMapView*)mapView animated:(BOOL)animated ease:(BOOL)ease withCompletionHandler:(void (^)(void))completionHandler +- (void)_moveCamera:(RCTMLNMapView*)mapView animated:(BOOL)animated ease:(BOOL)ease withCompletionHandler:(void (^)(void))completionHandler { - RCTMGLCameraWithPadding *nextCamera = [self _makeCamera:mapView]; + RCTMLNCameraWithPadding *nextCamera = [self _makeCamera:mapView]; NSString *easeFunctionName = ease ? kCAMediaTimingFunctionEaseInEaseOut : kCAMediaTimingFunctionLinear; [mapView setCamera:nextCamera.camera @@ -71,9 +71,9 @@ - (void)_moveCamera:(RCTMGLMapView*)mapView animated:(BOOL)animated ease:(BOOL)e completionHandler:completionHandler]; } -- (RCTMGLCameraWithPadding*)_makeCamera:(RCTMGLMapView*)mapView +- (RCTMLNCameraWithPadding*)_makeCamera:(RCTMLNMapView*)mapView { - MGLMapCamera *nextCamera = [mapView.camera copy]; + MLNMapCamera *nextCamera = [mapView.camera copy]; UIEdgeInsets padding = [self _clippedPadding:_cameraStop.padding forView:mapView]; if (padding.top <= 0 && padding.bottom <= 0) { @@ -86,14 +86,14 @@ - (RCTMGLCameraWithPadding*)_makeCamera:(RCTMGLMapView*)mapView bool hasSetAltitude = false; if ([self _isCoordValid:_cameraStop.coordinate]) { - MGLCoordinateBounds boundsFromCoord = { .sw = _cameraStop.coordinate, .ne = _cameraStop.coordinate }; - MGLMapCamera *boundsCamera = [mapView + MLNCoordinateBounds boundsFromCoord = { .sw = _cameraStop.coordinate, .ne = _cameraStop.coordinate }; + MLNMapCamera *boundsCamera = [mapView camera:nextCamera fittingCoordinateBounds:boundsFromCoord edgePadding: padding]; nextCamera.centerCoordinate = boundsCamera.centerCoordinate; } else if ([self _areBoundsValid:_cameraStop.bounds]) { - MGLMapCamera *boundsCamera = [mapView + MLNMapCamera *boundsCamera = [mapView camera:nextCamera fittingCoordinateBounds:_cameraStop.bounds edgePadding: padding]; @@ -117,13 +117,13 @@ - (RCTMGLCameraWithPadding*)_makeCamera:(RCTMGLMapView*)mapView atPitch:nextCamera.pitch]; } - RCTMGLCameraWithPadding* cameraWithPadding = [[RCTMGLCameraWithPadding alloc] init]; + RCTMLNCameraWithPadding* cameraWithPadding = [[RCTMLNCameraWithPadding alloc] init]; cameraWithPadding.camera = nextCamera; cameraWithPadding.boundsPadding = padding; return cameraWithPadding; } -- (UIEdgeInsets)_clippedPadding:(UIEdgeInsets)padding forView:(RCTMGLMapView*)mapView +- (UIEdgeInsets)_clippedPadding:(UIEdgeInsets)padding forView:(RCTMLNMapView*)mapView { UIEdgeInsets result = padding; if ((padding.top + padding.bottom) >= mapView.frame.size.height) { @@ -141,7 +141,7 @@ - (UIEdgeInsets)_clippedPadding:(UIEdgeInsets)padding forView:(RCTMGLMapView*)ma return result; } -- (BOOL)_areBoundsValid:(MGLCoordinateBounds)bounds { +- (BOOL)_areBoundsValid:(MLNCoordinateBounds)bounds { BOOL isValid = CLLocationCoordinate2DIsValid(bounds.ne) && CLLocationCoordinate2DIsValid(bounds.sw); if (!isValid) { diff --git a/ios/RCTMGL/CameraUpdateQueue.h b/ios/RCTMLN/CameraUpdateQueue.h similarity index 80% rename from ios/RCTMGL/CameraUpdateQueue.h rename to ios/RCTMLN/CameraUpdateQueue.h index 45332bac6..e4c322cb7 100644 --- a/ios/RCTMGL/CameraUpdateQueue.h +++ b/ios/RCTMLN/CameraUpdateQueue.h @@ -1,6 +1,6 @@ // // CameraUpdateQueue.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/6/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,7 +8,7 @@ #import "CameraStop.h" #import "CameraUpdateItem.h" -#import "RCTMGLMapView.h" +#import "RCTMLNMapView.h" @interface CameraUpdateQueue : NSObject @@ -16,6 +16,6 @@ - (CameraStop* _Nonnull)dequeue; - (void)flush; - (BOOL)isEmpty; -- (void)execute:(RCTMGLMapView* _Nonnull)mapView; +- (void)execute:(RCTMLNMapView* _Nonnull)mapView; @end diff --git a/ios/RCTMGL/CameraUpdateQueue.m b/ios/RCTMLN/CameraUpdateQueue.m similarity index 92% rename from ios/RCTMGL/CameraUpdateQueue.m rename to ios/RCTMLN/CameraUpdateQueue.m index 35c4d43a5..b120ab231 100644 --- a/ios/RCTMGL/CameraUpdateQueue.m +++ b/ios/RCTMLN/CameraUpdateQueue.m @@ -1,6 +1,6 @@ // // CameraUpdateQueue.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/6/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -47,7 +47,7 @@ - (BOOL)isEmpty return queue.count == 0; } -- (void)execute:(RCTMGLMapView*)mapView +- (void)execute:(RCTMLNMapView*)mapView { if (mapView == nil) { return; @@ -66,7 +66,7 @@ - (void)execute:(RCTMGLMapView*)mapView item.cameraStop = stop; __weak CameraUpdateQueue *weakSelf = self; - __weak RCTMGLMapView *weakMap = mapView; + __weak RCTMLNMapView *weakMap = mapView; [item execute:mapView withCompletionHandler:^{ [weakSelf execute:weakMap]; }]; } diff --git a/ios/RCTMGL/FilterParser.h b/ios/RCTMLN/FilterParser.h similarity index 95% rename from ios/RCTMGL/FilterParser.h rename to ios/RCTMLN/FilterParser.h index 74e8920fa..b0fc66f02 100644 --- a/ios/RCTMGL/FilterParser.h +++ b/ios/RCTMLN/FilterParser.h @@ -1,6 +1,6 @@ // // FilterParser.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 10/3/17. // Copyright © 2017 Mapbox Inc. All rights reserved. diff --git a/ios/RCTMGL/FilterParser.m b/ios/RCTMLN/FilterParser.m similarity index 74% rename from ios/RCTMGL/FilterParser.m rename to ios/RCTMLN/FilterParser.m index f2d9a1c05..4c91525c6 100644 --- a/ios/RCTMGL/FilterParser.m +++ b/ios/RCTMLN/FilterParser.m @@ -1,13 +1,13 @@ // // FilterParser.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 10/3/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import "FilterParser.h" -#import +#import @implementation FilterParser @@ -16,7 +16,7 @@ + (NSPredicate*)parse:(NSArray *)filterList if (filterList == nil || filterList.count < 1) { return nil; } - return [NSPredicate predicateWithMGLJSONObject:filterList]; + return [NSPredicate predicateWithMLNJSONObject:filterList]; } @end diff --git a/ios/RCTMGL/MGLCustomHeaders.h b/ios/RCTMLN/MLNCustomHeaders.h similarity index 82% rename from ios/RCTMGL/MGLCustomHeaders.h rename to ios/RCTMLN/MLNCustomHeaders.h index 0dabbd3f2..8fd40bcb6 100644 --- a/ios/RCTMGL/MGLCustomHeaders.h +++ b/ios/RCTMLN/MLNCustomHeaders.h @@ -1,6 +1,6 @@ // -// MGLCustomHeaders.h -// RCTMGL +// MLNCustomHeaders.h +// RCTMLN // #import @@ -8,7 +8,7 @@ @interface NSMutableURLRequest (CustomHeaders) @end -@interface MGLCustomHeaders : NSObject +@interface MLNCustomHeaders : NSObject @property (nonatomic, strong) NSMutableDictionary *currentHeaders; diff --git a/ios/RCTMGL/MGLCustomHeaders.m b/ios/RCTMLN/MLNCustomHeaders.m similarity index 86% rename from ios/RCTMGL/MGLCustomHeaders.m rename to ios/RCTMLN/MLNCustomHeaders.m index a7f6e2734..386412806 100644 --- a/ios/RCTMGL/MGLCustomHeaders.m +++ b/ios/RCTMLN/MLNCustomHeaders.m @@ -1,13 +1,13 @@ // -// MGLCustomHeaders.h -// RCTMGL +// MLNCustomHeaders.h +// RCTMLN // #import -#import "MGLCustomHeaders.h" -#import -#import +#import "MLNCustomHeaders.h" +#import +#import @implementation NSMutableURLRequest (CustomHeaders) @@ -26,7 +26,7 @@ +(NSMutableURLRequest*) __swizzle_requestWithURL:(NSURL*)url { } NSMutableURLRequest *req = [NSMutableURLRequest __swizzle_requestWithURL:url]; - NSDictionary *currentHeaders = [[[MGLCustomHeaders sharedInstance] currentHeaders] copy]; + NSDictionary *currentHeaders = [[[MLNCustomHeaders sharedInstance] currentHeaders] copy]; if(currentHeaders != nil && [currentHeaders count]>0) { for (NSString* headerName in currentHeaders) { id headerValue = currentHeaders[headerName]; @@ -38,21 +38,21 @@ +(NSMutableURLRequest*) __swizzle_requestWithURL:(NSURL*)url { @end -@implementation MGLCustomHeaders { +@implementation MLNCustomHeaders { NSMutableDictionary *_currentHeaders; BOOL areHeadersAdded; } + (id)sharedInstance { - static MGLCustomHeaders *customHeaders; + static MLNCustomHeaders *customHeaders; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ customHeaders = [[self alloc] init]; }); return customHeaders; } // This replaces the [NSMutableURLRequest requestWithURL:] with custom implementation which -// adds runtime headers copied from [MGLCustomHeaders _currentHeaders] +// adds runtime headers copied from [MLNCustomHeaders _currentHeaders] -(void)initHeaders { if (!areHeadersAdded) { @@ -84,7 +84,7 @@ - (void)addHeader:(NSString *)value forHeaderName:(NSString *)headerName { } [_currentHeaders setObject:value forKey:headerName]; - [[[MGLNetworkConfiguration sharedManager] sessionConfiguration] setHTTPAdditionalHeaders:_currentHeaders]; + [[[MLNNetworkConfiguration sharedManager] sessionConfiguration] setHTTPAdditionalHeaders:_currentHeaders]; } - (void)removeHeader:(NSString *)header { diff --git a/ios/RCTMLN/MLNFaux3DUserLocationAnnotationView.h b/ios/RCTMLN/MLNFaux3DUserLocationAnnotationView.h new file mode 100644 index 000000000..eeb39d446 --- /dev/null +++ b/ios/RCTMLN/MLNFaux3DUserLocationAnnotationView.h @@ -0,0 +1,23 @@ +// +// MLNFaux3DUserLocationAnnotationView.h +// RCTMLN +// +// Created by Nick Italiano on 12/20/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import +@import MapLibre; + +extern const CGFloat MLNUserLocationAnnotationDotSize; +extern const CGFloat MLNUserLocationAnnotationHaloSize; + +extern const CGFloat MLNUserLocationAnnotationPuckSize; +extern const CGFloat MLNUserLocationAnnotationArrowSize; + +// Threshold in radians between heading indicator rotation updates. +extern const CGFloat MLNUserLocationHeadingUpdateThreshold; + +@interface MLNFaux3DUserLocationAnnotationView : MLNUserLocationAnnotationView + +@end diff --git a/ios/RCTMGL/MGLFaux3DUserLocationAnnotationView.m b/ios/RCTMLN/MLNFaux3DUserLocationAnnotationView.m similarity index 85% rename from ios/RCTMGL/MGLFaux3DUserLocationAnnotationView.m rename to ios/RCTMLN/MLNFaux3DUserLocationAnnotationView.m index ea6a331ae..4af66d54c 100644 --- a/ios/RCTMGL/MGLFaux3DUserLocationAnnotationView.m +++ b/ios/RCTMLN/MLNFaux3DUserLocationAnnotationView.m @@ -1,31 +1,31 @@ // -// https://github.com/mapbox/mapbox-gl-native/blob/master/platform/ios/src/MGLFaux3DUserLocationAnnotationView.m +// https://github.com/mapbox/mapbox-gl-native/blob/master/platform/ios/src/MLNFaux3DUserLocationAnnotationView.m // -#import "MGLFaux3DUserLocationAnnotationView.h" +#import "MLNFaux3DUserLocationAnnotationView.h" -#import "MGLUserLocationHeadingIndicator.h" -#import "MGLUserLocationHeadingArrowLayer.h" -#import "MGLUserLocationHeadingBeamLayer.h" +#import "MLNUserLocationHeadingIndicator.h" +#import "MLNUserLocationHeadingArrowLayer.h" +#import "MLNUserLocationHeadingBeamLayer.h" -#import "RCTMGLMapView.h" +#import "RCTMLNMapView.h" -const CGFloat MGLUserLocationAnnotationDotSize = 22.0; -const CGFloat MGLUserLocationAnnotationHaloSize = 115.0; +const CGFloat MLNUserLocationAnnotationDotSize = 22.0; +const CGFloat MLNUserLocationAnnotationHaloSize = 115.0; -const CGFloat MGLUserLocationAnnotationPuckSize = 45.0; -const CGFloat MGLUserLocationAnnotationArrowSize = MGLUserLocationAnnotationPuckSize * 0.5; +const CGFloat MLNUserLocationAnnotationPuckSize = 45.0; +const CGFloat MLNUserLocationAnnotationArrowSize = MLNUserLocationAnnotationPuckSize * 0.5; -const CGFloat MGLUserLocationHeadingUpdateThreshold = 0.01; +const CGFloat MLNUserLocationHeadingUpdateThreshold = 0.01; -@implementation MGLFaux3DUserLocationAnnotationView +@implementation MLNFaux3DUserLocationAnnotationView { BOOL _puckModeActivated; CALayer *_puckDot; CAShapeLayer *_puckArrow; - CALayer *_headingIndicatorLayer; + CALayer *_headingIndicatorLayer; CALayer *_accuracyRingLayer; CALayer *_dotBorderLayer; CALayer *_dotLayer; @@ -47,15 +47,15 @@ - (void)update { if (CGSizeEqualToSize(self.frame.size, CGSizeZero)) { - CGFloat frameSize = (self.mapView.userTrackingMode == MGLUserTrackingModeFollowWithCourse) ? MGLUserLocationAnnotationPuckSize : MGLUserLocationAnnotationDotSize; + CGFloat frameSize = (self.mapView.userTrackingMode == MLNUserTrackingModeFollowWithCourse) ? MLNUserLocationAnnotationPuckSize : MLNUserLocationAnnotationDotSize; [self updateFrameWithSize:frameSize]; } if (CLLocationCoordinate2DIsValid(self.userLocation.coordinate)) { - RCTMGLMapView *reactMapView = (RCTMGLMapView *)self.mapView; + RCTMLNMapView *reactMapView = (RCTMLNMapView *)self.mapView; // FM - TODO - (reactMapView.userTrackingMode == MGLUserTrackingModeFollowWithCourse) ? [self drawPuck] : [self drawDot]; + (reactMapView.userTrackingMode == MLNUserTrackingModeFollowWithCourse) ? [self drawPuck] : [self drawDot]; [self updatePitch]; } @@ -87,7 +87,7 @@ - (void)updatePitch [CATransaction begin]; [CATransaction setDisableActions:YES]; - CATransform3D t = CATransform3DRotate(CATransform3DIdentity, MGLRadiansFromDegrees(self.mapView.camera.pitch), 1.0, 0, 0); + CATransform3D t = CATransform3DRotate(CATransform3DIdentity, MLNRadiansFromDegrees(self.mapView.camera.pitch), 1.0, 0, 0); self.layer.sublayerTransform = t; [self updateFaux3DEffect]; @@ -100,7 +100,7 @@ - (void)updatePitch - (void)updateFaux3DEffect { - CGFloat pitch = MGLRadiansFromDegrees(self.mapView.camera.pitch); + CGFloat pitch = MLNRadiansFromDegrees(self.mapView.camera.pitch); if (_puckDot) { @@ -148,14 +148,14 @@ - (void)drawPuck _dotBorderLayer = nil; _dotLayer = nil; - [self updateFrameWithSize:MGLUserLocationAnnotationPuckSize]; + [self updateFrameWithSize:MLNUserLocationAnnotationPuckSize]; } // background dot (white with black shadow) // if ( ! _puckDot) { - _puckDot = [self circleLayerWithSize:MGLUserLocationAnnotationPuckSize]; + _puckDot = [self circleLayerWithSize:MLNUserLocationAnnotationPuckSize]; _puckDot.backgroundColor = [[UIColor whiteColor] CGColor]; _puckDot.shadowColor = [[UIColor blackColor] CGColor]; _puckDot.shadowOpacity = 0.25; @@ -181,7 +181,7 @@ - (void)drawPuck _puckArrow = [CAShapeLayer layer]; _puckArrow.path = [[self puckArrow] CGPath]; _puckArrow.fillColor = [self.mapView.tintColor CGColor]; - _puckArrow.bounds = CGRectMake(0, 0, round(MGLUserLocationAnnotationArrowSize), round(MGLUserLocationAnnotationArrowSize)); + _puckArrow.bounds = CGRectMake(0, 0, round(MLNUserLocationAnnotationArrowSize), round(MLNUserLocationAnnotationArrowSize)); _puckArrow.position = CGPointMake(CGRectGetMidX(super.bounds), CGRectGetMidY(super.bounds)); _puckArrow.shouldRasterize = YES; _puckArrow.rasterizationScale = [UIScreen mainScreen].scale; @@ -195,7 +195,7 @@ - (void)drawPuck } if (self.userLocation.location.course >= 0) { - _puckArrow.affineTransform = CGAffineTransformRotate(CGAffineTransformIdentity, -MGLRadiansFromDegrees(self.mapView.direction - self.userLocation.location.course)); + _puckArrow.affineTransform = CGAffineTransformRotate(CGAffineTransformIdentity, -MLNRadiansFromDegrees(self.mapView.direction - self.userLocation.location.course)); } if ( ! _puckModeActivated) @@ -208,7 +208,7 @@ - (void)drawPuck - (UIBezierPath *)puckArrow { - CGFloat max = MGLUserLocationAnnotationArrowSize; + CGFloat max = MLNUserLocationAnnotationArrowSize; UIBezierPath *bezierPath = UIBezierPath.bezierPath; [bezierPath moveToPoint: CGPointMake(max * 0.5, 0)]; @@ -230,12 +230,12 @@ - (void)drawDot _puckDot = nil; _puckArrow = nil; - [self updateFrameWithSize:MGLUserLocationAnnotationDotSize]; + [self updateFrameWithSize:MLNUserLocationAnnotationDotSize]; } // heading indicator (tinted, beam or arrow) - RCTMGLMapView *reactMapView = (RCTMGLMapView *)self.mapView; - BOOL headingTrackingModeEnabled = reactMapView.userTrackingMode == MGLUserTrackingModeFollowWithHeading; + RCTMLNMapView *reactMapView = (RCTMLNMapView *)self.mapView; + BOOL headingTrackingModeEnabled = reactMapView.userTrackingMode == MLNUserTrackingModeFollowWithHeading; BOOL showHeadingIndicator = self.mapView.showsUserHeadingIndicator || headingTrackingModeEnabled; if (showHeadingIndicator) @@ -243,8 +243,8 @@ - (void)drawDot _headingIndicatorLayer.hidden = NO; CLLocationDirection headingAccuracy = self.userLocation.heading.headingAccuracy; - if (([_headingIndicatorLayer isMemberOfClass:[MGLUserLocationHeadingBeamLayer class]] && ! headingTrackingModeEnabled) || - ([_headingIndicatorLayer isMemberOfClass:[MGLUserLocationHeadingArrowLayer class]] && headingTrackingModeEnabled)) + if (([_headingIndicatorLayer isMemberOfClass:[MLNUserLocationHeadingBeamLayer class]] && ! headingTrackingModeEnabled) || + ([_headingIndicatorLayer isMemberOfClass:[MLNUserLocationHeadingArrowLayer class]] && headingTrackingModeEnabled)) { [_headingIndicatorLayer removeFromSuperlayer]; _headingIndicatorLayer = nil; @@ -255,12 +255,12 @@ - (void)drawDot { if (headingTrackingModeEnabled) { - _headingIndicatorLayer = [[MGLUserLocationHeadingBeamLayer alloc] initWithUserLocationAnnotationView:self]; + _headingIndicatorLayer = [[MLNUserLocationHeadingBeamLayer alloc] initWithUserLocationAnnotationView:self]; [self.layer insertSublayer:_headingIndicatorLayer below:_dotBorderLayer]; } else { - _headingIndicatorLayer = [[MGLUserLocationHeadingArrowLayer alloc] initWithUserLocationAnnotationView:self]; + _headingIndicatorLayer = [[MLNUserLocationHeadingArrowLayer alloc] initWithUserLocationAnnotationView:self]; [self.layer addSublayer:_headingIndicatorLayer]; _headingIndicatorLayer.zPosition = 1; } @@ -274,10 +274,10 @@ - (void)drawDot if (self.userLocation.heading.trueHeading >= 0) { - CGFloat rotation = -MGLRadiansFromDegrees(self.mapView.direction - self.userLocation.heading.trueHeading); + CGFloat rotation = -MLNRadiansFromDegrees(self.mapView.direction - self.userLocation.heading.trueHeading); // Don't rotate if the change is imperceptible. - if (fabs(rotation) > MGLUserLocationHeadingUpdateThreshold) + if (fabs(rotation) > MLNUserLocationHeadingUpdateThreshold) { [CATransaction begin]; [CATransaction setDisableActions:YES]; @@ -301,7 +301,7 @@ - (void)drawDot CGFloat accuracyRingSize = [self calculateAccuracyRingSize]; // only show the accuracy ring if it won't be obscured by the location dot - if (accuracyRingSize > MGLUserLocationAnnotationDotSize + 15) + if (accuracyRingSize > MLNUserLocationAnnotationDotSize + 15) { _accuracyRingLayer.hidden = NO; @@ -325,8 +325,8 @@ - (void)drawDot { _accuracyRingLayer.hidden = YES; - _haloLayer.bounds = CGRectMake(0, 0, MGLUserLocationAnnotationHaloSize, MGLUserLocationAnnotationHaloSize); - _haloLayer.cornerRadius = MGLUserLocationAnnotationHaloSize / 2.0; + _haloLayer.bounds = CGRectMake(0, 0, MLNUserLocationAnnotationHaloSize, MLNUserLocationAnnotationHaloSize); + _haloLayer.cornerRadius = MLNUserLocationAnnotationHaloSize / 2.0; _haloLayer.shouldRasterize = YES; _haloLayer.rasterizationScale = [UIScreen mainScreen].scale; } @@ -354,7 +354,7 @@ - (void)drawDot // if ( ! _haloLayer) { - _haloLayer = [self circleLayerWithSize:MGLUserLocationAnnotationHaloSize]; + _haloLayer = [self circleLayerWithSize:MLNUserLocationAnnotationHaloSize]; _haloLayer.backgroundColor = [self.mapView.tintColor CGColor]; _haloLayer.allowsGroupOpacity = NO; _haloLayer.zPosition = -0.1f; @@ -383,7 +383,7 @@ - (void)drawDot // if ( ! _dotBorderLayer) { - _dotBorderLayer = [self circleLayerWithSize:MGLUserLocationAnnotationDotSize]; + _dotBorderLayer = [self circleLayerWithSize:MLNUserLocationAnnotationDotSize]; _dotBorderLayer.backgroundColor = [[UIColor whiteColor] CGColor]; _dotBorderLayer.shadowColor = [[UIColor blackColor] CGColor]; _dotBorderLayer.shadowOpacity = 0.25; @@ -406,7 +406,7 @@ - (void)drawDot // if ( ! _dotLayer) { - _dotLayer = [self circleLayerWithSize:MGLUserLocationAnnotationDotSize * 0.75]; + _dotLayer = [self circleLayerWithSize:MLNUserLocationAnnotationDotSize * 0.75]; _dotLayer.backgroundColor = [self.mapView.tintColor CGColor]; // set defaults for the animations diff --git a/ios/RCTMGL/MGLModule.h b/ios/RCTMLN/MLNModule.h similarity index 70% rename from ios/RCTMGL/MGLModule.h rename to ios/RCTMLN/MLNModule.h index 902d48835..419f0096e 100644 --- a/ios/RCTMGL/MGLModule.h +++ b/ios/RCTMLN/MLNModule.h @@ -1,6 +1,6 @@ // -// MGLModule.h -// RCTMGL +// MLNModule.h +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -9,5 +9,5 @@ #import #import -@interface MGLModule : NSObject +@interface MLNModule : NSObject @end diff --git a/ios/RCTMGL/MGLModule.m b/ios/RCTMLN/MLNModule.m similarity index 61% rename from ios/RCTMGL/MGLModule.m rename to ios/RCTMLN/MLNModule.m index b44a35b24..d80b3b563 100644 --- a/ios/RCTMGL/MGLModule.m +++ b/ios/RCTMLN/MLNModule.m @@ -1,20 +1,20 @@ // -// MGLModule.m -// RCTMGL +// MLNModule.m +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "MGLModule.h" -#import "RCTMGLEventTypes.h" -#import "MGLOfflineModule.h" +#import "MLNModule.h" +#import "RCTMLNEventTypes.h" +#import "MLNOfflineModule.h" #import "CameraMode.h" -#import "RCTMGLSource.h" -#import "MGLCustomHeaders.h" -@import Mapbox; +#import "RCTMLNSource.h" +#import "MLNCustomHeaders.h" +@import MapLibre; -@implementation MGLModule +@implementation MLNModule RCT_EXPORT_MODULE(); @@ -28,10 +28,10 @@ + (BOOL)requiresMainQueueSetup // style urls NSMutableDictionary *styleURLS = [[NSMutableDictionary alloc] init]; - for (MGLDefaultStyle* style in [MGLStyle predefinedStyles]) { + for (MLNDefaultStyle* style in [MLNStyle predefinedStyles]) { [styleURLS setObject:[style.url absoluteString] forKey:style.name]; } - [styleURLS setObject:[[MGLStyle defaultStyleURL] absoluteString] forKey:@"Default"]; + [styleURLS setObject:[[MLNStyle defaultStyleURL] absoluteString] forKey:@"Default"]; // event types NSMutableDictionary *eventTypes = [[NSMutableDictionary alloc] init]; @@ -57,16 +57,16 @@ + (BOOL)requiresMainQueueSetup // user tracking modes NSMutableDictionary *userTrackingModes = [[NSMutableDictionary alloc] init]; - [userTrackingModes setObject:[NSNumber numberWithInt:MGLUserTrackingModeNone] forKey:@"None"]; - [userTrackingModes setObject:[NSNumber numberWithInt:MGLUserTrackingModeFollow] forKey:@"Follow"]; - [userTrackingModes setObject:[NSNumber numberWithInt:MGLUserTrackingModeFollowWithHeading] forKey:@"FollowWithHeading"]; - [userTrackingModes setObject:[NSNumber numberWithInt:MGLUserTrackingModeFollowWithCourse] forKey:@"FollowWithCourse"]; + [userTrackingModes setObject:[NSNumber numberWithInt:MLNUserTrackingModeNone] forKey:@"None"]; + [userTrackingModes setObject:[NSNumber numberWithInt:MLNUserTrackingModeFollow] forKey:@"Follow"]; + [userTrackingModes setObject:[NSNumber numberWithInt:MLNUserTrackingModeFollowWithHeading] forKey:@"FollowWithHeading"]; + [userTrackingModes setObject:[NSNumber numberWithInt:MLNUserTrackingModeFollowWithCourse] forKey:@"FollowWithCourse"]; // user location vertical alignment NSMutableDictionary *userLocationVerticalAlignment = [[NSMutableDictionary alloc] init]; - [userLocationVerticalAlignment setObject:[NSNumber numberWithInt:MGLAnnotationVerticalAlignmentTop] forKey:@"Top"]; - [userLocationVerticalAlignment setObject:[NSNumber numberWithInt:MGLAnnotationVerticalAlignmentCenter] forKey:@"Center"]; - [userLocationVerticalAlignment setObject:[NSNumber numberWithInt:MGLAnnotationVerticalAlignmentBottom] forKey:@"Bottom"]; + [userLocationVerticalAlignment setObject:[NSNumber numberWithInt:MLNAnnotationVerticalAlignmentTop] forKey:@"Top"]; + [userLocationVerticalAlignment setObject:[NSNumber numberWithInt:MLNAnnotationVerticalAlignmentCenter] forKey:@"Center"]; + [userLocationVerticalAlignment setObject:[NSNumber numberWithInt:MLNAnnotationVerticalAlignmentBottom] forKey:@"Bottom"]; // camera modes NSMutableDictionary *cameraModes = [[NSMutableDictionary alloc] init]; @@ -81,117 +81,117 @@ + (BOOL)requiresMainQueueSetup // line layer constants NSMutableDictionary *lineJoin = [[NSMutableDictionary alloc] init]; - [lineJoin setObject:@(MGLLineJoinBevel) forKey:@"Bevel"]; - [lineJoin setObject:@(MGLLineJoinRound) forKey:@"Round"]; - [lineJoin setObject:@(MGLLineJoinMiter) forKey:@"Miter"]; + [lineJoin setObject:@(MLNLineJoinBevel) forKey:@"Bevel"]; + [lineJoin setObject:@(MLNLineJoinRound) forKey:@"Round"]; + [lineJoin setObject:@(MLNLineJoinMiter) forKey:@"Miter"]; NSMutableDictionary *lineCap = [[NSMutableDictionary alloc] init]; - [lineCap setObject:@(MGLLineCapButt) forKey:@"Butt"]; - [lineCap setObject:@(MGLLineCapRound) forKey:@"Round"]; - [lineCap setObject:@(MGLLineCapSquare) forKey:@"Square"]; + [lineCap setObject:@(MLNLineCapButt) forKey:@"Butt"]; + [lineCap setObject:@(MLNLineCapRound) forKey:@"Round"]; + [lineCap setObject:@(MLNLineCapSquare) forKey:@"Square"]; NSMutableDictionary *lineTranslateAnchor = [[NSMutableDictionary alloc] init]; - [lineTranslateAnchor setObject:@(MGLLineTranslationAnchorMap) forKey:@"Map"]; - [lineTranslateAnchor setObject:@(MGLLineTranslationAnchorViewport) forKey:@"Viewport"]; + [lineTranslateAnchor setObject:@(MLNLineTranslationAnchorMap) forKey:@"Map"]; + [lineTranslateAnchor setObject:@(MLNLineTranslationAnchorViewport) forKey:@"Viewport"]; // circle layer constants NSMutableDictionary *circlePitchScale = [[NSMutableDictionary alloc] init]; - [circlePitchScale setObject:@(MGLCircleScaleAlignmentMap) forKey:@"Map"]; - [circlePitchScale setObject:@(MGLCircleScaleAlignmentViewport) forKey:@"Viewport"]; + [circlePitchScale setObject:@(MLNCircleScaleAlignmentMap) forKey:@"Map"]; + [circlePitchScale setObject:@(MLNCircleScaleAlignmentViewport) forKey:@"Viewport"]; NSMutableDictionary *circlePitchAlignment = [[NSMutableDictionary alloc] init]; - [circlePitchAlignment setObject:@(MGLCirclePitchAlignmentMap) forKey:@"Map"]; - [circlePitchAlignment setObject:@(MGLCirclePitchAlignmentViewport) forKey:@"Viewport"]; + [circlePitchAlignment setObject:@(MLNCirclePitchAlignmentMap) forKey:@"Map"]; + [circlePitchAlignment setObject:@(MLNCirclePitchAlignmentViewport) forKey:@"Viewport"]; NSMutableDictionary *circleTranslateAnchor = [[NSMutableDictionary alloc] init]; - [circleTranslateAnchor setObject:@(MGLCircleTranslationAnchorMap) forKey:@"Map"]; - [circleTranslateAnchor setObject:@(MGLCircleTranslationAnchorViewport) forKey:@"Viewport"]; + [circleTranslateAnchor setObject:@(MLNCircleTranslationAnchorMap) forKey:@"Map"]; + [circleTranslateAnchor setObject:@(MLNCircleTranslationAnchorViewport) forKey:@"Viewport"]; // fill extrusion layer constants NSMutableDictionary *fillExtrusionTranslateAnchor = [[NSMutableDictionary alloc] init]; - [fillExtrusionTranslateAnchor setObject:@(MGLFillExtrusionTranslationAnchorMap) forKey:@"Map"]; - [fillExtrusionTranslateAnchor setObject:@(MGLFillExtrusionTranslationAnchorViewport) forKey:@"Viewport"]; + [fillExtrusionTranslateAnchor setObject:@(MLNFillExtrusionTranslationAnchorMap) forKey:@"Map"]; + [fillExtrusionTranslateAnchor setObject:@(MLNFillExtrusionTranslationAnchorViewport) forKey:@"Viewport"]; // fill layer constants NSMutableDictionary *fillTranslateAnchor = [[NSMutableDictionary alloc] init]; - [fillTranslateAnchor setObject:@(MGLFillTranslationAnchorMap) forKey:@"Map"]; - [fillTranslateAnchor setObject:@(MGLFillTranslationAnchorViewport) forKey:@"Viewport"]; + [fillTranslateAnchor setObject:@(MLNFillTranslationAnchorMap) forKey:@"Map"]; + [fillTranslateAnchor setObject:@(MLNFillTranslationAnchorViewport) forKey:@"Viewport"]; // symbol layer constants NSMutableDictionary *iconRotationAlignment = [[NSMutableDictionary alloc] init]; - [iconRotationAlignment setObject:@(MGLIconRotationAlignmentAuto) forKey:@"Auto"]; - [iconRotationAlignment setObject:@(MGLIconRotationAlignmentMap) forKey:@"Map"]; - [iconRotationAlignment setObject:@(MGLIconRotationAlignmentViewport) forKey:@"Viewport"]; + [iconRotationAlignment setObject:@(MLNIconRotationAlignmentAuto) forKey:@"Auto"]; + [iconRotationAlignment setObject:@(MLNIconRotationAlignmentMap) forKey:@"Map"]; + [iconRotationAlignment setObject:@(MLNIconRotationAlignmentViewport) forKey:@"Viewport"]; NSMutableDictionary *iconTextFit = [[NSMutableDictionary alloc] init]; - [iconTextFit setObject:@(MGLIconTextFitNone) forKey:@"None"]; - [iconTextFit setObject:@(MGLIconTextFitWidth) forKey:@"Width"]; - [iconTextFit setObject:@(MGLIconTextFitHeight) forKey:@"Height"]; - [iconTextFit setObject:@(MGLIconTextFitBoth) forKey:@"Both"]; + [iconTextFit setObject:@(MLNIconTextFitNone) forKey:@"None"]; + [iconTextFit setObject:@(MLNIconTextFitWidth) forKey:@"Width"]; + [iconTextFit setObject:@(MLNIconTextFitHeight) forKey:@"Height"]; + [iconTextFit setObject:@(MLNIconTextFitBoth) forKey:@"Both"]; NSMutableDictionary *iconAnchor = [[NSMutableDictionary alloc] init]; - [iconAnchor setObject:@(MGLIconAnchorCenter) forKey:@"Center"]; - [iconAnchor setObject:@(MGLIconAnchorTop) forKey:@"Top"]; - [iconAnchor setObject:@(MGLIconAnchorBottom) forKey:@"Bottom"]; - [iconAnchor setObject:@(MGLIconAnchorLeft) forKey:@"Left"]; - [iconAnchor setObject:@(MGLIconAnchorRight) forKey:@"Right"]; - [iconAnchor setObject:@(MGLIconAnchorTopLeft) forKey:@"TopLeft"]; - [iconAnchor setObject:@(MGLIconAnchorTopRight) forKey:@"TopRight"]; - [iconAnchor setObject:@(MGLIconAnchorBottomLeft) forKey:@"BottomLeft"]; - [iconAnchor setObject:@(MGLIconAnchorBottomRight) forKey:@"BottomRight"]; + [iconAnchor setObject:@(MLNIconAnchorCenter) forKey:@"Center"]; + [iconAnchor setObject:@(MLNIconAnchorTop) forKey:@"Top"]; + [iconAnchor setObject:@(MLNIconAnchorBottom) forKey:@"Bottom"]; + [iconAnchor setObject:@(MLNIconAnchorLeft) forKey:@"Left"]; + [iconAnchor setObject:@(MLNIconAnchorRight) forKey:@"Right"]; + [iconAnchor setObject:@(MLNIconAnchorTopLeft) forKey:@"TopLeft"]; + [iconAnchor setObject:@(MLNIconAnchorTopRight) forKey:@"TopRight"]; + [iconAnchor setObject:@(MLNIconAnchorBottomLeft) forKey:@"BottomLeft"]; + [iconAnchor setObject:@(MLNIconAnchorBottomRight) forKey:@"BottomRight"]; NSMutableDictionary *iconTranslateAnchor = [[NSMutableDictionary alloc] init]; - [iconTranslateAnchor setObject:@(MGLIconTranslationAnchorMap) forKey:@"Map"]; - [iconTranslateAnchor setObject:@(MGLIconTranslationAnchorViewport) forKey:@"Viewport"]; + [iconTranslateAnchor setObject:@(MLNIconTranslationAnchorMap) forKey:@"Map"]; + [iconTranslateAnchor setObject:@(MLNIconTranslationAnchorViewport) forKey:@"Viewport"]; NSMutableDictionary *iconPitchAlignment = [[NSMutableDictionary alloc] init]; - [iconPitchAlignment setObject:@(MGLIconPitchAlignmentAuto) forKey:@"Auto"]; - [iconPitchAlignment setObject:@(MGLIconPitchAlignmentMap) forKey:@"Map"]; - [iconPitchAlignment setObject:@(MGLIconPitchAlignmentViewport) forKey:@"Viewport"]; + [iconPitchAlignment setObject:@(MLNIconPitchAlignmentAuto) forKey:@"Auto"]; + [iconPitchAlignment setObject:@(MLNIconPitchAlignmentMap) forKey:@"Map"]; + [iconPitchAlignment setObject:@(MLNIconPitchAlignmentViewport) forKey:@"Viewport"]; NSMutableDictionary *symbolPlacement = [[NSMutableDictionary alloc] init]; - [symbolPlacement setObject:@(MGLSymbolPlacementLine) forKey:@"Line"]; - [symbolPlacement setObject:@(MGLSymbolPlacementPoint) forKey:@"Point"]; + [symbolPlacement setObject:@(MLNSymbolPlacementLine) forKey:@"Line"]; + [symbolPlacement setObject:@(MLNSymbolPlacementPoint) forKey:@"Point"]; NSMutableDictionary *textAnchor = [[NSMutableDictionary alloc] init]; - [textAnchor setObject:@(MGLTextAnchorCenter) forKey:@"Center"]; - [textAnchor setObject:@(MGLTextAnchorLeft) forKey:@"Left"]; - [textAnchor setObject:@(MGLTextAnchorRight) forKey:@"Right"]; - [textAnchor setObject:@(MGLTextAnchorTop) forKey:@"Top"]; - [textAnchor setObject:@(MGLTextAnchorBottom) forKey:@"Bottom"]; - [textAnchor setObject:@(MGLTextAnchorTopLeft) forKey:@"TopLeft"]; - [textAnchor setObject:@(MGLTextAnchorTopRight) forKey:@"TopRight"]; - [textAnchor setObject:@(MGLTextAnchorBottomLeft) forKey:@"BottomLeft"]; - [textAnchor setObject:@(MGLTextAnchorBottomRight) forKey:@"BottomRight"]; + [textAnchor setObject:@(MLNTextAnchorCenter) forKey:@"Center"]; + [textAnchor setObject:@(MLNTextAnchorLeft) forKey:@"Left"]; + [textAnchor setObject:@(MLNTextAnchorRight) forKey:@"Right"]; + [textAnchor setObject:@(MLNTextAnchorTop) forKey:@"Top"]; + [textAnchor setObject:@(MLNTextAnchorBottom) forKey:@"Bottom"]; + [textAnchor setObject:@(MLNTextAnchorTopLeft) forKey:@"TopLeft"]; + [textAnchor setObject:@(MLNTextAnchorTopRight) forKey:@"TopRight"]; + [textAnchor setObject:@(MLNTextAnchorBottomLeft) forKey:@"BottomLeft"]; + [textAnchor setObject:@(MLNTextAnchorBottomRight) forKey:@"BottomRight"]; NSMutableDictionary *textJustify = [[NSMutableDictionary alloc] init]; - [textJustify setObject:@(MGLTextJustificationCenter) forKey:@"Center"]; - [textJustify setObject:@(MGLTextJustificationLeft) forKey:@"Left"]; - [textJustify setObject:@(MGLTextJustificationRight) forKey:@"Right"]; + [textJustify setObject:@(MLNTextJustificationCenter) forKey:@"Center"]; + [textJustify setObject:@(MLNTextJustificationLeft) forKey:@"Left"]; + [textJustify setObject:@(MLNTextJustificationRight) forKey:@"Right"]; NSMutableDictionary *textPitchAlignment = [[NSMutableDictionary alloc] init]; - [textPitchAlignment setObject:@(MGLTextPitchAlignmentAuto) forKey:@"Auto"]; - [textPitchAlignment setObject:@(MGLTextPitchAlignmentMap) forKey:@"Map"]; - [textPitchAlignment setObject:@(MGLTextPitchAlignmentViewport) forKey:@"Viewport"]; + [textPitchAlignment setObject:@(MLNTextPitchAlignmentAuto) forKey:@"Auto"]; + [textPitchAlignment setObject:@(MLNTextPitchAlignmentMap) forKey:@"Map"]; + [textPitchAlignment setObject:@(MLNTextPitchAlignmentViewport) forKey:@"Viewport"]; NSMutableDictionary *textRotationAlignment = [[NSMutableDictionary alloc] init]; - [textRotationAlignment setObject:@(MGLTextRotationAlignmentAuto) forKey:@"Auto"]; - [textRotationAlignment setObject:@(MGLTextRotationAlignmentMap) forKey:@"Map"]; - [textRotationAlignment setObject:@(MGLTextRotationAlignmentViewport) forKey:@"Viewport"]; + [textRotationAlignment setObject:@(MLNTextRotationAlignmentAuto) forKey:@"Auto"]; + [textRotationAlignment setObject:@(MLNTextRotationAlignmentMap) forKey:@"Map"]; + [textRotationAlignment setObject:@(MLNTextRotationAlignmentViewport) forKey:@"Viewport"]; NSMutableDictionary *textTransform = [[NSMutableDictionary alloc] init]; - [textTransform setObject:@(MGLTextTransformNone) forKey:@"None"]; - [textTransform setObject:@(MGLTextTransformLowercase) forKey:@"Lowercase"]; - [textTransform setObject:@(MGLTextTransformUppercase) forKey:@"Uppercase"]; + [textTransform setObject:@(MLNTextTransformNone) forKey:@"None"]; + [textTransform setObject:@(MLNTextTransformLowercase) forKey:@"Lowercase"]; + [textTransform setObject:@(MLNTextTransformUppercase) forKey:@"Uppercase"]; NSMutableDictionary *textTranslateAnchor = [[NSMutableDictionary alloc] init]; - [textTranslateAnchor setObject:@(MGLTextTranslationAnchorMap) forKey:@"Map"]; - [textTranslateAnchor setObject:@(MGLTextTranslationAnchorViewport) forKey:@"Viewport"]; + [textTranslateAnchor setObject:@(MLNTextTranslationAnchorMap) forKey:@"Map"]; + [textTranslateAnchor setObject:@(MLNTextTranslationAnchorViewport) forKey:@"Viewport"]; // light constants NSMutableDictionary *lightAnchor = [[NSMutableDictionary alloc] init]; - [lightAnchor setObject:@(MGLLightAnchorMap) forKey:@"Map"]; - [lightAnchor setObject:@(MGLLightAnchorViewport) forKey:@"Viewport"]; + [lightAnchor setObject:@(MLNLightAnchorMap) forKey:@"Map"]; + [lightAnchor setObject:@(MLNLightAnchorViewport) forKey:@"Viewport"]; // offline module callback names NSMutableDictionary *offlineModuleCallbackNames = [[NSMutableDictionary alloc] init]; @@ -199,9 +199,9 @@ + (BOOL)requiresMainQueueSetup [offlineModuleCallbackNames setObject:RCT_MAPBOX_OFFLINE_CALLBACK_PROGRESS forKey:@"Progress"]; NSMutableDictionary *offlinePackDownloadState = [[NSMutableDictionary alloc] init]; - [offlinePackDownloadState setObject:@(MGLOfflinePackStateInactive) forKey:@"Inactive"]; - [offlinePackDownloadState setObject:@(MGLOfflinePackStateActive) forKey:@"Active"]; - [offlinePackDownloadState setObject:@(MGLOfflinePackStateComplete) forKey:@"Complete"]; + [offlinePackDownloadState setObject:@(MLNOfflinePackStateInactive) forKey:@"Inactive"]; + [offlinePackDownloadState setObject:@(MLNOfflinePackStateActive) forKey:@"Active"]; + [offlinePackDownloadState setObject:@(MLNOfflinePackStateComplete) forKey:@"Complete"]; return @{ @"StyleURL": styleURLS, @@ -240,23 +240,23 @@ + (BOOL)requiresMainQueueSetup RCT_EXPORT_METHOD(setAccessToken:(NSString *)accessToken) { if (accessToken.length > 0) { - [MGLSettings setApiKey:accessToken]; + [MLNSettings setApiKey:accessToken]; } } RCT_EXPORT_METHOD(addCustomHeader:(NSString *)headerName forHeaderValue:(NSString *) headerValue) { - [MGLCustomHeaders.sharedInstance addHeader:headerValue forHeaderName:headerName]; + [MLNCustomHeaders.sharedInstance addHeader:headerValue forHeaderName:headerName]; } RCT_EXPORT_METHOD(removeCustomHeader:(NSString *)headerName) { - [MGLCustomHeaders.sharedInstance removeHeader:headerName]; + [MLNCustomHeaders.sharedInstance removeHeader:headerName]; } RCT_EXPORT_METHOD(getAccessToken:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - NSString* accessToken = MGLSettings.apiKey; + NSString* accessToken = MLNSettings.apiKey; if (accessToken != nil) { resolve(accessToken); diff --git a/ios/RCTMGL/MGLOfflineModule.h b/ios/RCTMLN/MLNOfflineModule.h similarity index 72% rename from ios/RCTMGL/MGLOfflineModule.h rename to ios/RCTMLN/MLNOfflineModule.h index e876a175f..0da2e5949 100644 --- a/ios/RCTMGL/MGLOfflineModule.h +++ b/ios/RCTMLN/MLNOfflineModule.h @@ -1,6 +1,6 @@ // -// MGLOfflineModule.h -// RCTMGL +// MLNOfflineModule.h +// RCTMLN // // Created by Nick Italiano on 10/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -9,9 +9,9 @@ #import #import -@import Mapbox; +@import MapLibre; -@interface MGLOfflineModule : RCTEventEmitter +@interface MLNOfflineModule : RCTEventEmitter extern NSString *const RCT_MAPBOX_OFFLINE_CALLBACK_PROGRESS; extern NSString *const RCT_MAPBOX_OFFLINE_CALLBACK_ERROR; diff --git a/ios/RCTMGL/MGLOfflineModule.m b/ios/RCTMLN/MLNOfflineModule.m similarity index 80% rename from ios/RCTMGL/MGLOfflineModule.m rename to ios/RCTMLN/MLNOfflineModule.m index 719deeeb1..d7edfd423 100644 --- a/ios/RCTMGL/MGLOfflineModule.m +++ b/ios/RCTMLN/MLNOfflineModule.m @@ -1,17 +1,17 @@ // -// MGLOfflineModule.m -// RCTMGL +// MLNOfflineModule.m +// RCTMLN // // Created by Nick Italiano on 10/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "MGLOfflineModule.h" -#import "RCTMGLUtils.h" -#import "RCTMGLEvent.h" -#import "RCTMGLEventTypes.h" +#import "MLNOfflineModule.h" +#import "RCTMLNUtils.h" +#import "RCTMLNEvent.h" +#import "RCTMLNEventTypes.h" -@implementation MGLOfflineModule +@implementation MLNOfflineModule { NSUInteger lastPackState; double lastPackTimestamp; @@ -50,18 +50,18 @@ - (instancetype)init lastPackState = -1; NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; - [defaultCenter addObserver:self selector:@selector(offlinePackProgressDidChange:) name:MGLOfflinePackProgressChangedNotification object:nil]; - [defaultCenter addObserver:self selector:@selector(offlinePackDidReceiveError:) name:MGLOfflinePackErrorNotification object:nil]; - [defaultCenter addObserver:self selector:@selector(offlinePackDidReceiveMaxAllowedMapboxTiles:) name:MGLOfflinePackMaximumMapboxTilesReachedNotification object:nil]; + [defaultCenter addObserver:self selector:@selector(offlinePackProgressDidChange:) name:MLNOfflinePackProgressChangedNotification object:nil]; + [defaultCenter addObserver:self selector:@selector(offlinePackDidReceiveError:) name:MLNOfflinePackErrorNotification object:nil]; + [defaultCenter addObserver:self selector:@selector(offlinePackDidReceiveMaxAllowedMapboxTiles:) name:MLNOfflinePackMaximumMapboxTilesReachedNotification object:nil]; - [[MGLOfflineStorage sharedOfflineStorage] addObserver:self forKeyPath:@"packs" options:NSKeyValueObservingOptionInitial context:NULL]; + [[MLNOfflineStorage sharedOfflineStorage] addObserver:self forKeyPath:@"packs" options:NSKeyValueObservingOptionInitial context:NULL]; } return self; } - (void)dealloc { - [[MGLOfflineStorage sharedOfflineStorage] removeObserver:self forKeyPath:@"packs"]; + [[MLNOfflineStorage sharedOfflineStorage] removeObserver:self forKeyPath:@"packs"]; [[NSNotificationCenter defaultCenter] removeObserver:self]; } @@ -76,7 +76,7 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N return; } - NSArray *packs = [[MGLOfflineStorage sharedOfflineStorage] packs]; + NSArray *packs = [[MLNOfflineStorage sharedOfflineStorage] packs]; if (packs == nil) { return; } @@ -93,17 +93,17 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N rejecter:(RCTPromiseRejectBlock)reject) { NSString *styleURL = options[@"styleURL"]; - MGLCoordinateBounds bounds = [RCTMGLUtils fromFeatureCollection:options[@"bounds"]]; + MLNCoordinateBounds bounds = [RCTMLNUtils fromFeatureCollection:options[@"bounds"]]; - id offlineRegion = [[MGLTilePyramidOfflineRegion alloc] initWithStyleURL:[NSURL URLWithString:styleURL] + id offlineRegion = [[MLNTilePyramidOfflineRegion alloc] initWithStyleURL:[NSURL URLWithString:styleURL] bounds:bounds fromZoomLevel:[options[@"minZoom"] doubleValue] toZoomLevel:[options[@"maxZoom"] doubleValue]]; NSData *context = [self _archiveMetadata:options[@"metadata"]]; - [[MGLOfflineStorage sharedOfflineStorage] addPackForRegion:offlineRegion + [[MLNOfflineStorage sharedOfflineStorage] addPackForRegion:offlineRegion withContext:context - completionHandler:^(MGLOfflinePack *pack, NSError *error) { + completionHandler:^(MLNOfflinePack *pack, NSError *error) { if (error != nil) { reject(@"createPack", error.description, error); return; @@ -130,7 +130,7 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N } } - [[MGLOfflineStorage sharedOfflineStorage] addContentsOfFile:absolutePath withCompletionHandler:^(NSURL *fileURL, NSArray *packs, NSError *error) { + [[MLNOfflineStorage sharedOfflineStorage] addContentsOfFile:absolutePath withCompletionHandler:^(NSURL *fileURL, NSArray *packs, NSError *error) { if (error != nil) { reject(@"mergeOfflineRegions", error.description, error); return; @@ -142,7 +142,7 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N RCT_EXPORT_METHOD(getPacks:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { dispatch_async(dispatch_get_main_queue(), ^{ - NSArray *packs = [[MGLOfflineStorage sharedOfflineStorage] packs]; + NSArray *packs = [[MLNOfflineStorage sharedOfflineStorage] packs]; if (packs == nil) { // packs have not loaded yet @@ -156,7 +156,7 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N RCT_EXPORT_METHOD(invalidateAmbientCache:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - [[MGLOfflineStorage sharedOfflineStorage] invalidateAmbientCacheWithCompletionHandler:^(NSError *error) { + [[MLNOfflineStorage sharedOfflineStorage] invalidateAmbientCacheWithCompletionHandler:^(NSError *error) { if (error != nil) { reject(@"invalidateAmbientCache", error.description, error); return; @@ -167,7 +167,7 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N RCT_EXPORT_METHOD(clearAmbientCache:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - [[MGLOfflineStorage sharedOfflineStorage] clearAmbientCacheWithCompletionHandler:^(NSError *error) { + [[MLNOfflineStorage sharedOfflineStorage] clearAmbientCacheWithCompletionHandler:^(NSError *error) { if (error != nil) { reject(@"clearAmbientCache", error.description, error); return; @@ -180,7 +180,7 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N resolver:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - [[MGLOfflineStorage sharedOfflineStorage] setMaximumAmbientCacheSize:cacheSize withCompletionHandler:^(NSError *error) { + [[MLNOfflineStorage sharedOfflineStorage] setMaximumAmbientCacheSize:cacheSize withCompletionHandler:^(NSError *error) { if (error != nil) { reject(@"setMaximumAmbientCacheSize", error.description, error); return; @@ -192,7 +192,7 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N RCT_EXPORT_METHOD(resetDatabase:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - [[MGLOfflineStorage sharedOfflineStorage] resetDatabaseWithCompletionHandler:^(NSError *error) { + [[MLNOfflineStorage sharedOfflineStorage] resetDatabaseWithCompletionHandler:^(NSError *error) { if (error != nil) { reject(@"resetDatabase", error.description, error); return; @@ -206,7 +206,7 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N resolver:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - MGLOfflinePack *pack = [self _getPackFromName:name]; + MLNOfflinePack *pack = [self _getPackFromName:name]; if (pack == nil) { resolve(nil); @@ -221,13 +221,13 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N resolver:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - MGLOfflinePack *pack = [self _getPackFromName:name]; + MLNOfflinePack *pack = [self _getPackFromName:name]; if (pack == nil) { resolve(nil); return; } - [[MGLOfflineStorage sharedOfflineStorage] invalidatePack:pack withCompletionHandler:^(NSError *error) { + [[MLNOfflineStorage sharedOfflineStorage] invalidatePack:pack withCompletionHandler:^(NSError *error) { if (error != nil) { reject(@"invalidatePack", error.description, error); return; @@ -240,18 +240,18 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N resolver:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - MGLOfflinePack *pack = [self _getPackFromName:name]; + MLNOfflinePack *pack = [self _getPackFromName:name]; if (pack == nil) { resolve(nil); return; } - if (pack.state == MGLOfflinePackStateInvalid) { - NSError *error = [NSError errorWithDomain:MGLErrorDomain code:1 userInfo:@{NSLocalizedDescriptionKey: NSLocalizedString(@"Pack has already been deleted", nil)}]; + if (pack.state == MLNOfflinePackStateInvalid) { + NSError *error = [NSError errorWithDomain:MLNErrorDomain code:1 userInfo:@{NSLocalizedDescriptionKey: NSLocalizedString(@"Pack has already been deleted", nil)}]; reject(@"deletePack", error.description, error); return; } - [[MGLOfflineStorage sharedOfflineStorage] removePack:pack withCompletionHandler:^(NSError *error) { + [[MLNOfflineStorage sharedOfflineStorage] removePack:pack withCompletionHandler:^(NSError *error) { if (error != nil) { reject(@"deletePack", error.description, error); return; @@ -264,14 +264,14 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N resolver:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - MGLOfflinePack *pack = [self _getPackFromName:name]; + MLNOfflinePack *pack = [self _getPackFromName:name]; if (pack == nil) { reject(@"pausePackDownload", @"Unknown offline region", nil); return; } - if (pack.state == MGLOfflinePackStateInactive || pack.state == MGLOfflinePackStateComplete) { + if (pack.state == MLNOfflinePackStateInactive || pack.state == MLNOfflinePackStateComplete) { resolve(nil); return; } @@ -284,14 +284,14 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N resolver:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - MGLOfflinePack *pack = [self _getPackFromName:name]; + MLNOfflinePack *pack = [self _getPackFromName:name]; if (pack == nil) { reject(@"resumePack", @"Unknown offline region", nil); return; } - if (pack.state == MGLOfflinePackStateActive || pack.state == MGLOfflinePackStateComplete) { + if (pack.state == MLNOfflinePackStateActive || pack.state == MLNOfflinePackStateComplete) { resolve(nil); return; } @@ -302,7 +302,7 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N RCT_EXPORT_METHOD(setTileCountLimit:(nonnull NSNumber *)limit) { - [[MGLOfflineStorage sharedOfflineStorage] setMaximumAllowedMapboxTiles:[limit intValue]]; + [[MLNOfflineStorage sharedOfflineStorage] setMaximumAllowedMapboxTiles:[limit intValue]]; } RCT_EXPORT_METHOD(setProgressEventThrottle:(nonnull NSNumber *)throttleValue) @@ -312,15 +312,15 @@ - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(N - (void)offlinePackProgressDidChange:(NSNotification *)notification { - MGLOfflinePack *pack = notification.object; + MLNOfflinePack *pack = notification.object; - if (pack.state == MGLOfflinePackStateInvalid) { + if (pack.state == MLNOfflinePackStateInvalid) { return; // Avoid invalid offline pack exception } if ([self _shouldSendProgressEvent:[self _getCurrentTimestamp] pack:pack]) { NSDictionary *metadata = [self _unarchiveMetadata:pack]; - RCTMGLEvent *event = [self _makeProgressEvent:metadata[@"name"] pack:pack]; + RCTMLNEvent *event = [self _makeProgressEvent:metadata[@"name"] pack:pack]; [self _sendEvent:RCT_MAPBOX_OFFLINE_CALLBACK_PROGRESS event:event]; lastPackTimestamp = [self _getCurrentTimestamp]; } @@ -330,16 +330,16 @@ - (void)offlinePackProgressDidChange:(NSNotification *)notification - (void)offlinePackDidReceiveError:(NSNotification *)notification { - MGLOfflinePack *pack = notification.object; - if (pack.state == MGLOfflinePackStateInvalid) { + MLNOfflinePack *pack = notification.object; + if (pack.state == MLNOfflinePackStateInvalid) { return; // Avoid invalid offline pack exception } NSDictionary *metadata = [self _unarchiveMetadata:pack]; NSString *name = metadata[@"name"]; if (name != nil) { - NSError *error = notification.userInfo[MGLOfflinePackUserInfoKeyError]; - RCTMGLEvent *event = [self _makeErrorEvent:name + NSError *error = notification.userInfo[MLNOfflinePackUserInfoKeyError]; + RCTMLNEvent *event = [self _makeErrorEvent:name type:RCT_MAPBOX_OFFLINE_ERROR message:error.description]; [self _sendEvent:RCT_MAPBOX_OFFLINE_CALLBACK_ERROR event:event]; @@ -348,12 +348,12 @@ - (void)offlinePackDidReceiveError:(NSNotification *)notification - (void)offlinePackDidReceiveMaxAllowedMapboxTiles:(NSNotification *)notification { - MGLOfflinePack *pack = notification.object; + MLNOfflinePack *pack = notification.object; NSDictionary *metadata = [self _unarchiveMetadata:pack]; NSString *name = metadata[@"name"]; if (name != nil) { - RCTMGLEvent *event = [self _makeErrorEvent:name + RCTMLNEvent *event = [self _makeErrorEvent:name type:RCT_MAPBOX_OFFLINE_ERROR message:@"Mapbox tile limit exceeded"]; [self _sendEvent:RCT_MAPBOX_OFFLINE_CALLBACK_ERROR event:event]; @@ -370,7 +370,7 @@ - (NSData *)_archiveMetadata:(NSString *)metadata return [NSKeyedArchiver archivedDataWithRootObject:metadata]; } -- (NSDictionary *)_unarchiveMetadata:(MGLOfflinePack *)pack +- (NSDictionary *)_unarchiveMetadata:(MLNOfflinePack *)pack { id data = [NSKeyedUnarchiver unarchiveObjectWithData:pack.context]; // Version v5 store data as NSDictionary while v6 store data as JSON string. @@ -396,7 +396,7 @@ - (NSDictionary *)_unarchiveMetadata:(MGLOfflinePack *)pack error:nil]; } -- (NSDictionary *)_makeRegionStatusPayload:(NSString *)name pack:(MGLOfflinePack *)pack +- (NSDictionary *)_makeRegionStatusPayload:(NSString *)name pack:(MLNOfflinePack *)pack { uint64_t completedResources = pack.progress.countOfResourcesCompleted; uint64_t expectedResources = pack.progress.countOfResourcesExpected; @@ -419,18 +419,18 @@ - (NSDictionary *)_makeRegionStatusPayload:(NSString *)name pack:(MGLOfflinePack }; } -- (RCTMGLEvent *)_makeProgressEvent:(NSString *)name pack:(MGLOfflinePack *)pack +- (RCTMLNEvent *)_makeProgressEvent:(NSString *)name pack:(MLNOfflinePack *)pack { - return [RCTMGLEvent makeEvent:RCT_MAPBOX_OFFLINE_PROGRESS withPayload:[self _makeRegionStatusPayload:name pack:pack]]; + return [RCTMLNEvent makeEvent:RCT_MAPBOX_OFFLINE_PROGRESS withPayload:[self _makeRegionStatusPayload:name pack:pack]]; } -- (RCTMGLEvent *)_makeErrorEvent:(NSString *)name type:(NSString *)type message:(NSString *)message +- (RCTMLNEvent *)_makeErrorEvent:(NSString *)name type:(NSString *)type message:(NSString *)message { NSDictionary *payload = @{ @"name": name, @"message": message }; - return [RCTMGLEvent makeEvent:type withPayload:payload]; + return [RCTMLNEvent makeEvent:type withPayload:payload]; } -- (NSArray *)_convertPacksToJson:(NSArray *)packs +- (NSArray *)_convertPacksToJson:(NSArray *)packs { NSMutableArray *jsonPacks = [NSMutableArray new]; @@ -438,17 +438,17 @@ - (RCTMGLEvent *)_makeErrorEvent:(NSString *)name type:(NSString *)type message: return jsonPacks; } - for (MGLOfflinePack *pack in packs) { + for (MLNOfflinePack *pack in packs) { [jsonPacks addObject:[self _convertPackToDict:pack]]; } return jsonPacks; } -- (NSDictionary *)_convertPackToDict:(MGLOfflinePack *)pack +- (NSDictionary *)_convertPackToDict:(MLNOfflinePack *)pack { // format bounds - MGLTilePyramidOfflineRegion *region = (MGLTilePyramidOfflineRegion *)pack.region; + MLNTilePyramidOfflineRegion *region = (MLNTilePyramidOfflineRegion *)pack.region; if (region == nil) { return nil; } @@ -469,15 +469,15 @@ - (NSDictionary *)_convertPackToDict:(MGLOfflinePack *)pack }; } -- (MGLOfflinePack *)_getPackFromName:(NSString *)name +- (MLNOfflinePack *)_getPackFromName:(NSString *)name { - NSArray *packs = [[MGLOfflineStorage sharedOfflineStorage] packs]; + NSArray *packs = [[MLNOfflineStorage sharedOfflineStorage] packs]; if (packs == nil) { return nil; } - for (MGLOfflinePack *pack in packs) { + for (MLNOfflinePack *pack in packs) { NSDictionary *metadata = [self _unarchiveMetadata:pack]; if ([name isEqualToString:metadata[@"name"]]) { @@ -488,7 +488,7 @@ - (MGLOfflinePack *)_getPackFromName:(NSString *)name return nil; } -- (void)_sendEvent:(NSString *)eventName event:(RCTMGLEvent *)event +- (void)_sendEvent:(NSString *)eventName event:(RCTMLNEvent *)event { if (!hasListeners) { return; @@ -496,7 +496,7 @@ - (void)_sendEvent:(NSString *)eventName event:(RCTMGLEvent *)event [self sendEventWithName:eventName body:[event toJSON]]; } -- (BOOL)_shouldSendProgressEvent:(double)currentTimestamp pack:(MGLOfflinePack *)currentPack +- (BOOL)_shouldSendProgressEvent:(double)currentTimestamp pack:(MLNOfflinePack *)currentPack { if (lastPackState == -1) { return YES; diff --git a/ios/RCTMGL/MGLSnapshotModule.h b/ios/RCTMLN/MLNSnapshotModule.h similarity index 61% rename from ios/RCTMGL/MGLSnapshotModule.h rename to ios/RCTMLN/MLNSnapshotModule.h index bf868aeb7..a8b985aaa 100644 --- a/ios/RCTMGL/MGLSnapshotModule.h +++ b/ios/RCTMLN/MLNSnapshotModule.h @@ -1,6 +1,6 @@ // -// MGLSnapshotModule.h -// RCTMGL +// MLNSnapshotModule.h +// RCTMLN // // Created by Nick Italiano on 12/1/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import -@interface MGLSnapshotModule : NSObject +@interface MLNSnapshotModule : NSObject @end diff --git a/ios/RCTMGL/MGLSnapshotModule.m b/ios/RCTMLN/MLNSnapshotModule.m similarity index 74% rename from ios/RCTMGL/MGLSnapshotModule.m rename to ios/RCTMLN/MLNSnapshotModule.m index 25ba8d1ab..7d6820a96 100644 --- a/ios/RCTMGL/MGLSnapshotModule.m +++ b/ios/RCTMLN/MLNSnapshotModule.m @@ -1,17 +1,17 @@ // -// MGLSnapshotModule.m -// RCTMGL +// MLNSnapshotModule.m +// RCTMLN // // Created by Nick Italiano on 12/1/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "MGLSnapshotModule.h" -#import "RCTMGLUtils.h" +#import "MLNSnapshotModule.h" +#import "RCTMLNUtils.h" #import "RNMBImageUtils.h" -@import Mapbox; +@import MapLibre; -@implementation MGLSnapshotModule +@implementation MLNSnapshotModule RCT_EXPORT_MODULE() @@ -25,10 +25,10 @@ + (BOOL)requiresMainQueueSetup rejecter:(RCTPromiseRejectBlock)reject) { dispatch_async(dispatch_get_main_queue(), ^{ - MGLMapSnapshotOptions *options = [self _getOptions:jsOptions]; - __block MGLMapSnapshotter *snapshotter = [[MGLMapSnapshotter alloc] initWithOptions:options]; + MLNMapSnapshotOptions *options = [self _getOptions:jsOptions]; + __block MLNMapSnapshotter *snapshotter = [[MLNMapSnapshotter alloc] initWithOptions:options]; - [snapshotter startWithCompletionHandler:^(MGLMapSnapshot * _Nullable snapshot, NSError * _Nullable err) { + [snapshotter startWithCompletionHandler:^(MLNMapSnapshot * _Nullable snapshot, NSError * _Nullable err) { if (err != nil) { reject(@"takeSnap", @"Could not create snapshot", err); snapshotter = nil; @@ -48,22 +48,22 @@ + (BOOL)requiresMainQueueSetup }); } -- (MGLMapSnapshotOptions *)_getOptions:(NSDictionary *)jsOptions +- (MLNMapSnapshotOptions *)_getOptions:(NSDictionary *)jsOptions { - MGLMapCamera *camera = [[MGLMapCamera alloc] init]; + MLNMapCamera *camera = [[MLNMapCamera alloc] init]; camera.pitch = [jsOptions[@"pitch"] doubleValue]; camera.heading = [jsOptions[@"heading"] doubleValue]; if (jsOptions[@"centerCoordinate"] != nil) { - camera.centerCoordinate = [RCTMGLUtils fromFeature:jsOptions[@"centerCoordinate"]]; + camera.centerCoordinate = [RCTMLNUtils fromFeature:jsOptions[@"centerCoordinate"]]; } NSNumber *width = jsOptions[@"width"]; NSNumber *height = jsOptions[@"height"]; CGSize size = CGSizeMake([width doubleValue], [height doubleValue]); - MGLMapSnapshotOptions *options = [[MGLMapSnapshotOptions alloc] initWithStyleURL:[NSURL URLWithString:jsOptions[@"styleURL"]] + MLNMapSnapshotOptions *options = [[MLNMapSnapshotOptions alloc] initWithStyleURL:[NSURL URLWithString:jsOptions[@"styleURL"]] camera:camera size:size]; if (jsOptions[@"zoomLevel"] != nil) { @@ -71,7 +71,7 @@ - (MGLMapSnapshotOptions *)_getOptions:(NSDictionary *)jsOptions } if (jsOptions[@"bounds"] != nil) { - options.coordinateBounds = [RCTMGLUtils fromFeatureCollection:jsOptions[@"bounds"]]; + options.coordinateBounds = [RCTMLNUtils fromFeatureCollection:jsOptions[@"bounds"]]; } return options; diff --git a/ios/RCTMGL/MGLUserLocationHeadingArrowLayer.h b/ios/RCTMLN/MLNUserLocationHeadingArrowLayer.h similarity index 52% rename from ios/RCTMGL/MGLUserLocationHeadingArrowLayer.h rename to ios/RCTMLN/MLNUserLocationHeadingArrowLayer.h index 90727cd1d..6fad54b12 100644 --- a/ios/RCTMGL/MGLUserLocationHeadingArrowLayer.h +++ b/ios/RCTMLN/MLNUserLocationHeadingArrowLayer.h @@ -1,10 +1,10 @@ #import -#import "MGLUserLocationHeadingIndicator.h" -@import Mapbox; +#import "MLNUserLocationHeadingIndicator.h" +@import MapLibre; -@interface MGLUserLocationHeadingArrowLayer : CAShapeLayer +@interface MLNUserLocationHeadingArrowLayer : CAShapeLayer -- (instancetype)initWithUserLocationAnnotationView:(MGLUserLocationAnnotationView *)userLocationView; +- (instancetype)initWithUserLocationAnnotationView:(MLNUserLocationAnnotationView *)userLocationView; - (void)updateHeadingAccuracy:(CLLocationDirection)accuracy; - (void)updateTintColor:(CGColorRef)color; diff --git a/ios/RCTMGL/MGLUserLocationHeadingArrowLayer.m b/ios/RCTMLN/MLNUserLocationHeadingArrowLayer.m similarity index 79% rename from ios/RCTMGL/MGLUserLocationHeadingArrowLayer.m rename to ios/RCTMLN/MLNUserLocationHeadingArrowLayer.m index b63ba09f1..3f6634873 100644 --- a/ios/RCTMGL/MGLUserLocationHeadingArrowLayer.m +++ b/ios/RCTMLN/MLNUserLocationHeadingArrowLayer.m @@ -1,13 +1,13 @@ -#import "MGLUserLocationHeadingArrowLayer.h" -#import "MGLFaux3DUserLocationAnnotationView.h" +#import "MLNUserLocationHeadingArrowLayer.h" +#import "MLNFaux3DUserLocationAnnotationView.h" -const CGFloat MGLUserLocationHeadingArrowSize = 6; +const CGFloat MLNUserLocationHeadingArrowSize = 6; -@implementation MGLUserLocationHeadingArrowLayer +@implementation MLNUserLocationHeadingArrowLayer -- (instancetype)initWithUserLocationAnnotationView:(MGLUserLocationAnnotationView *)userLocationView +- (instancetype)initWithUserLocationAnnotationView:(MLNUserLocationAnnotationView *)userLocationView { - CGFloat size = userLocationView.bounds.size.width + MGLUserLocationHeadingArrowSize; + CGFloat size = userLocationView.bounds.size.width + MLNUserLocationHeadingArrowSize; self = [super init]; self.bounds = CGRectMake(0, 0, size, size); @@ -37,7 +37,7 @@ - (void)updateTintColor:(CGColorRef)color - (CGPathRef)arrowPath { CGFloat center = roundf(CGRectGetMidX(self.bounds)); - CGFloat size = MGLUserLocationHeadingArrowSize; + CGFloat size = MLNUserLocationHeadingArrowSize; CGPoint top = CGPointMake(center, 0); CGPoint left = CGPointMake(center - size, size); diff --git a/ios/RCTMLN/MLNUserLocationHeadingBeamLayer.h b/ios/RCTMLN/MLNUserLocationHeadingBeamLayer.h new file mode 100644 index 000000000..d5a4ed1aa --- /dev/null +++ b/ios/RCTMLN/MLNUserLocationHeadingBeamLayer.h @@ -0,0 +1,11 @@ +#import +#import "MLNUserLocationHeadingIndicator.h" +@import MapLibre; + +@interface MLNUserLocationHeadingBeamLayer : CALayer + +- (MLNUserLocationHeadingBeamLayer *)initWithUserLocationAnnotationView:(MLNUserLocationAnnotationView *)userLocationView; +- (void)updateHeadingAccuracy:(CLLocationDirection)accuracy; +- (void)updateTintColor:(CGColorRef)color; + +@end diff --git a/ios/RCTMGL/MGLUserLocationHeadingBeamLayer.m b/ios/RCTMLN/MLNUserLocationHeadingBeamLayer.m similarity index 84% rename from ios/RCTMGL/MGLUserLocationHeadingBeamLayer.m rename to ios/RCTMLN/MLNUserLocationHeadingBeamLayer.m index d3d85b18c..9ebd48eac 100644 --- a/ios/RCTMGL/MGLUserLocationHeadingBeamLayer.m +++ b/ios/RCTMLN/MLNUserLocationHeadingBeamLayer.m @@ -1,14 +1,14 @@ -#import "MGLUserLocationHeadingBeamLayer.h" -#import "MGLFaux3DUserLocationAnnotationView.h" +#import "MLNUserLocationHeadingBeamLayer.h" +#import "MLNFaux3DUserLocationAnnotationView.h" -@implementation MGLUserLocationHeadingBeamLayer +@implementation MLNUserLocationHeadingBeamLayer { CAShapeLayer *_maskLayer; } -- (instancetype)initWithUserLocationAnnotationView:(MGLUserLocationAnnotationView *)userLocationView +- (instancetype)initWithUserLocationAnnotationView:(MLNUserLocationAnnotationView *)userLocationView { - CGFloat size = MGLUserLocationAnnotationHaloSize; + CGFloat size = MLNUserLocationAnnotationHaloSize; self = [super init]; self.bounds = CGRectMake(0, 0, size, size); @@ -45,9 +45,9 @@ - (CGImageRef)gradientImageWithTintColor:(CGColorRef)tintColor { UIImage *image; - CGFloat haloRadius = MGLUserLocationAnnotationHaloSize / 2.0; + CGFloat haloRadius = MLNUserLocationAnnotationHaloSize / 2.0; - UIGraphicsBeginImageContextWithOptions(CGSizeMake(MGLUserLocationAnnotationHaloSize, haloRadius), NO, 0); + UIGraphicsBeginImageContextWithOptions(CGSizeMake(MLNUserLocationAnnotationHaloSize, haloRadius), NO, 0); CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB(); CGContextRef context = UIGraphicsGetCurrentContext(); @@ -83,14 +83,14 @@ - (CGPathRef)clippingMaskForAccuracy:(CGFloat)accuracy clippingDegrees = fmin(clippingDegrees, 70); // most accurate clippingDegrees = fmax(clippingDegrees, 10); // least accurate - CGRect ovalRect = CGRectMake(0, 0, MGLUserLocationAnnotationHaloSize, MGLUserLocationAnnotationHaloSize); + CGRect ovalRect = CGRectMake(0, 0, MLNUserLocationAnnotationHaloSize, MLNUserLocationAnnotationHaloSize); UIBezierPath *ovalPath = UIBezierPath.bezierPath; // clip the oval to ± incoming accuracy degrees (converted to radians), from the top [ovalPath addArcWithCenter:CGPointMake(CGRectGetMidX(ovalRect), CGRectGetMidY(ovalRect)) radius:CGRectGetWidth(ovalRect) / 2.0 - startAngle:MGLRadiansFromDegrees(-180 + clippingDegrees) - endAngle:MGLRadiansFromDegrees(-clippingDegrees) + startAngle:MLNRadiansFromDegrees(-180 + clippingDegrees) + endAngle:MLNRadiansFromDegrees(-clippingDegrees) clockwise:YES]; [ovalPath addLineToPoint:CGPointMake(CGRectGetMidX(ovalRect), CGRectGetMidY(ovalRect))]; diff --git a/ios/RCTMGL/MGLUserLocationHeadingIndicator.h b/ios/RCTMLN/MLNUserLocationHeadingIndicator.h similarity index 57% rename from ios/RCTMGL/MGLUserLocationHeadingIndicator.h rename to ios/RCTMLN/MLNUserLocationHeadingIndicator.h index e17d59939..5b82de93b 100644 --- a/ios/RCTMGL/MGLUserLocationHeadingIndicator.h +++ b/ios/RCTMLN/MLNUserLocationHeadingIndicator.h @@ -1,9 +1,9 @@ #import -@import Mapbox; +@import MapLibre; -@protocol MGLUserLocationHeadingIndicator +@protocol MLNUserLocationHeadingIndicator -- (instancetype)initWithUserLocationAnnotationView:(MGLUserLocationAnnotationView *)userLocationView; +- (instancetype)initWithUserLocationAnnotationView:(MLNUserLocationAnnotationView *)userLocationView; - (void)updateHeadingAccuracy:(CLLocationDirection)accuracy; - (void)updateTintColor:(CGColorRef)color; diff --git a/ios/RCTMGL/RCTConvert+Mapbox.h b/ios/RCTMLN/RCTConvert+Mapbox.h similarity index 96% rename from ios/RCTMGL/RCTConvert+Mapbox.h rename to ios/RCTMLN/RCTConvert+Mapbox.h index da34b5a74..54e224559 100644 --- a/ios/RCTMGL/RCTConvert+Mapbox.h +++ b/ios/RCTMLN/RCTConvert+Mapbox.h @@ -1,6 +1,6 @@ // // RCTConvert+Mapbox.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. diff --git a/ios/RCTMGL/RCTConvert+Mapbox.m b/ios/RCTMLN/RCTConvert+Mapbox.m similarity index 98% rename from ios/RCTMGL/RCTConvert+Mapbox.m rename to ios/RCTMLN/RCTConvert+Mapbox.m index 318b95681..e434769f5 100644 --- a/ios/RCTMGL/RCTConvert+Mapbox.m +++ b/ios/RCTMLN/RCTConvert+Mapbox.m @@ -1,6 +1,6 @@ // // RCTConvert+Mapbox.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. diff --git a/ios/RCTMGL/RCTMGL.h b/ios/RCTMLN/RCTMLN.h similarity index 73% rename from ios/RCTMGL/RCTMGL.h rename to ios/RCTMLN/RCTMLN.h index 3fd628faf..28d9090cb 100644 --- a/ios/RCTMGL/RCTMGL.h +++ b/ios/RCTMLN/RCTMLN.h @@ -1,6 +1,6 @@ // -// RCTMGL.h -// RCTMGL +// RCTMLN.h +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import -@interface RCTMGL : NSObject +@interface RCTMLN : NSObject @end diff --git a/ios/RCTMGL/RCTMGL.m b/ios/RCTMLN/RCTMLN.m similarity index 63% rename from ios/RCTMGL/RCTMGL.m rename to ios/RCTMLN/RCTMLN.m index a7972e274..9d02fbeec 100644 --- a/ios/RCTMGL/RCTMGL.m +++ b/ios/RCTMLN/RCTMLN.m @@ -1,13 +1,13 @@ // -// RCTMGL.m -// RCTMGL +// RCTMLN.m +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGL.h" +#import "RCTMLN.h" -@implementation RCTMGL +@implementation RCTMLN @end diff --git a/ios/RCTMLN/RCTMLNBackgroundLayer.h b/ios/RCTMLN/RCTMLNBackgroundLayer.h new file mode 100644 index 000000000..942ff425a --- /dev/null +++ b/ios/RCTMLN/RCTMLNBackgroundLayer.h @@ -0,0 +1,14 @@ +// +// RCTMLNBackgroundLayer.h +// RCTMLN +// +// Created by Nick Italiano on 9/25/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import "RCTMLNLayer.h" +@import MapLibre; + +@interface RCTMLNBackgroundLayer : RCTMLNLayer + +@end diff --git a/ios/RCTMLN/RCTMLNBackgroundLayer.m b/ios/RCTMLN/RCTMLNBackgroundLayer.m new file mode 100644 index 000000000..aed204091 --- /dev/null +++ b/ios/RCTMLN/RCTMLNBackgroundLayer.m @@ -0,0 +1,27 @@ +// +// RCTMLNBackgroundLayer.m +// RCTMLN +// +// Created by Nick Italiano on 9/25/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import "RCTMLNBackgroundLayer.h" +#import "RCTMLNStyle.h" + +@implementation RCTMLNBackgroundLayer + +- (MLNStyleLayer*)makeLayer:(MLNStyle*)style +{ + return [[MLNBackgroundStyleLayer alloc] initWithIdentifier:self.id]; +} + +- (void)addStyles +{ + RCTMLNStyle *style = [[RCTMLNStyle alloc] initWithMLNStyle:self.style]; + style.bridge = self.bridge; + [style backgroundLayer:(MLNBackgroundStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; + }]; +} + +@end diff --git a/ios/RCTMGL/RCTMGLBackgroundLayerManager.h b/ios/RCTMLN/RCTMLNBackgroundLayerManager.h similarity index 57% rename from ios/RCTMGL/RCTMGLBackgroundLayerManager.h rename to ios/RCTMLN/RCTMLNBackgroundLayerManager.h index 23baa5498..86736882a 100644 --- a/ios/RCTMGL/RCTMGLBackgroundLayerManager.h +++ b/ios/RCTMLN/RCTMLNBackgroundLayerManager.h @@ -1,6 +1,6 @@ // -// RCTMGLBackgroundLayerManager.h -// RCTMGL +// RCTMLNBackgroundLayerManager.h +// RCTMLN // // Created by Nick Italiano on 9/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLBackgroundLayerManager : ViewManager +@interface RCTMLNBackgroundLayerManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLBackgroundLayerManager.m b/ios/RCTMLN/RCTMLNBackgroundLayerManager.m similarity index 73% rename from ios/RCTMGL/RCTMGLBackgroundLayerManager.m rename to ios/RCTMLN/RCTMLNBackgroundLayerManager.m index 0150531dc..eec1210a7 100644 --- a/ios/RCTMGL/RCTMGLBackgroundLayerManager.m +++ b/ios/RCTMLN/RCTMLNBackgroundLayerManager.m @@ -1,15 +1,15 @@ // -// RCTMGLBackgroundLayerManager.m -// RCTMGL +// RCTMLNBackgroundLayerManager.m +// RCTMLN // // Created by Nick Italiano on 9/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLBackgroundLayerManager.h" -#import "RCTMGLBackgroundLayer.h" +#import "RCTMLNBackgroundLayerManager.h" +#import "RCTMLNBackgroundLayer.h" -@implementation RCTMGLBackgroundLayerManager +@implementation RCTMLNBackgroundLayerManager RCT_EXPORT_MODULE() @@ -27,7 +27,7 @@ @implementation RCTMGLBackgroundLayerManager - (UIView*)view { - RCTMGLBackgroundLayer *layer = [[RCTMGLBackgroundLayer alloc] init]; + RCTMLNBackgroundLayer *layer = [[RCTMLNBackgroundLayer alloc] init]; layer.bridge = self.bridge; return layer; } diff --git a/ios/RCTMGL/RCTMGLCallout.h b/ios/RCTMLN/RCTMLNCallout.h similarity index 57% rename from ios/RCTMGL/RCTMGLCallout.h rename to ios/RCTMLN/RCTMLNCallout.h index 599d109be..23a2dff53 100644 --- a/ios/RCTMGL/RCTMGLCallout.h +++ b/ios/RCTMLN/RCTMLNCallout.h @@ -1,6 +1,6 @@ // -// RCTMGLCalloutView.h -// RCTMGL +// RCTMLNCalloutView.h +// RCTMLN // // Created by Nick Italiano on 10/13/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,8 +8,8 @@ #import -@import Mapbox; +@import MapLibre; -@interface RCTMGLCallout : RCTView +@interface RCTMLNCallout : RCTView @end diff --git a/ios/RCTMGL/RCTMGLCallout.m b/ios/RCTMLN/RCTMLNCallout.m similarity index 90% rename from ios/RCTMGL/RCTMGLCallout.m rename to ios/RCTMLN/RCTMLNCallout.m index 5e995c633..e1575e091 100644 --- a/ios/RCTMGL/RCTMGLCallout.m +++ b/ios/RCTMLN/RCTMLNCallout.m @@ -1,20 +1,20 @@ // -// RCTMGLCalloutView.m -// RCTMGL +// RCTMLNCalloutView.m +// RCTMLN // // Created by Nick Italiano on 10/13/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLCallout.h" +#import "RCTMLNCallout.h" #import -@implementation RCTMGLCallout +@implementation RCTMLNCallout { - id _representedObject; + id _representedObject; __unused UIView *_leftAccessoryView;/* unused */ __unused UIView *_rightAccessoryView;/* unused */ - __weak id _delegate; + __weak id _delegate; BOOL _dismissesAutomatically; BOOL _anchoredToAnnotation; } diff --git a/ios/RCTMGL/RCTMGLCalloutManager.h b/ios/RCTMLN/RCTMLNCalloutManager.h similarity index 61% rename from ios/RCTMGL/RCTMGLCalloutManager.h rename to ios/RCTMLN/RCTMLNCalloutManager.h index f2dbbecbc..d6d7f6109 100644 --- a/ios/RCTMGL/RCTMGLCalloutManager.h +++ b/ios/RCTMLN/RCTMLNCalloutManager.h @@ -1,6 +1,6 @@ // -// RCTMGLCalloutViewManager.h -// RCTMGL +// RCTMLNCalloutViewManager.h +// RCTMLN // // Created by Nick Italiano on 10/13/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLCalloutManager : ViewManager +@interface RCTMLNCalloutManager : ViewManager @end diff --git a/ios/RCTMLN/RCTMLNCalloutManager.m b/ios/RCTMLN/RCTMLNCalloutManager.m new file mode 100644 index 000000000..c56714466 --- /dev/null +++ b/ios/RCTMLN/RCTMLNCalloutManager.m @@ -0,0 +1,21 @@ +// +// RCTMLNCalloutViewManager.m +// RCTMLN +// +// Created by Nick Italiano on 10/13/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import "RCTMLNCalloutManager.h" +#import "RCTMLNCallout.h" + +@implementation RCTMLNCalloutManager + +RCT_EXPORT_MODULE() + +- (UIView *)view +{ + return [[RCTMLNCallout alloc] init]; +} + +@end diff --git a/ios/RCTMGL/RCTMGLCamera.h b/ios/RCTMLN/RCTMLNCamera.h similarity index 85% rename from ios/RCTMGL/RCTMGLCamera.h rename to ios/RCTMLN/RCTMLNCamera.h index 8fb6c8ce3..5b84f148c 100644 --- a/ios/RCTMGL/RCTMGLCamera.h +++ b/ios/RCTMLN/RCTMLNCamera.h @@ -1,21 +1,21 @@ // -// RCTMGLCamera.h -// RCTMGL +// RCTMLNCamera.h +// RCTMLN // // Created by Nick Italiano on 6/22/18. // Copyright © 2018 Mapbox Inc. All rights reserved. // #import #import -#import "RCTMGLMapView.h" +#import "RCTMLNMapView.h" -@class RCTMGLMapView; +@class RCTMLNMapView; -@interface RCTMGLCamera : UIView +@interface RCTMLNCamera : UIView @property (nonatomic, strong) NSDictionary *stop; @property (nonatomic, strong) NSDictionary *defaultStop; -@property (nonatomic, strong) RCTMGLMapView *map; +@property (nonatomic, strong) RCTMLNMapView *map; @property (nonatomic, copy) NSNumber *animationDuration; @property (nonatomic, copy) NSString *animationMode; diff --git a/ios/RCTMGL/RCTMGLCamera.m b/ios/RCTMLN/RCTMLNCamera.m similarity index 78% rename from ios/RCTMGL/RCTMGLCamera.m rename to ios/RCTMLN/RCTMLNCamera.m index ddf3d0127..876590ead 100644 --- a/ios/RCTMGL/RCTMGLCamera.m +++ b/ios/RCTMLN/RCTMLNCamera.m @@ -1,25 +1,25 @@ // -// RCTMGLCamera.m -// RCTMGL +// RCTMLNCamera.m +// RCTMLN // // Created by Nick Italiano on 6/22/18. // Copyright © 2018 Mapbox Inc. All rights reserved. // -#import "RCTMGLCamera.h" +#import "RCTMLNCamera.h" #import "CameraStop.h" #import "CameraUpdateQueue.h" -#import "RCTMGLLocation.h" -#import "RCTMGLUtils.h" -#import "RCTMGLLocationManager.h" -#import "RCTMGLEvent.h" -#import "RCTMGLEventTypes.h" +#import "RCTMLNLocation.h" +#import "RCTMLNUtils.h" +#import "RCTMLNLocationManager.h" +#import "RCTMLNEvent.h" +#import "RCTMLNEventTypes.h" #import "CameraMode.h" -@implementation RCTMGLCamera +@implementation RCTMLNCamera { CameraUpdateQueue *cameraUpdateQueue; - RCTMGLCamera *followCamera; + RCTMLNCamera *followCamera; } - (instancetype)init @@ -63,7 +63,7 @@ - (void)setStop:(NSDictionary *)stop [self _updateCamera]; } -- (void)setMap:(RCTMGLMapView *)map +- (void)setMap:(RCTMLNMapView *)map { if (_map != nil) { _map.reactCamera = nil; @@ -117,8 +117,8 @@ - (void)_updateCameraFromJavascript return; } - if (_map != nil && _map.userTrackingMode != MGLUserTrackingModeNone) { - _map.userTrackingMode = MGLUserTrackingModeNone; + if (_map != nil && _map.userTrackingMode != MLNUserTrackingModeNone) { + _map.userTrackingMode = MLNUserTrackingModeNone; } if (_stop[@"stops"]) { NSArray* stops = _stop[@"stops"]; @@ -172,7 +172,7 @@ - (void)_updateMaxBounds { if (_map != nil) { if (_maxBounds) { - _map.maxBounds = [RCTMGLUtils fromFeatureCollection:_maxBounds]; + _map.maxBounds = [RCTMLNUtils fromFeatureCollection:_maxBounds]; } } } @@ -183,23 +183,23 @@ - (void)_updateCameraFromTrackingMode return; } if (!_followUserLocation) { - _map.userTrackingMode = MGLUserTrackingModeNone; + _map.userTrackingMode = MLNUserTrackingModeNone; return; } if (_map.userTrackingMode != [self _userTrackingMode]) { - _map.showsUserLocation = [self _userTrackingMode] != MGLUserTrackingModeNone; + _map.showsUserLocation = [self _userTrackingMode] != MLNUserTrackingModeNone; _map.userTrackingMode = [self _userTrackingMode]; } - MGLMapCamera *camera = _map.camera; + MLNMapCamera *camera = _map.camera; if (_followPitch != nil && [_followPitch floatValue] >= 0.0) { camera.pitch = [_followPitch floatValue]; } else if (_stop != nil && _stop[@"pitch"] != nil) { camera.pitch = [_stop[@"pitch"] floatValue]; } - if ([self _userTrackingMode] != MGLUserTrackingModeFollowWithCourse && [self _userTrackingMode] != MGLUserTrackingModeFollowWithHeading) { + if ([self _userTrackingMode] != MLNUserTrackingModeFollowWithCourse && [self _userTrackingMode] != MLNUserTrackingModeFollowWithHeading) { if (_followHeading != nil && [_followHeading floatValue] >= 0.0) { camera.heading = [_followHeading floatValue]; } else if (_stop != nil && _stop[@"heading"] != nil) { @@ -217,25 +217,25 @@ - (void)_updateCameraFromTrackingMode - (NSUInteger)_userTrackingMode { if ([_followUserMode isEqualToString:@"compass"]) { - return MGLUserTrackingModeFollowWithHeading; + return MLNUserTrackingModeFollowWithHeading; } else if ([_followUserMode isEqualToString:@"course"]) { - return MGLUserTrackingModeFollowWithCourse; + return MLNUserTrackingModeFollowWithCourse; } else if (_followUserLocation) { - return MGLUserTrackingModeFollow; + return MLNUserTrackingModeFollow; } else { - return MGLUserTrackingModeNone; + return MLNUserTrackingModeNone; } } -- (NSString*)_trackingModeToString:(MGLUserTrackingMode) mode { +- (NSString*)_trackingModeToString:(MLNUserTrackingMode) mode { switch (mode) { - case MGLUserTrackingModeFollowWithHeading: + case MLNUserTrackingModeFollowWithHeading: return @"compass"; - case MGLUserTrackingModeFollowWithCourse: + case MLNUserTrackingModeFollowWithCourse: return @"course"; - case MGLUserTrackingModeFollow: + case MLNUserTrackingModeFollow: return @"normal"; - case MGLUserTrackingModeNone: + case MLNUserTrackingModeNone: return [NSNull null]; } } @@ -246,10 +246,10 @@ - (void)initialLayout [self _updateCamera]; } -- (void)didChangeUserTrackingMode:(MGLUserTrackingMode)mode animated:(BOOL)animated +- (void)didChangeUserTrackingMode:(MLNUserTrackingMode)mode animated:(BOOL)animated { - NSDictionary *payload = @{ @"followUserMode": [self _trackingModeToString: mode], @"followUserLocation": @((BOOL)(mode != MGLUserTrackingModeNone)) }; - RCTMGLEvent *event = [RCTMGLEvent makeEvent:RCT_MAPBOX_USER_TRACKING_MODE_CHANGE withPayload:payload]; + NSDictionary *payload = @{ @"followUserMode": [self _trackingModeToString: mode], @"followUserLocation": @((BOOL)(mode != MLNUserTrackingModeNone)) }; + RCTMLNEvent *event = [RCTMLNEvent makeEvent:RCT_MAPBOX_USER_TRACKING_MODE_CHANGE withPayload:payload]; if (_onUserTrackingModeChange) { _onUserTrackingModeChange([event toJSON]); } diff --git a/ios/RCTMGL/RCTMGLCameraManager.h b/ios/RCTMLN/RCTMLNCameraManager.h similarity index 62% rename from ios/RCTMGL/RCTMGLCameraManager.h rename to ios/RCTMLN/RCTMLNCameraManager.h index 8b9ef9a01..ae7d74db9 100644 --- a/ios/RCTMGL/RCTMGLCameraManager.h +++ b/ios/RCTMLN/RCTMLNCameraManager.h @@ -1,6 +1,6 @@ // -// RCTMGLCameraManager.h -// RCTMGL +// RCTMLNCameraManager.h +// RCTMLN // // Created by Nick Italiano on 6/22/18. // Copyright © 2018 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLCameraManager : ViewManager +@interface RCTMLNCameraManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLCameraManager.m b/ios/RCTMLN/RCTMLNCameraManager.m similarity index 82% rename from ios/RCTMGL/RCTMGLCameraManager.m rename to ios/RCTMLN/RCTMLNCameraManager.m index cbfc22c8e..64dd79e11 100644 --- a/ios/RCTMGL/RCTMGLCameraManager.m +++ b/ios/RCTMLN/RCTMLNCameraManager.m @@ -1,17 +1,17 @@ // -// RCTMGLCameraManager.m -// RCTMGL +// RCTMLNCameraManager.m +// RCTMLN // // Created by Nick Italiano on 6/22/18. // Copyright © 2018 Mapbox Inc. All rights reserved. // -#import "RCTMGLCameraManager.h" -#import "RCTMGLCamera.h" +#import "RCTMLNCameraManager.h" +#import "RCTMLNCamera.h" -@implementation RCTMGLCameraManager +@implementation RCTMLNCameraManager -RCT_EXPORT_MODULE(RCTMGLCamera) +RCT_EXPORT_MODULE(RCTMLNCamera) #pragma - View Properties @@ -46,7 +46,7 @@ - (BOOL)requiresMainQueueSetup - (UIView *)view { - return [[RCTMGLCamera alloc] init]; + return [[RCTMLNCamera alloc] init]; } @end diff --git a/ios/RCTMLN/RCTMLNCircleLayer.h b/ios/RCTMLN/RCTMLNCircleLayer.h new file mode 100644 index 000000000..191f59b9d --- /dev/null +++ b/ios/RCTMLN/RCTMLNCircleLayer.h @@ -0,0 +1,13 @@ +// +// RCTMLNCircleLayer.h +// RCTMLN +// +// Created by Nick Italiano on 9/18/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import "RCTMLNVectorLayer.h" + +@interface RCTMLNCircleLayer : RCTMLNVectorLayer + +@end diff --git a/ios/RCTMGL/RCTMGLCircleLayer.m b/ios/RCTMLN/RCTMLNCircleLayer.m similarity index 50% rename from ios/RCTMGL/RCTMGLCircleLayer.m rename to ios/RCTMLN/RCTMLNCircleLayer.m index 055bf47e5..f114dabd0 100644 --- a/ios/RCTMGL/RCTMGLCircleLayer.m +++ b/ios/RCTMLN/RCTMLNCircleLayer.m @@ -1,32 +1,32 @@ // -// RCTMGLCircleLayer.m -// RCTMGL +// RCTMLNCircleLayer.m +// RCTMLN // // Created by Nick Italiano on 9/18/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLCircleLayer.h" -#import "RCTMGLStyle.h" +#import "RCTMLNCircleLayer.h" +#import "RCTMLNStyle.h" #import -@implementation RCTMGLCircleLayer +@implementation RCTMLNCircleLayer -- (MGLCircleStyleLayer*)makeLayer:(MGLStyle*)style +- (MLNCircleStyleLayer*)makeLayer:(MLNStyle*)style { - MGLSource *source = [self layerWithSourceIDInStyle:style]; + MLNSource *source = [self layerWithSourceIDInStyle:style]; if (source == nil) { return nil; } - MGLCircleStyleLayer *layer = [[MGLCircleStyleLayer alloc] initWithIdentifier:self.id source:source]; + MLNCircleStyleLayer *layer = [[MLNCircleStyleLayer alloc] initWithIdentifier:self.id source:source]; layer.sourceLayerIdentifier = self.sourceLayerID; return layer; } - (void)addStyles { - RCTMGLStyle *style = [[RCTMGLStyle alloc] initWithMGLStyle:self.style]; + RCTMLNStyle *style = [[RCTMLNStyle alloc] initWithMLNStyle:self.style]; style.bridge = self.bridge; - [style circleLayer:(MGLCircleStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ + [style circleLayer:(MLNCircleStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; }]; } diff --git a/ios/RCTMGL/RCTMGLCircleLayerManager.h b/ios/RCTMLN/RCTMLNCircleLayerManager.h similarity index 59% rename from ios/RCTMGL/RCTMGLCircleLayerManager.h rename to ios/RCTMLN/RCTMLNCircleLayerManager.h index 09929d190..e18234dad 100644 --- a/ios/RCTMGL/RCTMGLCircleLayerManager.h +++ b/ios/RCTMLN/RCTMLNCircleLayerManager.h @@ -1,6 +1,6 @@ // -// RCTMGLCircleLayerManager.h -// RCTMGL +// RCTMLNCircleLayerManager.h +// RCTMLN // // Created by Nick Italiano on 9/18/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLCircleLayerManager : ViewManager +@interface RCTMLNCircleLayerManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLCircleLayerManager.m b/ios/RCTMLN/RCTMLNCircleLayerManager.m similarity index 78% rename from ios/RCTMGL/RCTMGLCircleLayerManager.m rename to ios/RCTMLN/RCTMLNCircleLayerManager.m index b8e6b5abf..86d8a1e0e 100644 --- a/ios/RCTMGL/RCTMGLCircleLayerManager.m +++ b/ios/RCTMLN/RCTMLNCircleLayerManager.m @@ -1,15 +1,15 @@ // -// RCTMGLCircleLayerManager.m -// RCTMGL +// RCTMLNCircleLayerManager.m +// RCTMLN // // Created by Nick Italiano on 9/18/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLCircleLayerManager.h" -#import "RCTMGLCircleLayer.h" +#import "RCTMLNCircleLayerManager.h" +#import "RCTMLNCircleLayer.h" -@implementation RCTMGLCircleLayerManager +@implementation RCTMLNCircleLayerManager RCT_EXPORT_MODULE() @@ -31,7 +31,7 @@ @implementation RCTMGLCircleLayerManager - (UIView*)view { - RCTMGLCircleLayer *layer = [RCTMGLCircleLayer new]; + RCTMLNCircleLayer *layer = [RCTMLNCircleLayer new]; layer.bridge = self.bridge; return layer; } diff --git a/ios/RCTMGL/RCTMGLEvent.h b/ios/RCTMLN/RCTMLNEvent.h similarity index 58% rename from ios/RCTMGL/RCTMGLEvent.h rename to ios/RCTMLN/RCTMLNEvent.h index 3433558b1..4ef971f5e 100644 --- a/ios/RCTMGL/RCTMGLEvent.h +++ b/ios/RCTMLN/RCTMLNEvent.h @@ -1,21 +1,21 @@ // -// RCTMGLEvent.h -// RCTMGL +// RCTMLNEvent.h +// RCTMLN // // Created by Nick Italiano on 8/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -#import "RCTMGLEventProtocol.h" +#import "RCTMLNEventProtocol.h" -@interface RCTMGLEvent : NSObject +@interface RCTMLNEvent : NSObject @property (nonatomic, copy) NSString *type; @property (nonatomic, strong) NSDictionary *payload; @property (nonatomic, readonly) NSTimeInterval timestamp; -+ (RCTMGLEvent*)makeEvent:(NSString*)eventType; -+ (RCTMGLEvent*)makeEvent:(NSString*)eventType withPayload:(NSDictionary*)payload; ++ (RCTMLNEvent*)makeEvent:(NSString*)eventType; ++ (RCTMLNEvent*)makeEvent:(NSString*)eventType withPayload:(NSDictionary*)payload; @end diff --git a/ios/RCTMGL/RCTMGLEvent.m b/ios/RCTMLN/RCTMLNEvent.m similarity index 64% rename from ios/RCTMGL/RCTMGLEvent.m rename to ios/RCTMLN/RCTMLNEvent.m index 662c92713..62a401a3c 100644 --- a/ios/RCTMGL/RCTMGLEvent.m +++ b/ios/RCTMLN/RCTMLNEvent.m @@ -1,14 +1,14 @@ // -// RCTMGLEvent.m -// RCTMGL +// RCTMLNEvent.m +// RCTMLN // // Created by Nick Italiano on 8/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLEvent.h" +#import "RCTMLNEvent.h" -@implementation RCTMGLEvent +@implementation RCTMLNEvent - (instancetype)init { @@ -31,14 +31,14 @@ - (NSDictionary*)toJSON return @{ @"type": self.type, @"payload": self.payload }; } -+ (RCTMGLEvent*)makeEvent:(NSString*)type ++ (RCTMLNEvent*)makeEvent:(NSString*)type { - return [RCTMGLEvent makeEvent:type withPayload:@{}]; + return [RCTMLNEvent makeEvent:type withPayload:@{}]; } -+ (RCTMGLEvent*)makeEvent:(NSString*)type withPayload:(NSDictionary*)payload ++ (RCTMLNEvent*)makeEvent:(NSString*)type withPayload:(NSDictionary*)payload { - RCTMGLEvent *event = [[RCTMGLEvent alloc] init]; + RCTMLNEvent *event = [[RCTMLNEvent alloc] init]; event.type = type; event.payload = payload; return event; diff --git a/ios/RCTMGL/RCTMGLEventProtocol.h b/ios/RCTMLN/RCTMLNEventProtocol.h similarity index 77% rename from ios/RCTMGL/RCTMGLEventProtocol.h rename to ios/RCTMLN/RCTMLNEventProtocol.h index d6f7c7792..23c5715e3 100644 --- a/ios/RCTMGL/RCTMGLEventProtocol.h +++ b/ios/RCTMLN/RCTMLNEventProtocol.h @@ -1,12 +1,12 @@ // -// RCTMGLEvent.h -// RCTMGL +// RCTMLNEvent.h +// RCTMLN // // Created by Nick Italiano on 8/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -@protocol RCTMGLEventProtocol +@protocol RCTMLNEventProtocol @property (nonatomic, copy) NSString *type; @property (nonatomic, strong) NSDictionary *payload; diff --git a/ios/RCTMGL/RCTMGLEventTypes.h b/ios/RCTMLN/RCTMLNEventTypes.h similarity index 95% rename from ios/RCTMGL/RCTMGLEventTypes.h rename to ios/RCTMLN/RCTMLNEventTypes.h index 81d463b9a..120599648 100644 --- a/ios/RCTMGL/RCTMGLEventTypes.h +++ b/ios/RCTMLN/RCTMLNEventTypes.h @@ -1,6 +1,6 @@ // -// RCTMGLEventTypes.h -// RCTMGL +// RCTMLNEventTypes.h +// RCTMLN // // Created by Nick Italiano on 8/27/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,7 +8,7 @@ #import -@interface RCTMGLEventTypes : NSObject +@interface RCTMLNEventTypes : NSObject extern NSString *const RCT_MAPBOX_EVENT_TAP; extern NSString *const RCT_MAPBOX_EVENT_LONGPRESS; diff --git a/ios/RCTMGL/RCTMGLEventTypes.m b/ios/RCTMLN/RCTMLNEventTypes.m similarity index 95% rename from ios/RCTMGL/RCTMGLEventTypes.m rename to ios/RCTMLN/RCTMLNEventTypes.m index cc48538b2..b416d0c03 100644 --- a/ios/RCTMGL/RCTMGLEventTypes.m +++ b/ios/RCTMLN/RCTMLNEventTypes.m @@ -1,14 +1,14 @@ // -// RCTMGLEventTypes.m -// RCTMGL +// RCTMLNEventTypes.m +// RCTMLN // // Created by Nick Italiano on 8/27/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLEventTypes.h" +#import "RCTMLNEventTypes.h" -@implementation RCTMGLEventTypes +@implementation RCTMLNEventTypes NSString *const RCT_MAPBOX_EVENT_TAP = @"press"; NSString *const RCT_MAPBOX_EVENT_LONGPRESS = @"longpress"; diff --git a/ios/RCTMLN/RCTMLNFillExtrusionLayer.h b/ios/RCTMLN/RCTMLNFillExtrusionLayer.h new file mode 100644 index 000000000..a8a19e9ce --- /dev/null +++ b/ios/RCTMLN/RCTMLNFillExtrusionLayer.h @@ -0,0 +1,14 @@ +// +// RCTMLNFillExtrusionLayer.h +// RCTMLN +// +// Created by Nick Italiano on 9/15/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import "RCTMLNVectorLayer.h" +@import MapLibre; + +@interface RCTMLNFillExtrusionLayer : RCTMLNVectorLayer + +@end diff --git a/ios/RCTMGL/RCTMGLFillExtrusionLayer.m b/ios/RCTMLN/RCTMLNFillExtrusionLayer.m similarity index 50% rename from ios/RCTMGL/RCTMGLFillExtrusionLayer.m rename to ios/RCTMLN/RCTMLNFillExtrusionLayer.m index d152e67bb..696bc3308 100644 --- a/ios/RCTMGL/RCTMGLFillExtrusionLayer.m +++ b/ios/RCTMLN/RCTMLNFillExtrusionLayer.m @@ -1,31 +1,31 @@ // -// RCTMGLFillExtrusionLayer.m -// RCTMGL +// RCTMLNFillExtrusionLayer.m +// RCTMLN // // Created by Nick Italiano on 9/15/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLFillExtrusionLayer.h" -#import "RCTMGLStyle.h" +#import "RCTMLNFillExtrusionLayer.h" +#import "RCTMLNStyle.h" #import -@implementation RCTMGLFillExtrusionLayer +@implementation RCTMLNFillExtrusionLayer -- (MGLFillExtrusionStyleLayer*)makeLayer:(MGLStyle*)style +- (MLNFillExtrusionStyleLayer*)makeLayer:(MLNStyle*)style { - MGLSource *source = [self layerWithSourceIDInStyle:style]; + MLNSource *source = [self layerWithSourceIDInStyle:style]; if (source == nil) { return nil; } - MGLFillExtrusionStyleLayer *layer = [[MGLFillExtrusionStyleLayer alloc] initWithIdentifier:self.id source:source]; + MLNFillExtrusionStyleLayer *layer = [[MLNFillExtrusionStyleLayer alloc] initWithIdentifier:self.id source:source]; layer.sourceLayerIdentifier = self.sourceLayerID; return layer; } - (void)addStyles { - RCTMGLStyle *style = [[RCTMGLStyle alloc] initWithMGLStyle:self.style]; + RCTMLNStyle *style = [[RCTMLNStyle alloc] initWithMLNStyle:self.style]; style.bridge = self.bridge; - [style fillExtrusionLayer:(MGLFillExtrusionStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; + [style fillExtrusionLayer:(MLNFillExtrusionStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; }]; } diff --git a/ios/RCTMGL/RCTMGLFillExtrusionLayerManager.h b/ios/RCTMLN/RCTMLNFillExtrusionLayerManager.h similarity index 56% rename from ios/RCTMGL/RCTMGLFillExtrusionLayerManager.h rename to ios/RCTMLN/RCTMLNFillExtrusionLayerManager.h index 7da8b635b..e7d5b7bb3 100644 --- a/ios/RCTMGL/RCTMGLFillExtrusionLayerManager.h +++ b/ios/RCTMLN/RCTMLNFillExtrusionLayerManager.h @@ -1,6 +1,6 @@ // -// RCTMGLFillExtrusionLayerManager.h -// RCTMGL +// RCTMLNFillExtrusionLayerManager.h +// RCTMLN // // Created by Nick Italiano on 9/15/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLFillExtrusionLayerManager : ViewManager +@interface RCTMLNFillExtrusionLayerManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLFillExtrusionLayerManager.m b/ios/RCTMLN/RCTMLNFillExtrusionLayerManager.m similarity index 75% rename from ios/RCTMGL/RCTMGLFillExtrusionLayerManager.m rename to ios/RCTMLN/RCTMLNFillExtrusionLayerManager.m index 927f65ee0..a35eee1c4 100644 --- a/ios/RCTMGL/RCTMGLFillExtrusionLayerManager.m +++ b/ios/RCTMLN/RCTMLNFillExtrusionLayerManager.m @@ -1,15 +1,15 @@ // -// RCTMGLFillExtrusionLayerManager.m -// RCTMGL +// RCTMLNFillExtrusionLayerManager.m +// RCTMLN // // Created by Nick Italiano on 9/15/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLFillExtrusionLayerManager.h" -#import "RCTMGLFillExtrusionLayer.h" +#import "RCTMLNFillExtrusionLayerManager.h" +#import "RCTMLNFillExtrusionLayer.h" -@implementation RCTMGLFillExtrusionLayerManager +@implementation RCTMLNFillExtrusionLayerManager RCT_EXPORT_MODULE() @@ -31,7 +31,7 @@ @implementation RCTMGLFillExtrusionLayerManager - (UIView*)view { - RCTMGLFillExtrusionLayer *layer = [RCTMGLFillExtrusionLayer new]; + RCTMLNFillExtrusionLayer *layer = [RCTMLNFillExtrusionLayer new]; layer.bridge = self.bridge; return layer; } diff --git a/ios/RCTMLN/RCTMLNFillLayer.h b/ios/RCTMLN/RCTMLNFillLayer.h new file mode 100644 index 000000000..d33915b83 --- /dev/null +++ b/ios/RCTMLN/RCTMLNFillLayer.h @@ -0,0 +1,14 @@ +// +// RCTMLNFillLayer.h +// RCTMLN +// +// Created by Nick Italiano on 9/8/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import "RCTMLNVectorLayer.h" +@import MapLibre; + +@interface RCTMLNFillLayer : RCTMLNVectorLayer + +@end diff --git a/ios/RCTMGL/RCTMGLFillLayer.m b/ios/RCTMLN/RCTMLNFillLayer.m similarity index 51% rename from ios/RCTMGL/RCTMGLFillLayer.m rename to ios/RCTMLN/RCTMLNFillLayer.m index 985b5a237..8561007da 100644 --- a/ios/RCTMGL/RCTMGLFillLayer.m +++ b/ios/RCTMLN/RCTMLNFillLayer.m @@ -1,31 +1,31 @@ // -// RCTMGLFillLayer.m -// RCTMGL +// RCTMLNFillLayer.m +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLFillLayer.h" -#import "RCTMGLStyle.h" +#import "RCTMLNFillLayer.h" +#import "RCTMLNStyle.h" #import -@implementation RCTMGLFillLayer +@implementation RCTMLNFillLayer -- (MGLStyleLayer*)makeLayer:(MGLStyle*)style +- (MLNStyleLayer*)makeLayer:(MLNStyle*)style { - MGLSource *source = [self layerWithSourceIDInStyle:style]; + MLNSource *source = [self layerWithSourceIDInStyle:style]; if (source == nil) { return nil; } - MGLFillStyleLayer *layer = [[MGLFillStyleLayer alloc] initWithIdentifier:self.id source:source]; + MLNFillStyleLayer *layer = [[MLNFillStyleLayer alloc] initWithIdentifier:self.id source:source]; layer.sourceLayerIdentifier = self.sourceLayerID; return layer; } - (void)addStyles { - RCTMGLStyle *style = [[RCTMGLStyle alloc] initWithMGLStyle:self.style]; + RCTMLNStyle *style = [[RCTMLNStyle alloc] initWithMLNStyle:self.style]; style.bridge = self.bridge; - [style fillLayer:(MGLFillStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ + [style fillLayer:(MLNFillStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; }]; } diff --git a/ios/RCTMGL/RCTMGLFillLayerManager.h b/ios/RCTMLN/RCTMLNFillLayerManager.h similarity index 60% rename from ios/RCTMGL/RCTMGLFillLayerManager.h rename to ios/RCTMLN/RCTMLNFillLayerManager.h index 937bd2663..68d4a34b5 100644 --- a/ios/RCTMGL/RCTMGLFillLayerManager.h +++ b/ios/RCTMLN/RCTMLNFillLayerManager.h @@ -1,6 +1,6 @@ // -// RCTMGLFillLayerManager.h -// RCTMGL +// RCTMLNFillLayerManager.h +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLFillLayerManager : ViewManager +@interface RCTMLNFillLayerManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLFillLayerManager.m b/ios/RCTMLN/RCTMLNFillLayerManager.m similarity index 78% rename from ios/RCTMGL/RCTMGLFillLayerManager.m rename to ios/RCTMLN/RCTMLNFillLayerManager.m index 84556a47a..268f80312 100644 --- a/ios/RCTMGL/RCTMGLFillLayerManager.m +++ b/ios/RCTMLN/RCTMLNFillLayerManager.m @@ -1,15 +1,15 @@ // -// RCTMGLFillLayerManager.m -// RCTMGL +// RCTMLNFillLayerManager.m +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLFillLayerManager.h" -#import "RCTMGLFillLayer.h" +#import "RCTMLNFillLayerManager.h" +#import "RCTMLNFillLayer.h" -@implementation RCTMGLFillLayerManager +@implementation RCTMLNFillLayerManager RCT_EXPORT_MODULE(); @@ -29,7 +29,7 @@ @implementation RCTMGLFillLayerManager - (UIView*)view { - RCTMGLFillLayer *layer = [RCTMGLFillLayer new]; + RCTMLNFillLayer *layer = [RCTMLNFillLayer new]; layer.bridge = self.bridge; return layer; } diff --git a/ios/RCTMLN/RCTMLNHeatmapLayer.h b/ios/RCTMLN/RCTMLNHeatmapLayer.h new file mode 100644 index 000000000..30c997cda --- /dev/null +++ b/ios/RCTMLN/RCTMLNHeatmapLayer.h @@ -0,0 +1,12 @@ +// +// RCTMLNHeatmapLayer.h +// RCTMLN +// +// Created by Dheeraj Yalamanchili on 6/8/19. +// + +#import "RCTMLNVectorLayer.h" + +@interface RCTMLNHeatmapLayer : RCTMLNVectorLayer + +@end diff --git a/ios/RCTMLN/RCTMLNHeatmapLayer.m b/ios/RCTMLN/RCTMLNHeatmapLayer.m new file mode 100644 index 000000000..1b142c674 --- /dev/null +++ b/ios/RCTMLN/RCTMLNHeatmapLayer.m @@ -0,0 +1,30 @@ +// +// RCTMLNHeatmapLayer.m +// RCTMLN +// +// Created by Dheeraj Yalamanchili on 6/8/2019 + +#import "RCTMLNHeatmapLayer.h" +#import "RCTMLNStyle.h" + +@implementation RCTMLNHeatmapLayer + +- (MLNHeatmapStyleLayer*)makeLayer:(MLNStyle*)style +{ + MLNSource *source = [self layerWithSourceIDInStyle:style]; + if (source == nil) { return nil; } + MLNHeatmapStyleLayer *layer = [[MLNHeatmapStyleLayer alloc] initWithIdentifier:self.id source:source]; + layer.sourceLayerIdentifier = self.sourceLayerID; + return layer; +} + +- (void)addStyles +{ + RCTMLNStyle *style = [[RCTMLNStyle alloc] initWithMLNStyle:self.style]; + style.bridge = self.bridge; + [style heatmapLayer:(MLNHeatmapStyleLayer *)self.styleLayer withReactStyle:self.reactStyle isValid:^{ + return [self isAddedToMap]; + }]; +} + +@end diff --git a/ios/RCTMLN/RCTMLNHeatmapLayerManager.h b/ios/RCTMLN/RCTMLNHeatmapLayerManager.h new file mode 100644 index 000000000..427d4066b --- /dev/null +++ b/ios/RCTMLN/RCTMLNHeatmapLayerManager.h @@ -0,0 +1,12 @@ +// +// RCTMLNHeatmapLayerManager.h +// RCTMLN +// +// Created by Dheeraj Yalamanchili on 6/8/19. +// + +#import "ViewManager.h" + +@interface RCTMLNHeatmapLayerManager : ViewManager + +@end diff --git a/ios/RCTMGL/RCTMGLHeatmapLayerManager.m b/ios/RCTMLN/RCTMLNHeatmapLayerManager.m similarity index 76% rename from ios/RCTMGL/RCTMGLHeatmapLayerManager.m rename to ios/RCTMLN/RCTMLNHeatmapLayerManager.m index 17ef6d1f2..974eb5a64 100644 --- a/ios/RCTMGL/RCTMGLHeatmapLayerManager.m +++ b/ios/RCTMLN/RCTMLNHeatmapLayerManager.m @@ -1,14 +1,14 @@ // -// RCTMGLHeatmapLayerManager.m -// RCTMGL +// RCTMLNHeatmapLayerManager.m +// RCTMLN // // Created by Dheeraj Yalamanchili on 6/8/19. // -#import "RCTMGLHeatmapLayerManager.h" -#import "RCTMGLHeatmapLayer.h" +#import "RCTMLNHeatmapLayerManager.h" +#import "RCTMLNHeatmapLayer.h" -@implementation RCTMGLHeatmapLayerManager +@implementation RCTMLNHeatmapLayerManager RCT_EXPORT_MODULE() @@ -30,7 +30,7 @@ @implementation RCTMGLHeatmapLayerManager - (UIView*)view { - RCTMGLHeatmapLayer *layer = [RCTMGLHeatmapLayer new]; + RCTMLNHeatmapLayer *layer = [RCTMLNHeatmapLayer new]; layer.bridge = self.bridge; return layer; } diff --git a/ios/RCTMGL/RCTMGLImageQueue.h b/ios/RCTMLN/RCTMLNImageQueue.h similarity index 84% rename from ios/RCTMGL/RCTMGLImageQueue.h rename to ios/RCTMLN/RCTMLNImageQueue.h index 5a1bb8e00..85526bc84 100644 --- a/ios/RCTMGL/RCTMGLImageQueue.h +++ b/ios/RCTMLN/RCTMLNImageQueue.h @@ -1,6 +1,6 @@ // -// RCTMGLImageQueue.h -// RCTMGL +// RCTMLNImageQueue.h +// RCTMLN // // Created by Nick Italiano on 10/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -9,7 +9,7 @@ #import #import -@interface RCTMGLImageQueue : NSObject +@interface RCTMLNImageQueue : NSObject + (instancetype)sharedInstance; diff --git a/ios/RCTMGL/RCTMGLImageQueue.m b/ios/RCTMLN/RCTMLNImageQueue.m similarity index 69% rename from ios/RCTMGL/RCTMGLImageQueue.m rename to ios/RCTMLN/RCTMLNImageQueue.m index 47a58e71d..282bbede6 100644 --- a/ios/RCTMGL/RCTMGLImageQueue.m +++ b/ios/RCTMLN/RCTMLNImageQueue.m @@ -1,16 +1,16 @@ // -// RCTMGLImageQueue.m -// RCTMGL +// RCTMLNImageQueue.m +// RCTMLN // // Created by Nick Italiano on 10/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLImageQueue.h" -#import "RCTMGLImageQueueOperation.h" -#import "RCTMGLUtils.h" +#import "RCTMLNImageQueue.h" +#import "RCTMLNImageQueueOperation.h" +#import "RCTMLNUtils.h" -@implementation RCTMGLImageQueue +@implementation RCTMLNImageQueue { NSOperationQueue *imageQueue; } @@ -19,7 +19,7 @@ - (id)init { if (self = [super init]) { imageQueue = [[NSOperationQueue alloc] init]; - imageQueue.name = @"com.mapbox.rctmgl.DownloadImageQueue"; + imageQueue.name = @"com.maplibre.rctmln.DownloadImageQueue"; } return self; } @@ -31,10 +31,10 @@ - (void)dealloc + (instancetype)sharedInstance { - static RCTMGLImageQueue *sharedInstance = nil; + static RCTMLNImageQueue *sharedInstance = nil; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ - sharedInstance = [[RCTMGLImageQueue alloc] init]; + sharedInstance = [[RCTMLNImageQueue alloc] init]; }); return sharedInstance; } @@ -46,7 +46,7 @@ - (void)cancelAllOperations - (void)addImage:(NSString *)imageURL scale:(double)scale bridge:(RCTBridge *)bridge completionHandler:(RCTImageLoaderCompletionBlock)handler { - RCTMGLImageQueueOperation *operation = [[RCTMGLImageQueueOperation alloc] init]; + RCTMLNImageQueueOperation *operation = [[RCTMLNImageQueueOperation alloc] init]; operation.bridge = bridge; operation.urlRequest = [RCTConvert NSURLRequest:imageURL]; operation.completionHandler = handler; diff --git a/ios/RCTMGL/RCTMGLImageQueueOperation.h b/ios/RCTMLN/RCTMLNImageQueueOperation.h similarity index 78% rename from ios/RCTMGL/RCTMGLImageQueueOperation.h rename to ios/RCTMLN/RCTMLNImageQueueOperation.h index 6b30f3027..42334ac70 100644 --- a/ios/RCTMGL/RCTMGLImageQueueOperation.h +++ b/ios/RCTMLN/RCTMLNImageQueueOperation.h @@ -1,13 +1,13 @@ // -// RCTMGLImageQueueOperation.h -// RCTMGL +// RCTMLNImageQueueOperation.h +// RCTMLN // // Created by Nick Italiano on 2/28/18. // Copyright © 2018 Mapbox Inc. All rights reserved. // #import -@interface RCTMGLImageQueueOperation : NSBlockOperation +@interface RCTMLNImageQueueOperation : NSBlockOperation @property (nonatomic, weak) RCTBridge *bridge; @property (nonatomic, copy) RCTImageLoaderCompletionBlock completionHandler; diff --git a/ios/RCTMGL/RCTMGLImageQueueOperation.m b/ios/RCTMLN/RCTMLNImageQueueOperation.m similarity index 79% rename from ios/RCTMGL/RCTMGLImageQueueOperation.m rename to ios/RCTMLN/RCTMLNImageQueueOperation.m index 49029f7a0..c576f657d 100644 --- a/ios/RCTMGL/RCTMGLImageQueueOperation.m +++ b/ios/RCTMLN/RCTMLNImageQueueOperation.m @@ -1,15 +1,15 @@ // -// RCTMGLImageQueueOperation.m -// RCTMGL +// RCTMLNImageQueueOperation.m +// RCTMLN // // Created by Nick Italiano on 2/28/18. // Copyright © 2018 Mapbox Inc. All rights reserved. // -#import "RCTMGLImageQueueOperation.h" +#import "RCTMLNImageQueueOperation.h" -typedef NS_ENUM(NSInteger, RCTMGLImageQueueOperationState) { +typedef NS_ENUM(NSInteger, RCTMLNImageQueueOperationState) { IOState_Initial, IOState_CancelledDoNotExecute, IOState_Executing, // cancellationBlock is set @@ -20,11 +20,11 @@ typedef NS_ENUM(NSInteger, RCTMGLImageQueueOperationState) { IOState_Filter_All, }; -@interface RCTMGLImageQueueOperation() -@property (nonatomic) RCTMGLImageQueueOperationState state; +@interface RCTMLNImageQueueOperation() +@property (nonatomic) RCTMLNImageQueueOperationState state; @end -@implementation RCTMGLImageQueueOperation +@implementation RCTMLNImageQueueOperation { RCTImageLoaderCancellationBlock _cancellationBlock; BOOL _cancelled; @@ -67,9 +67,9 @@ -(void)callCancellationBlock { } } -- (RCTMGLImageQueueOperationState)setState:(RCTMGLImageQueueOperationState)newState only:(RCTMGLImageQueueOperationState)only except:(RCTMGLImageQueueOperationState) except +- (RCTMLNImageQueueOperationState)setState:(RCTMLNImageQueueOperationState)newState only:(RCTMLNImageQueueOperationState)only except:(RCTMLNImageQueueOperationState) except { - RCTMGLImageQueueOperationState prevState = IOState_Filter_None; + RCTMLNImageQueueOperationState prevState = IOState_Filter_None; [self willChangeValueForKey:@"isExecuting"]; [self willChangeValueForKey:@"isFinished"]; [self willChangeValueForKey:@"isCancelled"]; @@ -93,12 +93,12 @@ - (RCTMGLImageQueueOperationState)setState:(RCTMGLImageQueueOperationState)newSt return prevState; } -- (RCTMGLImageQueueOperationState)setState:(RCTMGLImageQueueOperationState)newState only:(RCTMGLImageQueueOperationState)only +- (RCTMLNImageQueueOperationState)setState:(RCTMLNImageQueueOperationState)newState only:(RCTMLNImageQueueOperationState)only { return [self setState: newState only:only except:IOState_Filter_None]; } -- (RCTMGLImageQueueOperationState)setState:(RCTMGLImageQueueOperationState)newState except:(RCTMGLImageQueueOperationState)except +- (RCTMLNImageQueueOperationState)setState:(RCTMLNImageQueueOperationState)newState except:(RCTMLNImageQueueOperationState)except { return [self setState: newState only:IOState_Filter_All except:except]; } @@ -108,7 +108,7 @@ - (void)start if (self.state == IOState_CancelledDoNotExecute) { return; } - __weak RCTMGLImageQueueOperation *weakSelf = self; + __weak RCTMLNImageQueueOperation *weakSelf = self; dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{ [weakSelf setCancellationBlock: [[weakSelf.bridge moduleForName:@"ImageLoader" lazilyLoadIfNecessary:YES] loadImageWithURLRequest:weakSelf.urlRequest diff --git a/ios/RCTMGL/RCTMGLImageSource.h b/ios/RCTMLN/RCTMLNImageSource.h similarity index 68% rename from ios/RCTMGL/RCTMGLImageSource.h rename to ios/RCTMLN/RCTMLNImageSource.h index 47247d4d4..dbf19e8cf 100644 --- a/ios/RCTMGL/RCTMGLImageSource.h +++ b/ios/RCTMLN/RCTMLNImageSource.h @@ -1,14 +1,14 @@ // -// RCTMGLImageSource.h -// RCTMGL +// RCTMLNImageSource.h +// RCTMLN // // Created by Nick Italiano on 11/29/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLSource.h" +#import "RCTMLNSource.h" -@interface RCTMGLImageSource : RCTMGLSource +@interface RCTMLNImageSource : RCTMLNSource @property (nonatomic, copy) NSString *url; @property (nonatomic, copy) NSArray *> *coordinates; diff --git a/ios/RCTMGL/RCTMGLImageSource.m b/ios/RCTMLN/RCTMLNImageSource.m similarity index 75% rename from ios/RCTMGL/RCTMGLImageSource.m rename to ios/RCTMLN/RCTMLNImageSource.m index 817918b20..db0093049 100644 --- a/ios/RCTMGL/RCTMGLImageSource.m +++ b/ios/RCTMLN/RCTMLNImageSource.m @@ -1,22 +1,22 @@ // -// RCTMGLImageSource.m -// RCTMGL +// RCTMLNImageSource.m +// RCTMLN // // Created by Nick Italiano on 11/29/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLImageSource.h" -@import Mapbox; +#import "RCTMLNImageSource.h" +@import MapLibre; -@implementation RCTMGLImageSource +@implementation RCTMLNImageSource - (void)setUrl:(NSString *)url { _url = url; if (self.source != nil) { - MGLImageSource *source = (MGLImageSource *)self.source; + MLNImageSource *source = (MLNImageSource *)self.source; source.URL = [NSURL URLWithString:_url]; } } @@ -25,12 +25,12 @@ - (void)setCoordinates:(NSArray *> *)coordinates { _coordinates = coordinates; if (self.source != nil) { - MGLImageSource *source = (MGLImageSource *)self.source; + MLNImageSource *source = (MLNImageSource *)self.source; source.coordinates = [self _makeCoordQuad]; } } -- (nullable MGLSource *)makeSource +- (nullable MLNSource *)makeSource { NSURL *myURL; @@ -43,18 +43,18 @@ - (nullable MGLSource *)makeSource myURL = [NSURL fileURLWithPath:_url]; } - return [[MGLImageSource alloc] initWithIdentifier:self.id + return [[MLNImageSource alloc] initWithIdentifier:self.id coordinateQuad:[self _makeCoordQuad] URL:myURL]; } -- (MGLCoordinateQuad)_makeCoordQuad +- (MLNCoordinateQuad)_makeCoordQuad { CLLocationCoordinate2D topLeft = CLLocationCoordinate2DMake([self.coordinates[0][1] floatValue], [self.coordinates[0][0] floatValue]); CLLocationCoordinate2D topRight = CLLocationCoordinate2DMake([self.coordinates[1][1] floatValue], [self.coordinates[1][0] floatValue]); CLLocationCoordinate2D bottomRight = CLLocationCoordinate2DMake([self.coordinates[2][1] floatValue], [self.coordinates[2][0] floatValue]); CLLocationCoordinate2D bottomLeft = CLLocationCoordinate2DMake([self.coordinates[3][1] floatValue], [self.coordinates[3][0] floatValue]); - return MGLCoordinateQuadMake(topLeft, bottomLeft, bottomRight, topRight); + return MLNCoordinateQuadMake(topLeft, bottomLeft, bottomRight, topRight); } @end diff --git a/ios/RCTMGL/RCTMGLImageSourceManager.h b/ios/RCTMLN/RCTMLNImageSourceManager.h similarity index 60% rename from ios/RCTMGL/RCTMGLImageSourceManager.h rename to ios/RCTMLN/RCTMLNImageSourceManager.h index 19f27153d..1f2ee9ed9 100644 --- a/ios/RCTMGL/RCTMGLImageSourceManager.h +++ b/ios/RCTMLN/RCTMLNImageSourceManager.h @@ -1,6 +1,6 @@ // -// RCTMGLImageSourceManager.h -// RCTMGL +// RCTMLNImageSourceManager.h +// RCTMLN // // Created by Nick Italiano on 11/29/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLImageSourceManager : ViewManager +@interface RCTMLNImageSourceManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLImageSourceManager.m b/ios/RCTMLN/RCTMLNImageSourceManager.m similarity index 60% rename from ios/RCTMGL/RCTMGLImageSourceManager.m rename to ios/RCTMLN/RCTMLNImageSourceManager.m index 4b0aa0db3..330981071 100644 --- a/ios/RCTMGL/RCTMGLImageSourceManager.m +++ b/ios/RCTMLN/RCTMLNImageSourceManager.m @@ -1,15 +1,15 @@ // -// RCTMGLImageSourceManager.m -// RCTMGL +// RCTMLNImageSourceManager.m +// RCTMLN // // Created by Nick Italiano on 11/29/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLImageSourceManager.h" -#import "RCTMGLImageSource.h" +#import "RCTMLNImageSourceManager.h" +#import "RCTMLNImageSource.h" -@implementation RCTMGLImageSourceManager +@implementation RCTMLNImageSourceManager RCT_EXPORT_MODULE() @@ -19,7 +19,7 @@ @implementation RCTMGLImageSourceManager - (UIView*)view { - return [RCTMGLImageSource new]; + return [RCTMLNImageSource new]; } @end diff --git a/ios/RCTMGL/RCTMGLImages.h b/ios/RCTMLN/RCTMLNImages.h similarity index 80% rename from ios/RCTMGL/RCTMGLImages.h rename to ios/RCTMLN/RCTMLNImages.h index 3fecb2b4a..c4af10837 100644 --- a/ios/RCTMGL/RCTMGLImages.h +++ b/ios/RCTMLN/RCTMLNImages.h @@ -2,15 +2,15 @@ #import #import -@import Mapbox; +@import MapLibre; -@class RCTMGLMapView; +@class RCTMLNMapView; -@interface RCTMGLImages : UIView +@interface RCTMLNImages : UIView @property (nonatomic, weak) RCTBridge *bridge; -@property (nonatomic, strong) RCTMGLMapView *map; +@property (nonatomic, strong) RCTMLNMapView *map; @property (nonatomic, strong) NSDictionary *images; @property (nonatomic, strong) NSArray *nativeImages; diff --git a/ios/RCTMGL/RCTMGLImages.m b/ios/RCTMLN/RCTMLNImages.m similarity index 89% rename from ios/RCTMGL/RCTMGLImages.m rename to ios/RCTMLN/RCTMLNImages.m index 2738d0ec7..466d159cf 100644 --- a/ios/RCTMGL/RCTMGLImages.m +++ b/ios/RCTMLN/RCTMLNImages.m @@ -1,12 +1,12 @@ -#import "RCTMGLImages.h" +#import "RCTMLNImages.h" #import -#import "RCTMGLMapView.h" -#import "RCTMGLUtils.h" -#import "RCTMGLEvent.h" -#import "RCTMGLEventTypes.h" +#import "RCTMLNMapView.h" +#import "RCTMLNUtils.h" +#import "RCTMLNEvent.h" +#import "RCTMLNEventTypes.h" -@implementation RCTMGLImages : UIView +@implementation RCTMLNImages : UIView static UIImage * _placeHolderImage; @@ -61,7 +61,7 @@ -(BOOL)addMissingImageToStyle:(NSString *)imageName { - (void) sendImageMissingEvent:(NSString *)imageName { NSDictionary *payload = @{ @"imageKey": imageName }; - RCTMGLEvent *event = [RCTMGLEvent makeEvent:RCT_MAPBOX_IMAGES_MISSING_IMAGE withPayload:payload]; + RCTMLNEvent *event = [RCTMLNEvent makeEvent:RCT_MAPBOX_IMAGES_MISSING_IMAGE withPayload:payload]; if (_onImageMissing) { _onImageMissing([event toJSON]); } @@ -72,7 +72,7 @@ - (void)_addNativeImages:(NSArray*)nativeImages if (!nativeImages) return; for (NSString *imageName in nativeImages) { - // only add native images if they are not in the style yet (similar to [RCTMGLUtils fetchImages: style:]) + // only add native images if they are not in the style yet (similar to [RCTMLNUtils fetchImages: style:]) if (![self.map.style imageForName:imageName]) { UIImage *image = [UIImage imageNamed:imageName]; [self.map.style setImage:image forName:imageName]; @@ -94,14 +94,14 @@ - (void)_addRemoteImages:(NSDictionary*)remoteImages // See also: https://github.com/mapbox/mapbox-gl-native/pull/14253#issuecomment-478827792 for (NSString *imageName in remoteImages.allKeys) { if (![self.map.style imageForName:imageName]) { - [self.map.style setImage:[RCTMGLImages placeholderImage] forName:imageName]; + [self.map.style setImage:[RCTMLNImages placeholderImage] forName:imageName]; [missingImages setValue:_images[imageName] forKey:imageName]; } } if (missingImages.count > 0) { // forceUpdate to ensure the placeholder images are updated - [RCTMGLUtils fetchImages:_bridge style:self.map.style objects:_images forceUpdate:true callback:^{ }]; + [RCTMLNUtils fetchImages:_bridge style:self.map.style objects:_images forceUpdate:true callback:^{ }]; } } diff --git a/ios/RCTMLN/RCTMLNImagesManager.h b/ios/RCTMLN/RCTMLNImagesManager.h new file mode 100644 index 000000000..128c45c29 --- /dev/null +++ b/ios/RCTMLN/RCTMLNImagesManager.h @@ -0,0 +1,5 @@ +#import "ViewManager.h" + +@interface RCTMLNImagesManager : ViewManager + +@end diff --git a/ios/RCTMGL/RCTMGLImagesManager.m b/ios/RCTMLN/RCTMLNImagesManager.m similarity index 69% rename from ios/RCTMGL/RCTMGLImagesManager.m rename to ios/RCTMLN/RCTMLNImagesManager.m index aa20aa17d..3bcd37b58 100644 --- a/ios/RCTMGL/RCTMGLImagesManager.m +++ b/ios/RCTMLN/RCTMLNImagesManager.m @@ -1,7 +1,7 @@ -#import "RCTMGLImagesManager.h" -#import "RCTMGLImages.h" +#import "RCTMLNImagesManager.h" +#import "RCTMLNImages.h" -@implementation RCTMGLImagesManager +@implementation RCTMLNImagesManager RCT_EXPORT_MODULE() @@ -13,7 +13,7 @@ @implementation RCTMGLImagesManager - (UIView*)view { - RCTMGLImages *images = [RCTMGLImages new]; + RCTMLNImages *images = [RCTMLNImages new]; images.bridge = self.bridge; return images; } diff --git a/ios/RCTMGL/RCTMGLLayer.h b/ios/RCTMLN/RCTMLNLayer.h similarity index 68% rename from ios/RCTMGL/RCTMGLLayer.h rename to ios/RCTMLN/RCTMLNLayer.h index 1ede8a0f3..14f7ac2ac 100644 --- a/ios/RCTMGL/RCTMGLLayer.h +++ b/ios/RCTMLN/RCTMLNLayer.h @@ -1,6 +1,6 @@ // // BaseLayer.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -10,17 +10,17 @@ #import -@class RCTMGLMapView; +@class RCTMLNMapView; -@import Mapbox; +@import MapLibre; -@interface RCTMGLLayer : UIView +@interface RCTMLNLayer : UIView @property (nonatomic, weak, nullable) RCTBridge* bridge; -@property (nonatomic, strong, nullable) MGLStyleLayer *styleLayer; -@property (nonatomic, strong, nullable) MGLStyle *style; -@property (nonatomic, weak, nullable) RCTMGLMapView* map; +@property (nonatomic, strong, nullable) MLNStyleLayer *styleLayer; +@property (nonatomic, strong, nullable) MLNStyle *style; +@property (nonatomic, weak, nullable) RCTMLNMapView* map; @property (nonatomic, strong, nullable) NSDictionary *reactStyle; @property (nonatomic, strong, nullable) NSArray *filter; @@ -34,10 +34,10 @@ @property (nonatomic, copy, nullable) NSNumber *maxZoomLevel; @property (nonatomic, copy, nullable) NSNumber *minZoomLevel; -- (void)addToMap:(nonnull RCTMGLMapView*)map style:(nonnull MGLStyle*)style; +- (void)addToMap:(nonnull RCTMLNMapView*)map style:(nonnull MLNStyle*)style; - (void)addedToMap; -- (void)removeFromMap:(nonnull MGLStyle*)style; -- (nullable T)makeLayer:(nonnull MGLStyle*)style; +- (void)removeFromMap:(nonnull MLNStyle*)style; +- (nullable T)makeLayer:(nonnull MLNStyle*)style; - (void)addStyles; - (void)insertAbove:(nonnull NSString*)layer; - (void)insertBelow:(nonnull NSString*)layer; @@ -47,6 +47,6 @@ - (BOOL)isAddedToMap; -- (nullable MGLSource*)layerWithSourceIDInStyle:(nonnull MGLStyle*) style; +- (nullable MLNSource*)layerWithSourceIDInStyle:(nonnull MLNStyle*) style; @end diff --git a/ios/RCTMGL/RCTMGLLayer.m b/ios/RCTMLN/RCTMLNLayer.m similarity index 87% rename from ios/RCTMGL/RCTMGLLayer.m rename to ios/RCTMLN/RCTMLNLayer.m index 78cd88184..f41369bf9 100644 --- a/ios/RCTMGL/RCTMGLLayer.m +++ b/ios/RCTMLN/RCTMLNLayer.m @@ -1,18 +1,18 @@ // // BaseLayer.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLLayer.h" -#import "RCTMGLSource.h" -#import "RCTMGLStyleValue.h" -#import "RCTMGLUtils.h" -#import "RCTMGLMapView.h" +#import "RCTMLNLayer.h" +#import "RCTMLNSource.h" +#import "RCTMLNStyleValue.h" +#import "RCTMLNUtils.h" +#import "RCTMLNMapView.h" -@implementation RCTMGLLayer +@implementation RCTMLNLayer - (void)setMinZoomLevel:(NSNumber*)minZoomLevel { @@ -71,7 +71,7 @@ - (void)setLayerIndex:(NSNumber *)layerIndex } } -- (void)setMap:(RCTMGLMapView *)map { +- (void)setMap:(RCTMLNMapView *)map { if (map == nil) { [self removeFromMap:_map.style]; _map = nil; @@ -92,7 +92,7 @@ -(void)setReactStyle:(NSDictionary *)reactStyle } } -- (void)addToMap:(RCTMGLMapView*) map style:(MGLStyle *)style +- (void)addToMap:(RCTMLNMapView*) map style:(MLNStyle *)style { if (style == nil) { return; @@ -103,7 +103,7 @@ - (void)addToMap:(RCTMGLMapView*) map style:(MGLStyle *)style RCTLogError(@"Cannot add a layer without id to the map: %@", self); return; } - MGLStyleLayer *existingLayer = [style layerWithIdentifier:_id]; + MLNStyleLayer *existingLayer = [style layerWithIdentifier:_id]; if (existingLayer != nil) { _styleLayer = existingLayer; } else { @@ -119,16 +119,16 @@ - (void)addToMap:(RCTMGLMapView*) map style:(MGLStyle *)style [self addedToMap]; } -- (nullable MGLSource*)layerWithSourceIDInStyle:(nonnull MGLStyle*) style +- (nullable MLNSource*)layerWithSourceIDInStyle:(nonnull MLNStyle*) style { - MGLSource* result = [style sourceWithIdentifier: self.sourceID]; + MLNSource* result = [style sourceWithIdentifier: self.sourceID]; if (result == NULL) { RCTLogError(@"Cannot find layer with id: %@ referenced by layer:%@", self.sourceID, _id); } return result; } -- (void)removeFromMap:(MGLStyle *)style +- (void)removeFromMap:(MLNStyle *)style { if (_styleLayer != nil) { [style removeLayer:_styleLayer]; @@ -141,7 +141,7 @@ - (BOOL)isAddedToMap return (_style != nil); } -- (nullable MGLStyleLayer*)makeLayer:(MGLStyle*)style +- (nullable MLNStyleLayer*)makeLayer:(MLNStyle*)style { @throw [NSException exceptionWithName:NSInternalInconsistencyException reason:[NSString stringWithFormat:@"You must override %@ in a subclass", NSStringFromSelector(_cmd)] @@ -160,7 +160,7 @@ - (void)addedToMap // override if you want } -- (void)insertLayer: (RCTMGLMapView*) map +- (void)insertLayer: (RCTMLNMapView*) map { if ([_style layerWithIdentifier:_id] != nil) { return; // prevent layer from being added twice @@ -193,7 +193,7 @@ - (void)setZoomBounds -(void)insertAbove:(NSString*)aboveLayerIDs { - [_map waitForLayerWithID: aboveLayerIDs then:^void (MGLStyleLayer* layer) { + [_map waitForLayerWithID: aboveLayerIDs then:^void (MLNStyleLayer* layer) { if (![self _hasInitialized]) { return; } @@ -204,7 +204,7 @@ -(void)insertAbove:(NSString*)aboveLayerIDs -(void)insertBelow:(NSString*)belowLayerID { - [_map waitForLayerWithID: belowLayerID then:^void (MGLStyleLayer* layer) { + [_map waitForLayerWithID: belowLayerID then:^void (MLNStyleLayer* layer) { if (![self _hasInitialized]) { return; } diff --git a/ios/RCTMGL/RCTMGLLight.h b/ios/RCTMLN/RCTMLNLight.h similarity index 60% rename from ios/RCTMGL/RCTMGLLight.h rename to ios/RCTMLN/RCTMLNLight.h index e4a971a28..809d174b1 100644 --- a/ios/RCTMGL/RCTMGLLight.h +++ b/ios/RCTMLN/RCTMLNLight.h @@ -1,17 +1,17 @@ // -// RCTMGLLight.h -// RCTMGL +// RCTMLNLight.h +// RCTMLN // // Created by Nick Italiano on 9/26/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -@import Mapbox; +@import MapLibre; -@interface RCTMGLLight : UIView +@interface RCTMLNLight : UIView -@property (nonatomic, strong) MGLMapView *map; +@property (nonatomic, strong) MLNMapView *map; @property (nonatomic, strong) NSDictionary *reactStyle; @end diff --git a/ios/RCTMGL/RCTMGLLight.m b/ios/RCTMLN/RCTMLNLight.m similarity index 65% rename from ios/RCTMGL/RCTMGLLight.m rename to ios/RCTMLN/RCTMLNLight.m index e558e152f..1cd78d2c4 100644 --- a/ios/RCTMGL/RCTMGLLight.m +++ b/ios/RCTMLN/RCTMLNLight.m @@ -1,17 +1,17 @@ // -// RCTMGLLight.m -// RCTMGL +// RCTMLNLight.m +// RCTMLN // // Created by Nick Italiano on 9/26/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLLight.h" -#import "RCTMGLStyle.h" +#import "RCTMLNLight.h" +#import "RCTMLNStyle.h" -@implementation RCTMGLLight +@implementation RCTMLNLight { - MGLLight *internalLight; + MLNLight *internalLight; } - (void)setReactStyle:(NSDictionary *)reactStyle @@ -23,7 +23,7 @@ - (void)setReactStyle:(NSDictionary *)reactStyle } } -- (void)setMap:(MGLMapView *)map +- (void)setMap:(MLNMapView *)map { _map = map; [self addStyles]; @@ -35,8 +35,8 @@ - (BOOL)isAddedToMap { - (void)addStyles { - MGLLight *light = [[MGLLight alloc] init]; - RCTMGLStyle *style = [[RCTMGLStyle alloc] init]; + MLNLight *light = [[MLNLight alloc] init]; + RCTMLNStyle *style = [[RCTMLNStyle alloc] init]; [style lightLayer:light withReactStyle:_reactStyle isValid:^{ return [self isAddedToMap]; }]; diff --git a/ios/RCTMGL/RCTMGLLightManager.h b/ios/RCTMLN/RCTMLNLightManager.h similarity index 63% rename from ios/RCTMGL/RCTMGLLightManager.h rename to ios/RCTMLN/RCTMLNLightManager.h index b404393ea..6f0c3d092 100644 --- a/ios/RCTMGL/RCTMGLLightManager.h +++ b/ios/RCTMLN/RCTMLNLightManager.h @@ -1,6 +1,6 @@ // -// RCTMGLLightManager.h -// RCTMGL +// RCTMLNLightManager.h +// RCTMLN // // Created by Nick Italiano on 9/26/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLLightManager : ViewManager +@interface RCTMLNLightManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLLightManager.m b/ios/RCTMLN/RCTMLNLightManager.m similarity index 57% rename from ios/RCTMGL/RCTMGLLightManager.m rename to ios/RCTMLN/RCTMLNLightManager.m index 505ebe3f2..fcab1c816 100644 --- a/ios/RCTMGL/RCTMGLLightManager.m +++ b/ios/RCTMLN/RCTMLNLightManager.m @@ -1,15 +1,15 @@ // -// RCTMGLLightManager.m -// RCTMGL +// RCTMLNLightManager.m +// RCTMLN // // Created by Nick Italiano on 9/26/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLLightManager.h" -#import "RCTMGLLight.h" +#import "RCTMLNLightManager.h" +#import "RCTMLNLight.h" -@implementation RCTMGLLightManager +@implementation RCTMLNLightManager RCT_EXPORT_MODULE() @@ -17,7 +17,7 @@ @implementation RCTMGLLightManager - (UIView*)view { - return [RCTMGLLight new]; + return [RCTMLNLight new]; } @end diff --git a/ios/RCTMLN/RCTMLNLineLayer.h b/ios/RCTMLN/RCTMLNLineLayer.h new file mode 100644 index 000000000..2ae9f04a4 --- /dev/null +++ b/ios/RCTMLN/RCTMLNLineLayer.h @@ -0,0 +1,14 @@ +// +// RCTMLNLineLayer.h +// RCTMLN +// +// Created by Nick Italiano on 9/18/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import "RCTMLNVectorLayer.h" +@import MapLibre; + +@interface RCTMLNLineLayer : RCTMLNVectorLayer + +@end diff --git a/ios/RCTMGL/RCTMGLLineLayer.m b/ios/RCTMLN/RCTMLNLineLayer.m similarity index 50% rename from ios/RCTMGL/RCTMGLLineLayer.m rename to ios/RCTMLN/RCTMLNLineLayer.m index 2878314b5..75922c12a 100644 --- a/ios/RCTMGL/RCTMGLLineLayer.m +++ b/ios/RCTMLN/RCTMLNLineLayer.m @@ -1,31 +1,31 @@ // -// RCTMGLLineLayer.m -// RCTMGL +// RCTMLNLineLayer.m +// RCTMLN // // Created by Nick Italiano on 9/18/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLLineLayer.h" -#import "RCTMGLStyle.h" +#import "RCTMLNLineLayer.h" +#import "RCTMLNStyle.h" #import -@implementation RCTMGLLineLayer +@implementation RCTMLNLineLayer -- (MGLLineStyleLayer*)makeLayer:(MGLStyle*)style +- (MLNLineStyleLayer*)makeLayer:(MLNStyle*)style { - MGLSource *source = [self layerWithSourceIDInStyle:style]; + MLNSource *source = [self layerWithSourceIDInStyle:style]; if (source == nil) { return nil; } - MGLLineStyleLayer *layer = [[MGLLineStyleLayer alloc] initWithIdentifier:self.id source:source]; + MLNLineStyleLayer *layer = [[MLNLineStyleLayer alloc] initWithIdentifier:self.id source:source]; layer.sourceLayerIdentifier = self.sourceLayerID; return layer; } - (void)addStyles { - RCTMGLStyle *style = [[RCTMGLStyle alloc] initWithMGLStyle:self.style]; + RCTMLNStyle *style = [[RCTMLNStyle alloc] initWithMLNStyle:self.style]; style.bridge = self.bridge; - [style lineLayer:(MGLLineStyleLayer *)self.styleLayer withReactStyle:self.reactStyle isValid:^{ + [style lineLayer:(MLNLineStyleLayer *)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; }]; } diff --git a/ios/RCTMGL/RCTMGLLineLayerManager.h b/ios/RCTMLN/RCTMLNLineLayerManager.h similarity index 60% rename from ios/RCTMGL/RCTMGLLineLayerManager.h rename to ios/RCTMLN/RCTMLNLineLayerManager.h index 84d4dfadc..02ee287d2 100644 --- a/ios/RCTMGL/RCTMGLLineLayerManager.h +++ b/ios/RCTMLN/RCTMLNLineLayerManager.h @@ -1,6 +1,6 @@ // -// RCTMGLLineLayerManager.h -// RCTMGL +// RCTMLNLineLayerManager.h +// RCTMLN // // Created by Nick Italiano on 9/18/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLLineLayerManager : ViewManager +@interface RCTMLNLineLayerManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLLineLayerManager.m b/ios/RCTMLN/RCTMLNLineLayerManager.m similarity index 79% rename from ios/RCTMGL/RCTMGLLineLayerManager.m rename to ios/RCTMLN/RCTMLNLineLayerManager.m index fe97f99a0..58e2d4e3c 100644 --- a/ios/RCTMGL/RCTMGLLineLayerManager.m +++ b/ios/RCTMLN/RCTMLNLineLayerManager.m @@ -1,15 +1,15 @@ // -// RCTMGLLineLayerManager.m -// RCTMGL +// RCTMLNLineLayerManager.m +// RCTMLN // // Created by Nick Italiano on 9/18/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLLineLayerManager.h" -#import "RCTMGLLineLayer.h" +#import "RCTMLNLineLayerManager.h" +#import "RCTMLNLineLayer.h" -@implementation RCTMGLLineLayerManager +@implementation RCTMLNLineLayerManager RCT_EXPORT_MODULE() @@ -31,7 +31,7 @@ @implementation RCTMGLLineLayerManager - (UIView*)view { - RCTMGLLineLayer *layer = [RCTMGLLineLayer new]; + RCTMLNLineLayer *layer = [RCTMLNLineLayer new]; layer.bridge = self.bridge; return layer; } diff --git a/ios/RCTMGL/RCTMGLLocation.h b/ios/RCTMLN/RCTMLNLocation.h similarity index 82% rename from ios/RCTMGL/RCTMGLLocation.h rename to ios/RCTMLN/RCTMLNLocation.h index a4501f95f..ad688194e 100644 --- a/ios/RCTMGL/RCTMGLLocation.h +++ b/ios/RCTMLN/RCTMLNLocation.h @@ -1,6 +1,6 @@ // -// RCTMGLLocation.h -// RCTMGL +// RCTMLNLocation.h +// RCTMLN // // Created by Nick Italiano on 6/21/18. // Copyright © 2018 Mapbox Inc. All rights reserved. @@ -9,7 +9,7 @@ #import #import -@interface RCTMGLLocation : NSObject +@interface RCTMLNLocation : NSObject @property (nonatomic, strong) CLLocation *location; @property (nonatomic, strong) CLHeading *heading; diff --git a/ios/RCTMGL/RCTMGLLocation.m b/ios/RCTMLN/RCTMLNLocation.m similarity index 90% rename from ios/RCTMGL/RCTMGLLocation.m rename to ios/RCTMLN/RCTMLNLocation.m index bce7a2070..00ef70eb1 100644 --- a/ios/RCTMGL/RCTMGLLocation.m +++ b/ios/RCTMLN/RCTMLNLocation.m @@ -1,14 +1,14 @@ // -// RCTMGLLocation.m -// RCTMGL +// RCTMLNLocation.m +// RCTMLN // // Created by Nick Italiano on 6/21/18. // Copyright © 2018 Mapbox Inc. All rights reserved. // -#import "RCTMGLLocation.h" +#import "RCTMLNLocation.h" -@implementation RCTMGLLocation +@implementation RCTMLNLocation - (NSDictionary *)toJSON { diff --git a/ios/RCTMLN/RCTMLNLocationManager.h b/ios/RCTMLN/RCTMLNLocationManager.h new file mode 100644 index 000000000..4beccf408 --- /dev/null +++ b/ios/RCTMLN/RCTMLNLocationManager.h @@ -0,0 +1,30 @@ +// +// RCTMLNLocationManager.h +// RCTMLN +// +// Created by Nick Italiano on 6/21/18. +// Copyright © 2018 Mapbox Inc. All rights reserved. +// + +#import + +#import "RCTMLNLocation.h" +#import "RCTMLNLocationManagerDelegate.h" + +typedef void (^RCTMLNLocationBlock)(RCTMLNLocation *location); + +@interface RCTMLNLocationManager : NSObject + +@property (nonatomic, strong) id delegate; + ++ (id)sharedInstance; + +- (void)start:(CLLocationDistance)minDisplacement; +- (void)stop; +- (void)setMinDisplacement:(CLLocationDistance)minDisplacement; +- (BOOL)isEnabled; +- (RCTMLNLocation *)getLastKnownLocation; +- (void)addListener:(RCTMLNLocationBlock)listener; +- (void)removeListener:(RCTMLNLocationBlock)listener; + +@end diff --git a/ios/RCTMGL/RCTMGLLocationManager.m b/ios/RCTMLN/RCTMLNLocationManager.m similarity index 80% rename from ios/RCTMGL/RCTMGLLocationManager.m rename to ios/RCTMLN/RCTMLNLocationManager.m index c68a1f4da..12a2f331a 100644 --- a/ios/RCTMGL/RCTMGLLocationManager.m +++ b/ios/RCTMLN/RCTMLNLocationManager.m @@ -1,30 +1,30 @@ // -// RCTMGLLocationManager.m -// RCTMGL +// RCTMLNLocationManager.m +// RCTMLN // // Created by Nick Italiano on 6/21/18. // Copyright © 2018 Mapbox Inc. All rights reserved. // #import -#import "RCTMGLLocationManager.h" +#import "RCTMLNLocationManager.h" -@interface RCTMGLLocationManager() +@interface RCTMLNLocationManager() @end -@implementation RCTMGLLocationManager +@implementation RCTMLNLocationManager { CLLocationManager *locationManager; CLLocation *lastKnownLocation; CLHeading *lastKnownHeading; CLLocationDistance displacement; - NSMutableArray *listeners; + NSMutableArray *listeners; BOOL isListening; } + (id)sharedInstance { - static RCTMGLLocationManager *manager = nil; + static RCTMLNLocationManager *manager = nil; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ manager = [[self alloc] init]; }); return manager; @@ -92,24 +92,24 @@ - (BOOL)isEnabled return isListening; } -- (RCTMGLLocation *)getLastKnownLocation +- (RCTMLNLocation *)getLastKnownLocation { CLLocation* newLastLocation = locationManager.location; if (newLastLocation) { lastKnownLocation = newLastLocation; } - RCTMGLLocation *location = [self _convertToMapboxLocation:lastKnownLocation]; + RCTMLNLocation *location = [self _convertToMapboxLocation:lastKnownLocation]; return location; } -- (void)addListener:(RCTMGLLocationBlock)listener +- (void)addListener:(RCTMLNLocationBlock)listener { if (![listeners containsObject:listener]) { [listeners addObject:listener]; } } -- (void)removeListener:(RCTMGLLocationBlock)listener +- (void)removeListener:(RCTMLNLocationBlock)listener { NSUInteger indexOf = [listeners indexOfObject:listener]; @@ -139,7 +139,7 @@ - (void)locationManager:(CLLocationManager *)manager didUpdateLocations:(NSArray - (void)_setupLocationManager { - __weak RCTMGLLocationManager *weakSelf = self; + __weak RCTMLNLocationManager *weakSelf = self; dispatch_async(dispatch_get_main_queue(), ^{ self->locationManager = [[CLLocationManager alloc] init]; @@ -153,11 +153,11 @@ - (void)_updateDelegate return; } - RCTMGLLocation *userLocation = [self _convertToMapboxLocation:lastKnownLocation]; + RCTMLNLocation *userLocation = [self _convertToMapboxLocation:lastKnownLocation]; if (listeners.count > 0) { for (int i = 0; i < listeners.count; i++) { - RCTMGLLocationBlock listener = listeners[i]; + RCTMLNLocationBlock listener = listeners[i]; listener(userLocation); } } @@ -165,13 +165,13 @@ - (void)_updateDelegate [_delegate locationManager:self didUpdateLocation:userLocation]; } -- (RCTMGLLocation *)_convertToMapboxLocation:(CLLocation *)location +- (RCTMLNLocation *)_convertToMapboxLocation:(CLLocation *)location { if (location == nil) { return nil; } - RCTMGLLocation *userLocation = [[RCTMGLLocation alloc] init]; + RCTMLNLocation *userLocation = [[RCTMLNLocation alloc] init]; userLocation.location = location; userLocation.heading = lastKnownHeading; return userLocation; diff --git a/ios/RCTMLN/RCTMLNLocationManagerDelegate.h b/ios/RCTMLN/RCTMLNLocationManagerDelegate.h new file mode 100644 index 000000000..c0e8c12d4 --- /dev/null +++ b/ios/RCTMLN/RCTMLNLocationManagerDelegate.h @@ -0,0 +1,20 @@ +// +// RCTMLNLocationManagerDelegate.h +// RCTMLN +// +// Created by Nick Italiano on 6/21/18. +// Copyright © 2018 Mapbox Inc. All rights reserved. +// + +#import + +#import "RCTMLNLocation.h" + +@class RCTMLNLocationManager; + +@protocol RCTMLNLocationManagerDelegate + +- (void)locationManager:(RCTMLNLocationManager *)locationManager didUpdateLocation:(RCTMLNLocation *)location; + +@end + diff --git a/ios/RCTMGL/RCTMGLLocationModule.h b/ios/RCTMLN/RCTMLNLocationModule.h similarity index 67% rename from ios/RCTMGL/RCTMGLLocationModule.h rename to ios/RCTMLN/RCTMLNLocationModule.h index 1301ea03f..80a6f2130 100644 --- a/ios/RCTMGL/RCTMGLLocationModule.h +++ b/ios/RCTMLN/RCTMLNLocationModule.h @@ -1,6 +1,6 @@ // -// RCTMGLLocationManager.h -// RCTMGL +// RCTMLNLocationManager.h +// RCTMLN // // Created by Nick Italiano on 6/21/18. // Copyright © 2018 Mapbox Inc. All rights reserved. @@ -10,6 +10,6 @@ #import #import -@interface RCTMGLLocationModule : RCTEventEmitter +@interface RCTMLNLocationModule : RCTEventEmitter @end diff --git a/ios/RCTMGL/RCTMGLLocationModule.m b/ios/RCTMLN/RCTMLNLocationModule.m similarity index 69% rename from ios/RCTMGL/RCTMGLLocationModule.m rename to ios/RCTMLN/RCTMLNLocationModule.m index 153bbf56b..0b83a19cc 100644 --- a/ios/RCTMGL/RCTMGLLocationModule.m +++ b/ios/RCTMLN/RCTMLNLocationModule.m @@ -1,6 +1,6 @@ // -// RCTMGLLocationManager.m -// RCTMGL +// RCTMLNLocationManager.m +// RCTMLN // // Created by Nick Italiano on 6/21/18. // Copyright © 2018 Mapbox Inc. All rights reserved. @@ -8,18 +8,18 @@ #import -#import "RCTMGLLocation.h" -#import "RCTMGLLocationModule.h" -#import "RCTMGLLocationManager.h" -#import "RCTMGLLocationManagerDelegate.h" -#import "RCTMGLEventTypes.h" +#import "RCTMLNLocation.h" +#import "RCTMLNLocationModule.h" +#import "RCTMLNLocationManager.h" +#import "RCTMLNLocationManagerDelegate.h" +#import "RCTMLNEventTypes.h" -@interface RCTMGLLocationModule() +@interface RCTMLNLocationModule() @end -@implementation RCTMGLLocationModule +@implementation RCTMLNLocationModule { - RCTMGLLocationManager *locationManager; + RCTMLNLocationManager *locationManager; BOOL hasListeners; } @@ -33,7 +33,7 @@ + (BOOL)requiresMainQueueSetup - (instancetype)init { if (self = [super init]) { - locationManager = [[RCTMGLLocationManager alloc] init]; + locationManager = [[RCTMLNLocationManager alloc] init]; locationManager.delegate = self; } return self; @@ -78,11 +78,11 @@ - (void)stopObserving RCT_EXPORT_METHOD(getLastKnownLocation:(RCTPromiseResolveBlock)resolve rejecter:(RCTPromiseRejectBlock)reject) { - RCTMGLLocation *lastKnownLocation = [locationManager getLastKnownLocation]; + RCTMLNLocation *lastKnownLocation = [locationManager getLastKnownLocation]; resolve(lastKnownLocation); } -- (void)locationManager:(RCTMGLLocationManager *)locationManager didUpdateLocation:(RCTMGLLocation *)location +- (void)locationManager:(RCTMLNLocationManager *)locationManager didUpdateLocation:(RCTMLNLocation *)location { if (!hasListeners) { return; diff --git a/ios/RCTMLN/RCTMLNLogging.h b/ios/RCTMLN/RCTMLNLogging.h new file mode 100644 index 000000000..29c483a4a --- /dev/null +++ b/ios/RCTMLN/RCTMLNLogging.h @@ -0,0 +1,18 @@ +#ifndef RCTMLNLogging_h +#define RCTMLNLogging_h + +#import +#import + + +@class MLNLoggingConfiguration; + +@interface RCTMLNLogging : RCTEventEmitter + +@property (nonatomic, nonnull) MLNLoggingConfiguration* loggingConfiguration; + +- (void)setLoggingLevel:(nonnull NSString*) logLevel; + +@end + +#endif /* RCTMLNLogging_h */ diff --git a/ios/RCTMGL/RCTMGLLogging.m b/ios/RCTMLN/RCTMLNLogging.m similarity index 65% rename from ios/RCTMGL/RCTMGLLogging.m rename to ios/RCTMLN/RCTMLNLogging.m index 8516b3308..6e49b9d9e 100644 --- a/ios/RCTMGL/RCTMGLLogging.m +++ b/ios/RCTMLN/RCTMLNLogging.m @@ -1,15 +1,15 @@ -#import "RCTMGLLogging.h" +#import "RCTMLNLogging.h" -@import Mapbox; +@import MapLibre; -@interface RCTMGLLogging() +@interface RCTMLNLogging() @property (nonatomic) BOOL hasListeners; @end -@implementation RCTMGLLogging +@implementation RCTMLNLogging + (id)allocWithZone:(NSZone *)zone { - static RCTMGLLogging *sharedInstance = nil; + static RCTMLNLogging *sharedInstance = nil; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ sharedInstance = [super allocWithZone:zone]; @@ -19,10 +19,10 @@ + (id)allocWithZone:(NSZone *)zone { -(id)init { if ( self = [super init] ) { - self.loggingConfiguration = [MGLLoggingConfiguration sharedConfiguration]; - [self.loggingConfiguration setLoggingLevel:MGLLoggingLevelWarning]; + self.loggingConfiguration = [MLNLoggingConfiguration sharedConfiguration]; + [self.loggingConfiguration setLoggingLevel:MLNLoggingLevelWarning]; __weak typeof(self) weakSelf = self; - self.loggingConfiguration.handler = ^(MGLLoggingLevel loggingLevel, NSString *filePath, NSUInteger line, NSString *message) { + self.loggingConfiguration.handler = ^(MLNLoggingLevel loggingLevel, NSString *filePath, NSUInteger line, NSString *message) { [weakSelf sendLogWithLevel:loggingLevel filePath: filePath line: line message: message]; }; } @@ -53,33 +53,33 @@ - (void)stopObserving self.hasListeners = false; } -- (void)sendLogWithLevel:(MGLLoggingLevel)loggingLevel filePath:(NSString*)filePath line:(NSUInteger)line message:(NSString*)message +- (void)sendLogWithLevel:(MLNLoggingLevel)loggingLevel filePath:(NSString*)filePath line:(NSUInteger)line message:(NSString*)message { if (!self.hasListeners) return; NSString* level = @"n/a"; switch (loggingLevel) { - case MGLLoggingLevelInfo: + case MLNLoggingLevelInfo: level = @"info"; break; - case MGLLoggingLevelError: + case MLNLoggingLevelError: level = @"error"; break; -#if MGL_LOGGING_ENABLE_DEBUG - case MGLLoggingLevelDebug: +#if MLN_LOGGING_ENABLE_DEBUG + case MLNLoggingLevelDebug: level = @"debug"; break; #endif - case MGLLoggingLevelWarning: + case MLNLoggingLevelWarning: level = @"warning"; break; - case MGLLoggingLevelNone: + case MLNLoggingLevelNone: level = @"none"; break; - case MGLLoggingLevelFault: + case MLNLoggingLevelFault: level = @"fault"; break; - case MGLLoggingLevelVerbose: + case MLNLoggingLevelVerbose: level = @"verbose"; break; } @@ -104,29 +104,29 @@ - (void)sendLogWithLevel:(MGLLoggingLevel)loggingLevel filePath:(NSString*)fileP RCT_EXPORT_METHOD(setLogLevel: (nonnull NSString*)logLevel) { - MGLLoggingLevel mglLogLevel = MGLLoggingLevelNone; + MLNLoggingLevel mlnLogLevel = MLNLoggingLevelNone; if ([logLevel isEqualToString:@"none"]) { - mglLogLevel = MGLLoggingLevelNone; + mlnLogLevel = MLNLoggingLevelNone; } else if ([logLevel isEqualToString:@"debug"]) { - mglLogLevel = MGLLoggingLevelInfo; + mlnLogLevel = MLNLoggingLevelInfo; } else if ([logLevel isEqualToString:@"fault"]) { - mglLogLevel = MGLLoggingLevelFault; + mlnLogLevel = MLNLoggingLevelFault; } else if ([logLevel isEqualToString:@"error"]) { - mglLogLevel = MGLLoggingLevelError; + mlnLogLevel = MLNLoggingLevelError; } else if ([logLevel isEqualToString:@"warning"]) { - mglLogLevel = MGLLoggingLevelWarning; + mlnLogLevel = MLNLoggingLevelWarning; } else if ([logLevel isEqualToString:@"info"]) { - mglLogLevel = MGLLoggingLevelInfo; + mlnLogLevel = MLNLoggingLevelInfo; } else if ([logLevel isEqualToString:@"debug"]) { -#if MGL_LOGGING_ENABLE_DEBUG - mglLogLevel = MGLLoggingLevelDebug; +#if MLN_LOGGING_ENABLE_DEBUG + mlnLogLevel = MLNLoggingLevelDebug; #else - mglLogLevel = MGLLoggingLevelVerbose; + mlnLogLevel = MLNLoggingLevelVerbose; #endif } else if ([logLevel isEqualToString:@"verbose"]) { - mglLogLevel = MGLLoggingLevelVerbose; + mlnLogLevel = MLNLoggingLevelVerbose; } - self.loggingConfiguration.loggingLevel = mglLogLevel; + self.loggingConfiguration.loggingLevel = mlnLogLevel; } @end diff --git a/ios/RCTMGL/RCTMGLMapTouchEvent.h b/ios/RCTMLN/RCTMLNMapTouchEvent.h similarity index 50% rename from ios/RCTMGL/RCTMGLMapTouchEvent.h rename to ios/RCTMLN/RCTMLNMapTouchEvent.h index 467613a3b..072a97ef0 100644 --- a/ios/RCTMGL/RCTMGLMapTouchEvent.h +++ b/ios/RCTMLN/RCTMLNMapTouchEvent.h @@ -1,25 +1,25 @@ // -// RCTMGLTouchEvent.h -// RCTMGL +// RCTMLNTouchEvent.h +// RCTMLN // // Created by Nick Italiano on 8/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -#import "RCTMGLEvent.h" -#import "RCTMGLPointAnnotation.h" -@import Mapbox; +#import "RCTMLNEvent.h" +#import "RCTMLNPointAnnotation.h" +@import MapLibre; -@interface RCTMGLMapTouchEvent : RCTMGLEvent +@interface RCTMLNMapTouchEvent : RCTMLNEvent @property (nonatomic, copy) NSString *id; @property (nonatomic, assign) CLLocationCoordinate2D coordinate; @property (nonatomic, assign) CGPoint screenPoint; -+ (RCTMGLMapTouchEvent*)makeTapEvent:(MGLMapView*)mapView withPoint:(CGPoint)point; -+ (RCTMGLMapTouchEvent*)makeLongPressEvent:(MGLMapView*)mapView withPoint:(CGPoint)point; -+ (RCTMGLMapTouchEvent *)makeAnnotationTapEvent:(RCTMGLPointAnnotation *)pointAnnotation; -+ (RCTMGLMapTouchEvent *)makeAnnotationTapEventOnDrag:(RCTMGLPointAnnotation *)pointAnnotation; ++ (RCTMLNMapTouchEvent*)makeTapEvent:(MLNMapView*)mapView withPoint:(CGPoint)point; ++ (RCTMLNMapTouchEvent*)makeLongPressEvent:(MLNMapView*)mapView withPoint:(CGPoint)point; ++ (RCTMLNMapTouchEvent *)makeAnnotationTapEvent:(RCTMLNPointAnnotation *)pointAnnotation; ++ (RCTMLNMapTouchEvent *)makeAnnotationTapEventOnDrag:(RCTMLNPointAnnotation *)pointAnnotation; @end diff --git a/ios/RCTMGL/RCTMGLMapTouchEvent.m b/ios/RCTMLN/RCTMLNMapTouchEvent.m similarity index 66% rename from ios/RCTMGL/RCTMGLMapTouchEvent.m rename to ios/RCTMLN/RCTMLNMapTouchEvent.m index ec3ac19d7..e3c57b676 100644 --- a/ios/RCTMGL/RCTMGLMapTouchEvent.m +++ b/ios/RCTMLN/RCTMLNMapTouchEvent.m @@ -1,21 +1,21 @@ // -// RCTMGLTouchEvent.m -// RCTMGL +// RCTMLNTouchEvent.m +// RCTMLN // // Created by Nick Italiano on 8/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLMapTouchEvent.h" -#import "RCTMGLEventTypes.h" -#import "RCTMGLPointAnnotation.h" -@import Mapbox; +#import "RCTMLNMapTouchEvent.h" +#import "RCTMLNEventTypes.h" +#import "RCTMLNPointAnnotation.h" +@import MapLibre; -@implementation RCTMGLMapTouchEvent +@implementation RCTMLNMapTouchEvent - (NSDictionary*)payload { - MGLPointFeature *feature = [[MGLPointFeature alloc] init]; + MLNPointFeature *feature = [[MLNPointFeature alloc] init]; feature.coordinate = _coordinate; if (_id == nil) { feature.attributes = @{ @@ -32,19 +32,19 @@ - (NSDictionary*)payload return [feature geoJSONDictionary]; } -+ (RCTMGLMapTouchEvent*)makeTapEvent:(MGLMapView*)mapView withPoint:(CGPoint)point ++ (RCTMLNMapTouchEvent*)makeTapEvent:(MLNMapView*)mapView withPoint:(CGPoint)point { - return [RCTMGLMapTouchEvent _fromPoint:point withMapView:mapView andEventType:RCT_MAPBOX_EVENT_TAP]; + return [RCTMLNMapTouchEvent _fromPoint:point withMapView:mapView andEventType:RCT_MAPBOX_EVENT_TAP]; } -+ (RCTMGLMapTouchEvent*)makeLongPressEvent:(MGLMapView*)mapView withPoint:(CGPoint)point ++ (RCTMLNMapTouchEvent*)makeLongPressEvent:(MLNMapView*)mapView withPoint:(CGPoint)point { - return [RCTMGLMapTouchEvent _fromPoint:point withMapView:mapView andEventType:RCT_MAPBOX_EVENT_LONGPRESS]; + return [RCTMLNMapTouchEvent _fromPoint:point withMapView:mapView andEventType:RCT_MAPBOX_EVENT_LONGPRESS]; } -+ (RCTMGLMapTouchEvent *)makeAnnotationTapEvent:(RCTMGLPointAnnotation *)pointAnnotation ++ (RCTMLNMapTouchEvent *)makeAnnotationTapEvent:(RCTMLNPointAnnotation *)pointAnnotation { - RCTMGLMapTouchEvent *event = [[RCTMGLMapTouchEvent alloc] init]; + RCTMLNMapTouchEvent *event = [[RCTMLNMapTouchEvent alloc] init]; event.type = RCT_MAPBOX_ANNOTATION_TAP; event.id = pointAnnotation.id; event.coordinate = pointAnnotation.coordinate; @@ -52,9 +52,9 @@ + (RCTMGLMapTouchEvent *)makeAnnotationTapEvent:(RCTMGLPointAnnotation *)pointAn return event; } -+ (RCTMGLMapTouchEvent *)makeAnnotationTapEventOnDrag:(RCTMGLPointAnnotation *)pointAnnotation ++ (RCTMLNMapTouchEvent *)makeAnnotationTapEventOnDrag:(RCTMLNPointAnnotation *)pointAnnotation { - RCTMGLMapTouchEvent *event = [[RCTMGLMapTouchEvent alloc] init]; + RCTMLNMapTouchEvent *event = [[RCTMLNMapTouchEvent alloc] init]; event.type = RCT_MAPBOX_ANNOTATION_TAP; event.id = pointAnnotation.id; CGPoint screenPoint = [pointAnnotation.superview convertPoint:pointAnnotation.layer.position toView:nil]; @@ -65,9 +65,9 @@ + (RCTMGLMapTouchEvent *)makeAnnotationTapEventOnDrag:(RCTMGLPointAnnotation *)p return event; } -+ (RCTMGLMapTouchEvent*)_fromPoint:(CGPoint)point withMapView:(MGLMapView *)mapView andEventType:(NSString*)eventType ++ (RCTMLNMapTouchEvent*)_fromPoint:(CGPoint)point withMapView:(MLNMapView *)mapView andEventType:(NSString*)eventType { - RCTMGLMapTouchEvent *event = [[RCTMGLMapTouchEvent alloc] init]; + RCTMLNMapTouchEvent *event = [[RCTMLNMapTouchEvent alloc] init]; event.type = eventType; event.coordinate = [mapView convertPoint:point toCoordinateFromView:mapView]; event.screenPoint = point; diff --git a/ios/RCTMGL/RCTMGLMapView.h b/ios/RCTMLN/RCTMLNMapView.h similarity index 62% rename from ios/RCTMGL/RCTMGLMapView.h rename to ios/RCTMLN/RCTMLNMapView.h index 413e63f3e..b7f177e39 100644 --- a/ios/RCTMGL/RCTMGLMapView.h +++ b/ios/RCTMLN/RCTMLNMapView.h @@ -1,42 +1,42 @@ // -// RCTMGLMapView.h -// RCTMGL +// RCTMLNMapView.h +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -#import "RCTMGLSource.h" -#import "RCTMGLShapeSource.h" -#import "RCTMGLPointAnnotation.h" -#import "RCTMGLLight.h" +#import "RCTMLNSource.h" +#import "RCTMLNShapeSource.h" +#import "RCTMLNPointAnnotation.h" +#import "RCTMLNLight.h" -@import Mapbox; +@import MapLibre; @class CameraUpdateQueue; -@class RCTMGLImages; -@class RCTMGLLogging; +@class RCTMLNImages; +@class RCTMLNLogging; -@protocol RCTMGLMapViewCamera +@protocol RCTMLNMapViewCamera - (void)initialLayout; -- (void)didChangeUserTrackingMode:(MGLUserTrackingMode)mode animated:(BOOL)animated; +- (void)didChangeUserTrackingMode:(MLNUserTrackingMode)mode animated:(BOOL)animated; @end -typedef void (^FoundLayerBlock) (MGLStyleLayer* __nonnull layer); -typedef void (^StyleLoadedBlock) (MGLStyle* __nonnull style); +typedef void (^FoundLayerBlock) (MLNStyleLayer* __nonnull layer); +typedef void (^StyleLoadedBlock) (MLNStyle* __nonnull style); -@interface RCTMGLMapView : MGLMapView +@interface RCTMLNMapView : MLNMapView -@property (nonatomic, strong, nonnull) RCTMGLLogging* logging; +@property (nonatomic, strong, nonnull) RCTMLNLogging* logging; @property (nonatomic, strong) CameraUpdateQueue *cameraUpdateQueue; -@property (nonatomic, weak) id reactCamera; +@property (nonatomic, weak) id reactCamera; @property (nonatomic, strong) NSMutableArray> *reactSubviews; -@property (nonatomic, strong) NSMutableArray *sources; -@property (nonatomic, strong) NSMutableArray *images; -@property (nonatomic, strong) NSMutableArray *layers; -@property (nonatomic, strong) NSMutableArray *pointAnnotations; -@property (nonatomic, strong) RCTMGLLight *light; +@property (nonatomic, strong) NSMutableArray *sources; +@property (nonatomic, strong) NSMutableArray *images; +@property (nonatomic, strong) NSMutableArray *layers; +@property (nonatomic, strong) NSMutableArray *pointAnnotations; +@property (nonatomic, strong) RCTMLNLight *light; @property (nonatomic, copy) NSArray *reactContentInset; @property (nonatomic, strong) NSMutableDictionary*> *layerWaiters; @@ -58,7 +58,7 @@ typedef void (^StyleLoadedBlock) (MGLStyle* __nonnull style); @property (nonatomic, copy) NSString *reactStyleURL; @property (nonatomic, assign) NSInteger reactPreferredFramesPerSecond; -@property (nonatomic, assign) MGLCoordinateBounds maxBounds; +@property (nonatomic, assign) MLNCoordinateBounds maxBounds; @property (nonatomic, assign) BOOL isUserInteraction; @property (nonatomic, assign) BOOL useNativeUserLocationAnnotationView; @@ -68,21 +68,21 @@ typedef void (^StyleLoadedBlock) (MGLStyle* __nonnull style); @property (nonatomic, copy) RCTBubblingEventBlock onMapChange; -- (void)layerAdded:(MGLStyleLayer*) layer; +- (void)layerAdded:(MLNStyleLayer*) layer; - (CLLocationDistance)getMetersPerPixelAtLatitude:(double)latitude withZoom:(double)zoomLevel; - (CLLocationDistance)altitudeFromZoom:(double)zoomLevel; - (CLLocationDistance)altitudeFromZoom:(double)zoomLevel atLatitude:(CLLocationDegrees)latitude; - (CLLocationDistance)altitudeFromZoom:(double)zoomLevel atLatitude:(CLLocationDegrees)latitude atPitch:(CGFloat)pitch; -- (RCTMGLPointAnnotation*)getRCTPointAnnotation:(MGLPointAnnotation*)mglAnnotation; -- (NSArray *)getAllTouchableSources; -- (NSArray *)getAllShapeSources; -- (NSArray *)getAllImages; -- (RCTMGLSource *)getTouchableSourceWithHighestZIndex:(NSArray *)touchableSources; +- (RCTMLNPointAnnotation*)getRCTPointAnnotation:(MLNPointAnnotation*)mlnAnnotation; +- (NSArray *)getAllTouchableSources; +- (NSArray *)getAllShapeSources; +- (NSArray *)getAllImages; +- (RCTMLNSource *)getTouchableSourceWithHighestZIndex:(NSArray *)touchableSources; - (NSString *)takeSnap:(BOOL)writeToDisk; -- (void)didChangeUserTrackingMode:(MGLUserTrackingMode)mode animated:(BOOL)animated; +- (void)didChangeUserTrackingMode:(MLNUserTrackingMode)mode animated:(BOOL)animated; -- (void)waitForLayerWithID:(nonnull NSString*)layerID then:(void (^ _Nonnull)(MGLStyleLayer* _Nonnull layer))foundLayer; +- (void)waitForLayerWithID:(nonnull NSString*)layerID then:(void (^ _Nonnull)(MLNStyleLayer* _Nonnull layer))foundLayer; - (void)setSourceVisibility:(BOOL)visiblity sourceId:(nonnull NSString*)sourceId sourceLayerId:(nullable NSString*)sourceLayerId; diff --git a/ios/RCTMGL/RCTMGLMapView.m b/ios/RCTMLN/RCTMLNMapView.m similarity index 75% rename from ios/RCTMGL/RCTMGLMapView.m rename to ios/RCTMLN/RCTMLNMapView.m index b439cc78b..2706fafe6 100644 --- a/ios/RCTMGL/RCTMGLMapView.m +++ b/ios/RCTMLN/RCTMLNMapView.m @@ -1,21 +1,21 @@ // -// RCTMGLMapView.m -// RCTMGL +// RCTMLNMapView.m +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLMapView.h" +#import "RCTMLNMapView.h" #import "CameraUpdateQueue.h" -#import "RCTMGLUtils.h" +#import "RCTMLNUtils.h" #import "RNMBImageUtils.h" -#import "RCTMGLImages.h" +#import "RCTMLNImages.h" #import -#import "RCTMGLNativeUserLocation.h" -#import "RCTMGLLogging.h" +#import "RCTMLNNativeUserLocation.h" +#import "RCTMLNLogging.h" -@implementation RCTMGLMapView +@implementation RCTMLNMapView { BOOL _pendingInitialLayout; } @@ -38,7 +38,7 @@ - (instancetype)initWithFrame:(CGRect)frame _reactSubviews = [[NSMutableArray alloc] init]; _layerWaiters = [[NSMutableDictionary alloc] init]; _styleWaiters = [[NSMutableArray alloc] init]; - _logging = [[RCTMGLLogging alloc] init]; + _logging = [[RCTMLNLogging alloc] init]; } return self; } @@ -63,7 +63,7 @@ - (void)invalidate } } -- (void)layerAdded:(MGLStyleLayer*) layer +- (void)layerAdded:(MLNStyleLayer*) layer { NSString* layerID = layer.identifier; NSMutableArray* waiters = [_layerWaiters valueForKey:layerID]; @@ -75,9 +75,9 @@ - (void)layerAdded:(MGLStyleLayer*) layer } } -- (void)waitForLayerWithID:(nonnull NSString*)layerID then:(void (^)(MGLStyleLayer* layer))foundLayer { +- (void)waitForLayerWithID:(nonnull NSString*)layerID then:(void (^)(MLNStyleLayer* layer))foundLayer { if (self.style) { - MGLStyleLayer* layer = [self.style layerWithIdentifier:layerID]; + MLNStyleLayer* layer = [self.style layerWithIdentifier:layerID]; if (layer) { foundLayer(layer); } else { @@ -97,7 +97,7 @@ - (void)waitForLayerWithID:(nonnull NSString*)layerID then:(void (^)(MGLStyleLay } } -- (void)getStyle:(void (^)(MGLStyle* style))onStyleLoaded { +- (void)getStyle:(void (^)(MLNStyle* style))onStyleLoaded { if (self.style) { onStyleLoaded(self.style); } else { @@ -116,30 +116,30 @@ - (void)notifyStyleLoaded { - (void) addToMap:(id)subview { - if ([subview isKindOfClass:[RCTMGLSource class]]) { - RCTMGLSource *source = (RCTMGLSource*)subview; + if ([subview isKindOfClass:[RCTMLNSource class]]) { + RCTMLNSource *source = (RCTMLNSource*)subview; source.map = self; - [_sources addObject:(RCTMGLSource*)subview]; - } else if ([subview isKindOfClass:[RCTMGLLight class]]) { - RCTMGLLight *light = (RCTMGLLight*)subview; + [_sources addObject:(RCTMLNSource*)subview]; + } else if ([subview isKindOfClass:[RCTMLNLight class]]) { + RCTMLNLight *light = (RCTMLNLight*)subview; _light = light; _light.map = self; - } else if ([subview isKindOfClass:[RCTMGLNativeUserLocation class]]) { - RCTMGLNativeUserLocation *nativeUserLocation = (RCTMGLNativeUserLocation*)subview; + } else if ([subview isKindOfClass:[RCTMLNNativeUserLocation class]]) { + RCTMLNNativeUserLocation *nativeUserLocation = (RCTMLNNativeUserLocation*)subview; nativeUserLocation.map = self; - } else if ([subview isKindOfClass:[RCTMGLPointAnnotation class]]) { - RCTMGLPointAnnotation *pointAnnotation = (RCTMGLPointAnnotation *)subview; + } else if ([subview isKindOfClass:[RCTMLNPointAnnotation class]]) { + RCTMLNPointAnnotation *pointAnnotation = (RCTMLNPointAnnotation *)subview; pointAnnotation.map = self; [_pointAnnotations addObject:pointAnnotation]; - } else if ([subview isKindOfClass:[RCTMGLCamera class]]) { - RCTMGLCamera *camera = (RCTMGLCamera *)subview; + } else if ([subview isKindOfClass:[RCTMLNCamera class]]) { + RCTMLNCamera *camera = (RCTMLNCamera *)subview; camera.map = self; - } else if ([subview isKindOfClass:[RCTMGLImages class]]) { - RCTMGLImages *images = (RCTMGLImages*)subview; + } else if ([subview isKindOfClass:[RCTMLNImages class]]) { + RCTMLNImages *images = (RCTMLNImages*)subview; images.map = self; [_images addObject:images]; - } else if ([subview isKindOfClass:[RCTMGLLayer class]]) { - RCTMGLLayer *layer = (RCTMGLLayer*)subview; + } else if ([subview isKindOfClass:[RCTMLNLayer class]]) { + RCTMLNLayer *layer = (RCTMLNLayer*)subview; layer.map = self; [_layers addObject:layer]; } else { @@ -153,30 +153,30 @@ - (void) addToMap:(id)subview - (void) removeFromMap:(id)subview { - if ([subview isKindOfClass:[RCTMGLSource class]]) { - RCTMGLSource *source = (RCTMGLSource*)subview; + if ([subview isKindOfClass:[RCTMLNSource class]]) { + RCTMLNSource *source = (RCTMLNSource*)subview; source.map = nil; [_sources removeObject:source]; - } else if ([subview isKindOfClass:[RCTMGLPointAnnotation class]]) { - RCTMGLPointAnnotation *pointAnnotation = (RCTMGLPointAnnotation *)subview; + } else if ([subview isKindOfClass:[RCTMLNPointAnnotation class]]) { + RCTMLNPointAnnotation *pointAnnotation = (RCTMLNPointAnnotation *)subview; pointAnnotation.map = nil; [_pointAnnotations removeObject:pointAnnotation]; - } else if ([subview isKindOfClass:[RCTMGLCamera class]]) { - RCTMGLCamera *camera = (RCTMGLCamera *)subview; + } else if ([subview isKindOfClass:[RCTMLNCamera class]]) { + RCTMLNCamera *camera = (RCTMLNCamera *)subview; camera.map = nil; - } else if ([subview isKindOfClass:[RCTMGLImages class]]) { - RCTMGLImages *images = (RCTMGLImages*)subview; + } else if ([subview isKindOfClass:[RCTMLNImages class]]) { + RCTMLNImages *images = (RCTMLNImages*)subview; images.map = nil; [_images removeObject:images]; - } else if ([subview isKindOfClass:[RCTMGLLayer class]]) { - RCTMGLLayer *layer = (RCTMGLLayer*)subview; + } else if ([subview isKindOfClass:[RCTMLNLayer class]]) { + RCTMLNLayer *layer = (RCTMLNLayer*)subview; layer.map = nil; [_layers removeObject:layer]; - } else if ([subview isKindOfClass:[RCTMGLNativeUserLocation class]]) { - RCTMGLNativeUserLocation *nativeUserLocation = (RCTMGLNativeUserLocation *)subview; + } else if ([subview isKindOfClass:[RCTMLNNativeUserLocation class]]) { + RCTMLNNativeUserLocation *nativeUserLocation = (RCTMLNNativeUserLocation *)subview; nativeUserLocation.map = nil; - } else if ([subview isKindOfClass:[RCTMGLLight class]]) { - RCTMGLLight *light = (RCTMGLLight*)subview; + } else if ([subview isKindOfClass:[RCTMLNLight class]]) { + RCTMLNLight *light = (RCTMLNLight*)subview; light.map = nil; } else { NSArray> *childSubViews = [subview reactSubviews]; @@ -193,16 +193,16 @@ - (void) removeFromMap:(id)subview - (void)setSourceVisibility:(BOOL)visible sourceId:(NSString *)sourceId sourceLayerId:(NSString *)sourceLayerId { __weak typeof(self) weakSelf = self; - [self getStyle:^(MGLStyle *style) { + [self getStyle:^(MLNStyle *style) { __strong typeof(self) strongSelf = weakSelf; - for (MGLStyleLayer *layer in strongSelf.style.layers) { - if ([layer isKindOfClass:[MGLForegroundStyleLayer class]]) { - MGLForegroundStyleLayer *foregroundLayer = (MGLForegroundStyleLayer*)layer; + for (MLNStyleLayer *layer in strongSelf.style.layers) { + if ([layer isKindOfClass:[MLNForegroundStyleLayer class]]) { + MLNForegroundStyleLayer *foregroundLayer = (MLNForegroundStyleLayer*)layer; if (![foregroundLayer.sourceIdentifier isEqualToString:sourceId]) continue; if (sourceLayerId == nil || sourceLayerId.length == 0) { layer.visible = visible; - } else if ([layer isKindOfClass:[MGLVectorStyleLayer class]]) { - MGLVectorStyleLayer *vectorLayer = (MGLVectorStyleLayer*)layer; + } else if ([layer isKindOfClass:[MLNVectorStyleLayer class]]) { + MLNVectorStyleLayer *vectorLayer = (MLNVectorStyleLayer*)layer; if ([vectorLayer.sourceLayerIdentifier isEqualToString:sourceLayerId]) { layer.visible = visible; } @@ -276,20 +276,20 @@ - (void)setReactAttributionPosition:(NSDictionary *)posit NSNumber *top = [position valueForKey:@"top"]; NSNumber *bottom = [position valueForKey:@"bottom"]; if (left != nil && top != nil) { - [self setAttributionButtonPosition:MGLOrnamentPositionTopLeft]; + [self setAttributionButtonPosition:MLNOrnamentPositionTopLeft]; [self setAttributionButtonMargins:CGPointMake([left floatValue], [top floatValue])]; } else if (right != nil && top != nil) { - [self setAttributionButtonPosition:MGLOrnamentPositionTopRight]; + [self setAttributionButtonPosition:MLNOrnamentPositionTopRight]; [self setAttributionButtonMargins:CGPointMake([right floatValue], [top floatValue])]; } else if (bottom != nil && right != nil) { - [self setAttributionButtonPosition:MGLOrnamentPositionBottomRight]; + [self setAttributionButtonPosition:MLNOrnamentPositionBottomRight]; [self setAttributionButtonMargins:CGPointMake([right floatValue], [bottom floatValue])]; } else if (bottom != nil && left != nil) { - [self setAttributionButtonPosition:MGLOrnamentPositionBottomLeft]; + [self setAttributionButtonPosition:MLNOrnamentPositionBottomLeft]; [self setAttributionButtonMargins:CGPointMake([left floatValue], [bottom floatValue])]; } else { - [self setAttributionButtonPosition:MGLOrnamentPositionBottomRight]; - // same as MGLOrnamentDefaultPositionOffset in MGLMapView.mm + [self setAttributionButtonPosition:MLNOrnamentPositionBottomRight]; + // same as MLNOrnamentDefaultPositionOffset in MLNMapView.mm [self setAttributionButtonMargins:CGPointMake(8, 8)]; } @@ -308,19 +308,19 @@ - (void)setReactLogoPosition:(NSDictionary *)logoPosition NSNumber *top = [logoPosition valueForKey:@"top"]; NSNumber *bottom = [logoPosition valueForKey:@"bottom"]; if (left != nil && top != nil) { - [self setLogoViewPosition:MGLOrnamentPositionTopLeft]; + [self setLogoViewPosition:MLNOrnamentPositionTopLeft]; [self setLogoViewMargins:CGPointMake([left floatValue], [top floatValue])]; } else if (right != nil && top != nil) { - [self setLogoViewPosition:MGLOrnamentPositionTopRight]; + [self setLogoViewPosition:MLNOrnamentPositionTopRight]; [self setLogoViewMargins:CGPointMake([right floatValue], [top floatValue])]; } else if (bottom != nil && right != nil) { - [self setLogoViewPosition:MGLOrnamentPositionBottomRight]; + [self setLogoViewPosition:MLNOrnamentPositionBottomRight]; [self setLogoViewMargins:CGPointMake([right floatValue], [bottom floatValue])]; } else if (bottom != nil && left != nil) { - [self setLogoViewPosition:MGLOrnamentPositionBottomLeft]; + [self setLogoViewPosition:MLNOrnamentPositionBottomLeft]; [self setLogoViewMargins:CGPointMake([left floatValue], [bottom floatValue])]; } else { - [self setLogoViewPosition:MGLOrnamentPositionBottomRight]; + [self setLogoViewPosition:MLNOrnamentPositionBottomRight]; [self setLogoViewMargins:CGPointMake(8, 8)]; } @@ -408,11 +408,11 @@ - (NSString *)takeSnap:(BOOL)writeToDisk - (CLLocationDistance)getMetersPerPixelAtLatitude:(double)latitude withZoom:(double)zoomLevel { - double constrainedZoom = [[RCTMGLUtils clamp:[NSNumber numberWithDouble:zoomLevel] + double constrainedZoom = [[RCTMLNUtils clamp:[NSNumber numberWithDouble:zoomLevel] min:[NSNumber numberWithDouble:self.minimumZoomLevel] max:[NSNumber numberWithDouble:self.maximumZoomLevel]] doubleValue]; - double constrainedLatitude = [[RCTMGLUtils clamp:[NSNumber numberWithDouble:latitude] + double constrainedLatitude = [[RCTMLNUtils clamp:[NSNumber numberWithDouble:latitude] min:[NSNumber numberWithDouble:-LAT_MAX] max:[NSNumber numberWithDouble:LAT_MAX]] doubleValue]; @@ -432,25 +432,25 @@ - (CLLocationDistance)altitudeFromZoom:(double)zoomLevel atLatitude:(CLLocationD - (CLLocationDistance)altitudeFromZoom:(double)zoomLevel atLatitude:(CLLocationDegrees)latitude atPitch:(CGFloat)pitch { - return MGLAltitudeForZoomLevel(zoomLevel, pitch, latitude, self.frame.size); + return MLNAltitudeForZoomLevel(zoomLevel, pitch, latitude, self.frame.size); } -- (RCTMGLPointAnnotation*)getRCTPointAnnotation:(MGLPointAnnotation *)mglAnnotation +- (RCTMLNPointAnnotation*)getRCTPointAnnotation:(MLNPointAnnotation *)mlnAnnotation { for (int i = 0; i < _pointAnnotations.count; i++) { - RCTMGLPointAnnotation *rctAnnotation = _pointAnnotations[i]; - if (rctAnnotation.annotation == mglAnnotation) { + RCTMLNPointAnnotation *rctAnnotation = _pointAnnotations[i]; + if (rctAnnotation.annotation == mlnAnnotation) { return rctAnnotation; } } return nil; } -- (NSArray *)getAllTouchableSources +- (NSArray *)getAllTouchableSources { - NSMutableArray *touchableSources = [[NSMutableArray alloc] init]; + NSMutableArray *touchableSources = [[NSMutableArray alloc] init]; - for (RCTMGLSource *source in _sources) { + for (RCTMLNSource *source in _sources) { if (source.hasPressListener) { [touchableSources addObject:source]; } @@ -459,24 +459,24 @@ - (RCTMGLPointAnnotation*)getRCTPointAnnotation:(MGLPointAnnotation *)mglAnnotat return touchableSources; } -- (NSArray*)getAllImages +- (NSArray*)getAllImages { return [_images copy]; } -- (NSArray *)getAllShapeSources +- (NSArray *)getAllShapeSources { - NSMutableArray *shapeSources = [[NSMutableArray alloc] init]; + NSMutableArray *shapeSources = [[NSMutableArray alloc] init]; - for (RCTMGLSource *source in _sources) { - if ([source isKindOfClass:[RCTMGLShapeSource class]]) { + for (RCTMLNSource *source in _sources) { + if ([source isKindOfClass:[RCTMLNShapeSource class]]) { [shapeSources addObject:source]; } } return shapeSources; } -- (RCTMGLSource *)getTouchableSourceWithHighestZIndex:(NSArray *)touchableSources +- (RCTMLNSource *)getTouchableSourceWithHighestZIndex:(NSArray *)touchableSources { if (touchableSources == nil || touchableSources.count == 0) { return nil; @@ -486,8 +486,8 @@ - (RCTMGLSource *)getTouchableSourceWithHighestZIndex:(NSArray * return touchableSources[0]; } - NSMutableDictionary *layerToSoureDict = [[NSMutableDictionary alloc] init]; - for (RCTMGLSource *touchableSource in touchableSources) { + NSMutableDictionary *layerToSoureDict = [[NSMutableDictionary alloc] init]; + for (RCTMLNSource *touchableSource in touchableSources) { NSArray *layerIDs = [touchableSource getLayerIDs]; for (NSString *layerID in layerIDs) { @@ -495,11 +495,11 @@ - (RCTMGLSource *)getTouchableSourceWithHighestZIndex:(NSArray * } } - NSArray *layers = self.style.layers; + NSArray *layers = self.style.layers; for (int i = (int)layers.count - 1; i >= 0; i--) { - MGLStyleLayer *layer = layers[i]; + MLNStyleLayer *layer = layers[i]; - RCTMGLSource *source = layerToSoureDict[layer.identifier]; + RCTMLNSource *source = layerToSoureDict[layer.identifier]; if (source != nil) { return source; } @@ -514,7 +514,7 @@ - (NSURL*)_getStyleURLFromKey:(NSString *)styleURL if (url) { return url; } else if (RCTJSONParse(styleURL, nil)) { - return [RCTMGLUtils styleURLFromStyleJSON:styleURL]; + return [RCTMLNUtils styleURLFromStyleJSON:styleURL]; } return url; } @@ -524,12 +524,12 @@ - (void)_removeAllSourcesFromMap if (self.style == nil || _sources.count == 0) { return; } - for (RCTMGLSource *source in _sources) { + for (RCTMLNSource *source in _sources) { source.map = nil; } } -- (void)didChangeUserTrackingMode:(MGLUserTrackingMode)mode animated:(BOOL)animated { +- (void)didChangeUserTrackingMode:(MLNUserTrackingMode)mode animated:(BOOL)animated { [_reactCamera didChangeUserTrackingMode:mode animated:animated]; } diff --git a/ios/RCTMGL/RCTMGLMapViewManager.h b/ios/RCTMLN/RCTMLNMapViewManager.h similarity index 71% rename from ios/RCTMGL/RCTMGLMapViewManager.h rename to ios/RCTMLN/RCTMLNMapViewManager.h index b2ca19a9f..d59999ea6 100644 --- a/ios/RCTMGL/RCTMGLMapViewManager.h +++ b/ios/RCTMLN/RCTMLNMapViewManager.h @@ -1,15 +1,15 @@ // -// RCTMGLMapViewManager.h -// RCTMGL +// RCTMLNMapViewManager.h +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import "ViewManager.h" -@import Mapbox; +@import MapLibre; -@interface RCTMGLMapViewManager : ViewManager +@interface RCTMLNMapViewManager : ViewManager - (void)didTapMap:(UITapGestureRecognizer *)recognizer; - (void)didLongPressMap:(UILongPressGestureRecognizer *)recognizer; diff --git a/ios/RCTMGL/RCTMGLMapViewManager.m b/ios/RCTMLN/RCTMLNMapViewManager.m similarity index 72% rename from ios/RCTMGL/RCTMGLMapViewManager.m rename to ios/RCTMLN/RCTMLNMapViewManager.m index d7d298583..d0f13bcae 100644 --- a/ios/RCTMGL/RCTMGLMapViewManager.m +++ b/ios/RCTMLN/RCTMLNMapViewManager.m @@ -1,6 +1,6 @@ // -// RCTMGLMapViewManager.m -// RCTMGL +// RCTMLNMapViewManager.m +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,25 +8,25 @@ #import -#import "RCTMGLMapViewManager.h" -#import "RCTMGLMapView.h" -#import "RCTMGLEventTypes.h" -#import "RCTMGLEvent.h" -#import "RCTMGLMapTouchEvent.h" -#import "RCTMGLUtils.h" +#import "RCTMLNMapViewManager.h" +#import "RCTMLNMapView.h" +#import "RCTMLNEventTypes.h" +#import "RCTMLNEvent.h" +#import "RCTMLNMapTouchEvent.h" +#import "RCTMLNUtils.h" #import "CameraStop.h" #import "CameraUpdateQueue.h" -#import "RCTMGLUserLocation.h" +#import "RCTMLNUserLocation.h" #import "FilterParser.h" -#import "RCTMGLImages.h" +#import "RCTMLNImages.h" -@interface RCTMGLMapViewManager() +@interface RCTMLNMapViewManager() @end -@implementation RCTMGLMapViewManager +@implementation RCTMLNMapViewManager -RCT_EXPORT_MODULE(RCTMGLMapView) +RCT_EXPORT_MODULE(RCTMLNMapView) - (BOOL)requiresMainQueueSetup { @@ -42,7 +42,7 @@ - (CGRect)defaultFrame - (UIView *)view { - RCTMGLMapView *mapView = [[RCTMGLMapView alloc] initWithFrame:[self defaultFrame]]; + RCTMLNMapView *mapView = [[RCTMLNMapView alloc] initWithFrame:[self defaultFrame]]; mapView.delegate = self; @@ -107,12 +107,12 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } - RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; + RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; CGPoint pointInView = [reactMapView convertCoordinate:CLLocationCoordinate2DMake([coordinate[1] doubleValue], [coordinate[0] doubleValue]) toPointToView:reactMapView]; @@ -129,12 +129,12 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } - RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; + RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; CLLocationCoordinate2D coordinate = [reactMapView convertPoint:point toCoordinateFromView:reactMapView]; @@ -152,12 +152,12 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } - RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; + RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; NSString *uri = [reactMapView takeSnap:writeToDisk]; resolve(@{ @"uri": uri }); }]; @@ -170,13 +170,13 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } - RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; - resolve(@{ @"visibleBounds": [RCTMGLUtils fromCoordinateBounds:reactMapView.visibleCoordinateBounds] }); + RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; + resolve(@{ @"visibleBounds": [RCTMLNUtils fromCoordinateBounds:reactMapView.visibleCoordinateBounds] }); }]; } @@ -187,12 +187,12 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } - RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; + RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; resolve(@{ @"zoom": @(reactMapView.zoomLevel) }); }]; } @@ -204,12 +204,12 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } - RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; + RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; resolve(@{ @"center": @[@(reactMapView.centerCoordinate.longitude), @(reactMapView.centerCoordinate.latitude)]}); }]; } @@ -224,8 +224,8 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } @@ -234,9 +234,9 @@ - (UIView *)view layerIDSet = [NSSet setWithArray:layerIDs]; } - RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; + RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; NSPredicate* predicate = [FilterParser parse:filter]; - NSArray> *shapes = [reactMapView visibleFeaturesAtPoint:CGPointMake([point[0] floatValue], [point[1] floatValue]) + NSArray> *shapes = [reactMapView visibleFeaturesAtPoint:CGPointMake([point[0] floatValue], [point[1] floatValue]) inStyleLayersWithIdentifiers:layerIDSet predicate:predicate]; @@ -261,12 +261,12 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } - RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; + RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; // bbox[top, right, bottom, left] CGFloat width = [bbox[1] floatValue] - [bbox[3] floatValue]; @@ -279,7 +279,7 @@ - (UIView *)view } NSPredicate* predicate = [FilterParser parse:filter]; - NSArray> *shapes = [reactMapView visibleFeaturesInRect:rect + NSArray> *shapes = [reactMapView visibleFeaturesInRect:rect inStyleLayersWithIdentifiers:layerIDSet predicate:predicate]; @@ -296,12 +296,12 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } - __weak RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; + __weak RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; [reactMapView showAttribution:reactMapView]; resolve(nil); }]; @@ -317,12 +317,12 @@ - (UIView *)view [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { id view = viewRegistry[reactTag]; - if (![view isKindOfClass:[RCTMGLMapView class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![view isKindOfClass:[RCTMLNMapView class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } - __weak RCTMGLMapView *reactMapView = (RCTMGLMapView*)view; + __weak RCTMLNMapView *reactMapView = (RCTMLNMapView*)view; [reactMapView setSourceVisibility:visible sourceId:sourceId sourceLayerId:sourceLayerId]; resolve(nil); }]; @@ -332,13 +332,13 @@ - (UIView *)view - (void)didTapMap:(UITapGestureRecognizer *)recognizer { - RCTMGLMapView *mapView = (RCTMGLMapView*)recognizer.view; + RCTMLNMapView *mapView = (RCTMLNMapView*)recognizer.view; CGPoint screenPoint = [recognizer locationInView:mapView]; - NSArray *touchableSources = [mapView getAllTouchableSources]; + NSArray *touchableSources = [mapView getAllTouchableSources]; - NSMutableDictionary>* > *hits = [[NSMutableDictionary alloc] init]; - NSMutableArray *hitTouchableSources = [[NSMutableArray alloc] init]; - for (RCTMGLSource *touchableSource in touchableSources) { + NSMutableDictionary>* > *hits = [[NSMutableDictionary alloc] init]; + NSMutableArray *hitTouchableSources = [[NSMutableArray alloc] init]; + for (RCTMLNSource *touchableSource in touchableSources) { NSDictionary *hitbox = touchableSource.hitbox; float halfWidth = [hitbox[@"width"] floatValue] / 2.f; float halfHeight = [hitbox[@"height"] floatValue] / 2.f; @@ -347,7 +347,7 @@ - (void)didTapMap:(UITapGestureRecognizer *)recognizer CGFloat left = screenPoint.x - halfWidth; CGRect hitboxRect = CGRectMake(left, top, [hitbox[@"width"] floatValue], [hitbox[@"height"] floatValue]); - NSArray> *features = [mapView visibleFeaturesInRect:hitboxRect + NSArray> *features = [mapView visibleFeaturesInRect:hitboxRect inStyleLayersWithIdentifiers:[NSSet setWithArray:[touchableSource getLayerIDs]] predicate:nil]; @@ -358,19 +358,19 @@ - (void)didTapMap:(UITapGestureRecognizer *)recognizer } if (hits.count > 0) { - RCTMGLSource *source = [mapView getTouchableSourceWithHighestZIndex:hitTouchableSources]; + RCTMLNSource *source = [mapView getTouchableSourceWithHighestZIndex:hitTouchableSources]; if (source != nil && source.hasPressListener) { NSArray* geoJSONDicts = [self featuresToJSON: hits[source.id]]; NSString *eventType = RCT_MAPBOX_VECTOR_SOURCE_LAYER_PRESS; - if ([source isKindOfClass:[RCTMGLShapeSource class]]) { + if ([source isKindOfClass:[RCTMLNShapeSource class]]) { eventType = RCT_MAPBOX_SHAPE_SOURCE_LAYER_PRESS; } CLLocationCoordinate2D coordinate = [mapView convertPoint:screenPoint toCoordinateFromView:mapView]; - RCTMGLEvent *event = [RCTMGLEvent makeEvent:eventType withPayload: @{ + RCTMLNEvent *event = [RCTMLNEvent makeEvent:eventType withPayload: @{ @"features": geoJSONDicts, @"point": @{ @"x": [NSNumber numberWithDouble: screenPoint.x], @@ -390,62 +390,62 @@ - (void)didTapMap:(UITapGestureRecognizer *)recognizer return; } - RCTMGLMapTouchEvent *event = [RCTMGLMapTouchEvent makeTapEvent:mapView withPoint:screenPoint]; + RCTMLNMapTouchEvent *event = [RCTMLNMapTouchEvent makeTapEvent:mapView withPoint:screenPoint]; [self fireEvent:event withCallback:mapView.onPress]; } - (void)didLongPressMap:(UILongPressGestureRecognizer *)recognizer { - RCTMGLMapView *mapView = (RCTMGLMapView*)recognizer.view; + RCTMLNMapView *mapView = (RCTMLNMapView*)recognizer.view; if (mapView == nil || mapView.onPress == nil || recognizer.state != UIGestureRecognizerStateBegan) { return; } - RCTMGLMapTouchEvent *event = [RCTMGLMapTouchEvent makeLongPressEvent:mapView withPoint:[recognizer locationInView:mapView]]; + RCTMLNMapTouchEvent *event = [RCTMLNMapTouchEvent makeLongPressEvent:mapView withPoint:[recognizer locationInView:mapView]]; [self fireEvent:event withCallback:mapView.onLongPress]; } -#pragma mark - MGLMapViewDelegate +#pragma mark - MLNMapViewDelegate -- (MGLAnnotationView *)mapView:(MGLMapView *)mapView viewForAnnotation:(id)annotation +- (MLNAnnotationView *)mapView:(MLNMapView *)mapView viewForAnnotation:(id)annotation { - if ([annotation isKindOfClass:[MGLUserLocation class]] && mapView.userLocation != nil) { - RCTMGLMapView* reactMapView = ((RCTMGLMapView *) mapView); + if ([annotation isKindOfClass:[MLNUserLocation class]] && mapView.userLocation != nil) { + RCTMLNMapView* reactMapView = ((RCTMLNMapView *) mapView); if (reactMapView.useNativeUserLocationAnnotationView) { return nil; } - return [[RCTMGLUserLocation sharedInstance] hiddenUserAnnotation]; + return [[RCTMLNUserLocation sharedInstance] hiddenUserAnnotation]; } - else if ([annotation isKindOfClass:[RCTMGLPointAnnotation class]]) { - RCTMGLPointAnnotation *rctAnnotation = (RCTMGLPointAnnotation *)annotation; + else if ([annotation isKindOfClass:[RCTMLNPointAnnotation class]]) { + RCTMLNPointAnnotation *rctAnnotation = (RCTMLNPointAnnotation *)annotation; return [rctAnnotation getAnnotationView]; } return nil; } -- (void)mapView:(MGLMapView *)mapView didChangeUserTrackingMode:(MGLUserTrackingMode)mode animated:(BOOL)animated +- (void)mapView:(MLNMapView *)mapView didChangeUserTrackingMode:(MLNUserTrackingMode)mode animated:(BOOL)animated { - RCTMGLMapView* reactMapView = ((RCTMGLMapView *) mapView); + RCTMLNMapView* reactMapView = ((RCTMLNMapView *) mapView); [reactMapView didChangeUserTrackingMode:mode animated:animated]; } -- (void)mapView:(MGLMapView *)mapView didSelectAnnotation:(nonnull id)annotation +- (void)mapView:(MLNMapView *)mapView didSelectAnnotation:(nonnull id)annotation { - if ([annotation isKindOfClass:[RCTMGLPointAnnotation class]]) { - RCTMGLPointAnnotation *rctAnnotation = (RCTMGLPointAnnotation *)annotation; + if ([annotation isKindOfClass:[RCTMLNPointAnnotation class]]) { + RCTMLNPointAnnotation *rctAnnotation = (RCTMLNPointAnnotation *)annotation; if (rctAnnotation.onSelected != nil) { - RCTMGLMapTouchEvent *event = [RCTMGLMapTouchEvent makeAnnotationTapEvent:rctAnnotation]; + RCTMLNMapTouchEvent *event = [RCTMLNMapTouchEvent makeAnnotationTapEvent:rctAnnotation]; rctAnnotation.onSelected([event toJSON]); } } } -- (void)mapView:(MGLMapView *)mapView didDeselectAnnotation:(nonnull id)annotation +- (void)mapView:(MLNMapView *)mapView didDeselectAnnotation:(nonnull id)annotation { - if ([annotation isKindOfClass:[RCTMGLPointAnnotation class]]) { - RCTMGLPointAnnotation *rctAnnotation = (RCTMGLPointAnnotation *)annotation; + if ([annotation isKindOfClass:[RCTMLNPointAnnotation class]]) { + RCTMLNPointAnnotation *rctAnnotation = (RCTMLNPointAnnotation *)annotation; if (rctAnnotation.onDeselected != nil) { rctAnnotation.onDeselected(nil); @@ -453,75 +453,75 @@ - (void)mapView:(MGLMapView *)mapView didDeselectAnnotation:(nonnull id)annotation { - if ([annotation isKindOfClass:[RCTMGLPointAnnotation class]]) { - RCTMGLPointAnnotation *rctAnnotation = (RCTMGLPointAnnotation *)annotation; +- (BOOL)mapView:(MLNMapView *)mapView annotationCanShowCallout:(id)annotation { + if ([annotation isKindOfClass:[RCTMLNPointAnnotation class]]) { + RCTMLNPointAnnotation *rctAnnotation = (RCTMLNPointAnnotation *)annotation; return rctAnnotation.calloutView != nil; } return NO; } -- (UIView *)mapView:(MGLMapView *)mapView calloutViewForAnnotation:(id)annotation +- (UIView *)mapView:(MLNMapView *)mapView calloutViewForAnnotation:(id)annotation { - if ([annotation isKindOfClass:[RCTMGLPointAnnotation class]]) { - RCTMGLPointAnnotation *rctAnnotation = (RCTMGLPointAnnotation *)annotation; + if ([annotation isKindOfClass:[RCTMLNPointAnnotation class]]) { + RCTMLNPointAnnotation *rctAnnotation = (RCTMLNPointAnnotation *)annotation; return rctAnnotation.calloutView; } return nil; } -- (BOOL)mapView:(MGLMapView *)mapView shouldChangeFromCamera:(MGLMapCamera *)oldCamera toCamera:(MGLMapCamera *)newCamera +- (BOOL)mapView:(MLNMapView *)mapView shouldChangeFromCamera:(MLNMapCamera *)oldCamera toCamera:(MLNMapCamera *)newCamera { - RCTMGLMapView* reactMapView = ((RCTMGLMapView *) mapView); - return MGLCoordinateBoundsIsEmpty(reactMapView.maxBounds) || MGLCoordinateInCoordinateBounds(newCamera.centerCoordinate, reactMapView.maxBounds); + RCTMLNMapView* reactMapView = ((RCTMLNMapView *) mapView); + return MLNCoordinateBoundsIsEmpty(reactMapView.maxBounds) || MLNCoordinateInCoordinateBounds(newCamera.centerCoordinate, reactMapView.maxBounds); } -- (void)mapView:(MGLMapView *)mapView regionWillChangeWithReason:(MGLCameraChangeReason)reason animated:(BOOL)animated +- (void)mapView:(MLNMapView *)mapView regionWillChangeWithReason:(MLNCameraChangeReason)reason animated:(BOOL)animated { - ((RCTMGLMapView *) mapView).isUserInteraction = (BOOL)(reason & ~MGLCameraChangeReasonProgrammatic); + ((RCTMLNMapView *) mapView).isUserInteraction = (BOOL)(reason & ~MLNCameraChangeReasonProgrammatic); NSDictionary *payload = [self _makeRegionPayload:mapView animated:animated]; [self reactMapDidChange:mapView eventType:RCT_MAPBOX_REGION_WILL_CHANGE_EVENT andPayload:payload]; } -- (void)mapViewRegionIsChanging:(MGLMapView *)mapView +- (void)mapViewRegionIsChanging:(MLNMapView *)mapView { NSDictionary *payload = [self _makeRegionPayload:mapView animated:false]; [self reactMapDidChange:mapView eventType:RCT_MAPBOX_REGION_IS_CHANGING andPayload:payload]; } -- (void)mapView:(MGLMapView *)mapView regionDidChangeWithReason:(MGLCameraChangeReason)reason animated:(BOOL)animated +- (void)mapView:(MLNMapView *)mapView regionDidChangeWithReason:(MLNCameraChangeReason)reason animated:(BOOL)animated { - if (((reason & MGLCameraChangeReasonTransitionCancelled) == MGLCameraChangeReasonTransitionCancelled) - && ((reason & MGLCameraChangeReasonGesturePan) != MGLCameraChangeReasonGesturePan)) return; + if (((reason & MLNCameraChangeReasonTransitionCancelled) == MLNCameraChangeReasonTransitionCancelled) + && ((reason & MLNCameraChangeReasonGesturePan) != MLNCameraChangeReasonGesturePan)) return; - ((RCTMGLMapView *) mapView).isUserInteraction = (BOOL)(reason & ~MGLCameraChangeReasonProgrammatic); + ((RCTMLNMapView *) mapView).isUserInteraction = (BOOL)(reason & ~MLNCameraChangeReasonProgrammatic); NSDictionary *payload = [self _makeRegionPayload:mapView animated:animated]; [self reactMapDidChange:mapView eventType:RCT_MAPBOX_REGION_DID_CHANGE andPayload:payload]; } -- (void)mapViewWillStartLoadingMap:(MGLMapView *)mapView +- (void)mapViewWillStartLoadingMap:(MLNMapView *)mapView { [self reactMapDidChange:mapView eventType:RCT_MAPBOX_WILL_START_LOADING_MAP]; } -- (void)mapViewDidFinishLoadingMap:(MGLMapView *)mapView +- (void)mapViewDidFinishLoadingMap:(MLNMapView *)mapView { [self reactMapDidChange:mapView eventType:RCT_MAPBOX_DID_FINISH_LOADING_MAP]; } -- (void)mapViewDidFailLoadingMap:(MGLMapView *)mapView withError:(NSError *)error +- (void)mapViewDidFailLoadingMap:(MLNMapView *)mapView withError:(NSError *)error { NSLog(@"Failed loading map %@", error); [self reactMapDidChange:mapView eventType:RCT_MAPBOX_DID_FAIL_LOADING_MAP]; } -- (void)mapViewWillStartRenderingFrame:(MGLMapView *)mapView +- (void)mapViewWillStartRenderingFrame:(MLNMapView *)mapView { [self reactMapDidChange:mapView eventType:RCT_MAPBOX_WILL_START_RENDERING_FRAME]; } -- (void)mapViewDidFinishRenderingFrame:(MGLMapView *)mapView fullyRendered:(BOOL)fullyRendered +- (void)mapViewDidFinishRenderingFrame:(MLNMapView *)mapView fullyRendered:(BOOL)fullyRendered { if (fullyRendered) { [self reactMapDidChange:mapView eventType:RCT_MAPBOX_DID_FINISH_RENDERING_FRAME_FULLY]; @@ -530,12 +530,12 @@ - (void)mapViewDidFinishRenderingFrame:(MGLMapView *)mapView fullyRendered:(BOOL } } -- (void)mapViewWillStartRenderingMap:(MGLMapView *)mapView +- (void)mapViewWillStartRenderingMap:(MLNMapView *)mapView { [self reactMapDidChange:mapView eventType:RCT_MAPBOX_WILL_START_RENDERING_MAP]; } -- (void)mapViewDidFinishRenderingMap:(MGLMapView *)mapView fullyRendered:(BOOL)fullyRendered +- (void)mapViewDidFinishRenderingMap:(MLNMapView *)mapView fullyRendered:(BOOL)fullyRendered { if (fullyRendered) { [self reactMapDidChange:mapView eventType:RCT_MAPBOX_DID_FINISH_RENDERING_MAP_FULLY]; @@ -544,19 +544,19 @@ - (void)mapViewDidFinishRenderingMap:(MGLMapView *)mapView fullyRendered:(BOOL)f } } -- (void)mapView:(MGLMapView *)mapView didFinishLoadingStyle:(MGLStyle *)style +- (void)mapView:(MLNMapView *)mapView didFinishLoadingStyle:(MLNStyle *)style { - RCTMGLMapView *reactMapView = (RCTMGLMapView*)mapView; + RCTMLNMapView *reactMapView = (RCTMLNMapView*)mapView; if(reactMapView.reactLocalizeLabels == true) { [style localizeLabelsIntoLocale:nil]; } for (int i = 0; i < reactMapView.sources.count; i++) { - RCTMGLSource *source = reactMapView.sources[i]; + RCTMLNSource *source = reactMapView.sources[i]; source.map = reactMapView; } for (int i = 0; i < reactMapView.layers.count; i++) { - RCTMGLLayer *layer = reactMapView.layers[i]; + RCTMLNLayer *layer = reactMapView.layers[i]; layer.map = reactMapView; } @@ -568,39 +568,39 @@ - (void)mapView:(MGLMapView *)mapView didFinishLoadingStyle:(MGLStyle *)style [self reactMapDidChange:reactMapView eventType:RCT_MAPBOX_DID_FINISH_LOADING_STYLE]; } --(UIImage *)mapView:(MGLMapView *)mapView didFailToLoadImage:(NSString *)imageName +-(UIImage *)mapView:(MLNMapView *)mapView didFailToLoadImage:(NSString *)imageName { - RCTMGLMapView* reactMapView = ((RCTMGLMapView *) mapView); - NSArray *allImages = [reactMapView getAllImages]; - for (RCTMGLImages *images in allImages) { + RCTMLNMapView* reactMapView = ((RCTMLNMapView *) mapView); + NSArray *allImages = [reactMapView getAllImages]; + for (RCTMLNImages *images in allImages) { if([images addMissingImageToStyle:imageName]) { // The image was added inside addMissingImageToStyle so we can return nil return nil; } } - for (RCTMGLImages *images in allImages) { + for (RCTMLNImages *images in allImages) { [images sendImageMissingEvent:imageName]; } return nil; } -- (void)reactMapDidChange:(MGLMapView*)mapView eventType:(NSString*)type +- (void)reactMapDidChange:(MLNMapView*)mapView eventType:(NSString*)type { [self reactMapDidChange:mapView eventType:type andPayload:nil]; } -- (void)reactMapDidChange:(MGLMapView*)mapView eventType:(NSString*)type andPayload:(NSDictionary*)payload +- (void)reactMapDidChange:(MLNMapView*)mapView eventType:(NSString*)type andPayload:(NSDictionary*)payload { - RCTMGLMapView *reactMapView = (RCTMGLMapView*)mapView; - RCTMGLEvent *event = [RCTMGLEvent makeEvent:type withPayload:payload]; + RCTMLNMapView *reactMapView = (RCTMLNMapView*)mapView; + RCTMLNEvent *event = [RCTMLNEvent makeEvent:type withPayload:payload]; [self fireEvent:event withCallback:reactMapView.onMapChange]; } -- (NSDictionary*)_makeRegionPayload:(MGLMapView*)mapView animated:(BOOL)animated +- (NSDictionary*)_makeRegionPayload:(MLNMapView*)mapView animated:(BOOL)animated { - RCTMGLMapView *rctMapView = (RCTMGLMapView *)mapView; - MGLPointFeature *feature = [[MGLPointFeature alloc] init]; + RCTMLNMapView *rctMapView = (RCTMLNMapView *)mapView; + MLNPointFeature *feature = [[MLNPointFeature alloc] init]; feature.coordinate = mapView.centerCoordinate; feature.attributes = @{ @"zoomLevel": [NSNumber numberWithDouble:mapView.zoomLevel], @@ -608,15 +608,15 @@ - (NSDictionary*)_makeRegionPayload:(MGLMapView*)mapView animated:(BOOL)animated @"pitch": [NSNumber numberWithDouble:mapView.camera.pitch], @"animated": [NSNumber numberWithBool:animated], @"isUserInteraction": @(rctMapView.isUserInteraction), - @"visibleBounds": [RCTMGLUtils fromCoordinateBounds:mapView.visibleCoordinateBounds] + @"visibleBounds": [RCTMLNUtils fromCoordinateBounds:mapView.visibleCoordinateBounds] }; return feature.geoJSONDictionary; } -- (NSArray *) featuresToJSON:(NSArray> *) features +- (NSArray *) featuresToJSON:(NSArray> *) features { NSMutableArray *json = [[NSMutableArray alloc] init]; - for(id feature in features) { + for(id feature in features) { [json addObject:feature.geoJSONDictionary]; } return json; diff --git a/ios/RCTMGL/RCTMGLNativeUserLocation.h b/ios/RCTMLN/RCTMLNNativeUserLocation.h similarity index 60% rename from ios/RCTMGL/RCTMGLNativeUserLocation.h rename to ios/RCTMLN/RCTMLNNativeUserLocation.h index 25d54729a..96a18fcc0 100644 --- a/ios/RCTMGL/RCTMGLNativeUserLocation.h +++ b/ios/RCTMLN/RCTMLNNativeUserLocation.h @@ -1,6 +1,6 @@ // -// RCTMGLCamera.h -// RCTMGL +// RCTMLNCamera.h +// RCTMLN // // Created by Nick Italiano on 6/22/18. // Copyright © 2018 Mapbox Inc. All rights reserved. @@ -8,11 +8,11 @@ #import #import -@class RCTMGLMapView; +@class RCTMLNMapView; -@interface RCTMGLNativeUserLocation : UIView +@interface RCTMLNNativeUserLocation : UIView -@property (nonatomic, strong) RCTMGLMapView *map; +@property (nonatomic, strong) RCTMLNMapView *map; @property (nonatomic) BOOL iosShowsUserHeadingIndicator; @end diff --git a/ios/RCTMGL/RCTMGLNativeUserLocation.m b/ios/RCTMLN/RCTMLNNativeUserLocation.m similarity index 78% rename from ios/RCTMGL/RCTMGLNativeUserLocation.m rename to ios/RCTMLN/RCTMLNNativeUserLocation.m index 6bff97405..9c6a8b7a2 100644 --- a/ios/RCTMGL/RCTMGLNativeUserLocation.m +++ b/ios/RCTMLN/RCTMLNNativeUserLocation.m @@ -1,27 +1,27 @@ // -// RCTMGLCamera.m -// RCTMGL +// RCTMLNCamera.m +// RCTMLN // // Created by Nick Italiano on 6/22/18. // Copyright © 2018 Mapbox Inc. All rights reserved. // -#import "RCTMGLNativeUserLocation.h" +#import "RCTMLNNativeUserLocation.h" #import "CameraStop.h" #import "CameraUpdateQueue.h" -#import "RCTMGLLocation.h" -#import "RCTMGLUtils.h" -#import "RCTMGLLocationManager.h" -#import "RCTMGLEvent.h" -#import "RCTMGLEventTypes.h" +#import "RCTMLNLocation.h" +#import "RCTMLNUtils.h" +#import "RCTMLNLocationManager.h" +#import "RCTMLNEvent.h" +#import "RCTMLNEventTypes.h" #import "CameraMode.h" -@implementation RCTMGLNativeUserLocation +@implementation RCTMLNNativeUserLocation { } -- (void)setMap:(RCTMGLMapView *)map +- (void)setMap:(RCTMLNMapView *)map { if (map == nil && _map) { _map.useNativeUserLocationAnnotationView = NO; diff --git a/ios/RCTMLN/RCTMLNNativeUserLocationManager.h b/ios/RCTMLN/RCTMLNNativeUserLocationManager.h new file mode 100644 index 000000000..3e1efbdcd --- /dev/null +++ b/ios/RCTMLN/RCTMLNNativeUserLocationManager.h @@ -0,0 +1,5 @@ +#import "ViewManager.h" + +@interface RCTMLNNativeUserLocationManager : ViewManager + +@end diff --git a/ios/RCTMLN/RCTMLNNativeUserLocationManager.m b/ios/RCTMLN/RCTMLNNativeUserLocationManager.m new file mode 100644 index 000000000..c2146fe05 --- /dev/null +++ b/ios/RCTMLN/RCTMLNNativeUserLocationManager.m @@ -0,0 +1,25 @@ +#import "RCTMLNNativeUserLocationManager.h" +#import "RCTMLNNativeUserLocation.h" + +@implementation RCTMLNNativeUserLocationManager + +RCT_EXPORT_MODULE(RCTMLNNativeUserLocation) +RCT_EXPORT_VIEW_PROPERTY(iosShowsUserHeadingIndicator, BOOL) + + +#pragma - View Properties + + +#pragma Methods + +- (BOOL)requiresMainQueueSetup +{ + return YES; +} + +- (UIView *)view +{ + return [[RCTMLNNativeUserLocation alloc] init]; +} + +@end diff --git a/ios/RCTMGL/RCTMGLPointAnnotation.h b/ios/RCTMLN/RCTMLNPointAnnotation.h similarity index 76% rename from ios/RCTMGL/RCTMGLPointAnnotation.h rename to ios/RCTMLN/RCTMLNPointAnnotation.h index 1fdd014a6..d458201f6 100644 --- a/ios/RCTMGL/RCTMGLPointAnnotation.h +++ b/ios/RCTMLN/RCTMLNPointAnnotation.h @@ -1,6 +1,6 @@ // -// RCTMGLPointAnnotation.h -// RCTMGL +// RCTMLNPointAnnotation.h +// RCTMLN // // Created by Nick Italiano on 10/12/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -9,14 +9,14 @@ #import #import #import -#import "RCTMGLCallout.h" +#import "RCTMLNCallout.h" -@import Mapbox; +@import MapLibre; -@interface RCTMGLPointAnnotation : MGLAnnotationView +@interface RCTMLNPointAnnotation : MLNAnnotationView -@property (nonatomic, weak) MGLMapView *map; -@property (nonatomic, strong) RCTMGLCallout *calloutView; +@property (nonatomic, weak) MLNMapView *map; +@property (nonatomic, strong) RCTMLNCallout *calloutView; @property (nonatomic, copy) NSString *id; @property (nonatomic, copy) NSString *reactTitle; @@ -36,6 +36,6 @@ @property (nonatomic, assign) BOOL reactSelected; @property (nonatomic, assign) BOOL reactDraggable; -- (MGLAnnotationView *)getAnnotationView; +- (MLNAnnotationView *)getAnnotationView; @end diff --git a/ios/RCTMGL/RCTMGLPointAnnotation.m b/ios/RCTMLN/RCTMLNPointAnnotation.m similarity index 83% rename from ios/RCTMGL/RCTMGLPointAnnotation.m rename to ios/RCTMLN/RCTMLNPointAnnotation.m index 57621c3b1..6fda2c048 100644 --- a/ios/RCTMGL/RCTMGLPointAnnotation.m +++ b/ios/RCTMLN/RCTMLNPointAnnotation.m @@ -1,20 +1,20 @@ // -// RCTMGLPointAnnotation.m -// RCTMGL +// RCTMLNPointAnnotation.m +// RCTMLN // // Created by Nick Italiano on 10/12/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLPointAnnotation.h" -#import "RCTMGLMapTouchEvent.h" -#import "RCTMGLUtils.h" +#import "RCTMLNPointAnnotation.h" +#import "RCTMLNMapTouchEvent.h" +#import "RCTMLNUtils.h" #import const float CENTER_X_OFFSET_BASE = -0.5f; const float CENTER_Y_OFFSET_BASE = -0.5f; -@implementation RCTMGLPointAnnotation +@implementation RCTMLNPointAnnotation { UITapGestureRecognizer *customViewTap; } @@ -29,8 +29,8 @@ - (id)init - (void)insertReactSubview:(UIView *)subview atIndex:(NSInteger)atIndex { - if ([subview isKindOfClass:[RCTMGLCallout class]]) { - self.calloutView = (RCTMGLCallout *)subview; + if ([subview isKindOfClass:[RCTMLNCallout class]]) { + self.calloutView = (RCTMLNCallout *)subview; self.calloutView.representedObject = self; } else { [super insertReactSubview:subview atIndex:0]; @@ -39,7 +39,7 @@ - (void)insertReactSubview:(UIView *)subview atIndex:(NSInteger)atIndex - (void)removeReactSubview:(UIView *)subview { - if ([subview isKindOfClass:[RCTMGLCallout class]]) { + if ([subview isKindOfClass:[RCTMLNCallout class]]) { self.calloutView = nil; } else { [super removeReactSubview:subview]; @@ -62,7 +62,7 @@ - (void)setAnchor:(NSDictionary *)anchor [self _setCenterOffset:self.frame]; } -- (void)setMap:(MGLMapView *)map +- (void)setMap:(MLNMapView *)map { if (map == nil) { [_map removeAnnotation:self]; @@ -125,7 +125,7 @@ - (NSString *)toolTip return _reactTitle; } -- (MGLAnnotationView *)getAnnotationView +- (MLNAnnotationView *)getAnnotationView { if (self.reactSubviews.count == 0) { // default pin view @@ -189,7 +189,7 @@ - (void)_updateCoordinate return; } - MGLPointFeature *feature = (MGLPointFeature *)[RCTMGLUtils shapeFromGeoJSON:_reactCoordinate]; + MLNPointFeature *feature = (MLNPointFeature *)[RCTMLNUtils shapeFromGeoJSON:_reactCoordinate]; if (feature == nil) { return; } @@ -216,34 +216,34 @@ - (BOOL)_isFrameSet return self.frame.size.width > 0 && self.frame.size.height > 0; } -- (void)setDragState:(MGLAnnotationViewDragState)dragState animated:(BOOL)animated { +- (void)setDragState:(MLNAnnotationViewDragState)dragState animated:(BOOL)animated { [super setDragState:dragState animated:animated]; switch (dragState) { - case MGLAnnotationViewDragStateStarting: { + case MLNAnnotationViewDragStateStarting: { if (self.onDragStart != nil) { - RCTMGLMapTouchEvent *event = [RCTMGLMapTouchEvent makeAnnotationTapEvent:self]; + RCTMLNMapTouchEvent *event = [RCTMLNMapTouchEvent makeAnnotationTapEvent:self]; self.onDragStart([event toJSON]); } break; } - case MGLAnnotationViewDragStateDragging: + case MLNAnnotationViewDragStateDragging: if (self.onDrag != nil) { - RCTMGLMapTouchEvent *event = [RCTMGLMapTouchEvent makeAnnotationTapEventOnDrag:self]; + RCTMLNMapTouchEvent *event = [RCTMLNMapTouchEvent makeAnnotationTapEventOnDrag:self]; self.onDrag([event toJSON]); } break; - case MGLAnnotationViewDragStateEnding: - case MGLAnnotationViewDragStateCanceling: { + case MLNAnnotationViewDragStateEnding: + case MLNAnnotationViewDragStateCanceling: { if (self.onDragEnd != nil) { - RCTMGLMapTouchEvent *event = [RCTMGLMapTouchEvent makeAnnotationTapEvent:self]; + RCTMLNMapTouchEvent *event = [RCTMLNMapTouchEvent makeAnnotationTapEvent:self]; self.onDragEnd([event toJSON]); } break; } - case MGLAnnotationViewDragStateNone: + case MLNAnnotationViewDragStateNone: return; } } diff --git a/ios/RCTMGL/RCTMGLPointAnnotationManager.h b/ios/RCTMLN/RCTMLNPointAnnotationManager.h similarity index 57% rename from ios/RCTMGL/RCTMGLPointAnnotationManager.h rename to ios/RCTMLN/RCTMLNPointAnnotationManager.h index fcbf7c7f1..bd4b1eb77 100644 --- a/ios/RCTMGL/RCTMGLPointAnnotationManager.h +++ b/ios/RCTMLN/RCTMLNPointAnnotationManager.h @@ -1,6 +1,6 @@ // -// RCTMGLPointAnnotationManager.h -// RCTMGL +// RCTMLNPointAnnotationManager.h +// RCTMLN // // Created by Nick Italiano on 10/12/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLPointAnnotationManager : ViewManager +@interface RCTMLNPointAnnotationManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLPointAnnotationManager.m b/ios/RCTMLN/RCTMLNPointAnnotationManager.m similarity index 82% rename from ios/RCTMGL/RCTMGLPointAnnotationManager.m rename to ios/RCTMLN/RCTMLNPointAnnotationManager.m index 164d40674..d738c11f6 100644 --- a/ios/RCTMGL/RCTMGLPointAnnotationManager.m +++ b/ios/RCTMLN/RCTMLNPointAnnotationManager.m @@ -1,15 +1,15 @@ // -// RCTMGLPointAnnotationManager.m -// RCTMGL +// RCTMLNPointAnnotationManager.m +// RCTMLN // // Created by Nick Italiano on 10/12/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLPointAnnotationManager.h" -#import "RCTMGLPointAnnotation.h" +#import "RCTMLNPointAnnotationManager.h" +#import "RCTMLNPointAnnotation.h" -@implementation RCTMGLPointAnnotationManager +@implementation RCTMLNPointAnnotationManager RCT_EXPORT_MODULE() @@ -30,7 +30,7 @@ @implementation RCTMGLPointAnnotationManager - (UIView *)view { - return [[RCTMGLPointAnnotation alloc] init]; + return [[RCTMLNPointAnnotation alloc] init]; } @end diff --git a/ios/RCTMLN/RCTMLNRasterLayer.h b/ios/RCTMLN/RCTMLNRasterLayer.h new file mode 100644 index 000000000..aceb55f92 --- /dev/null +++ b/ios/RCTMLN/RCTMLNRasterLayer.h @@ -0,0 +1,14 @@ +// +// RCTMLNRasterLayer.h +// RCTMLN +// +// Created by Nick Italiano on 9/25/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import "RCTMLNLayer.h" +@import MapLibre; + +@interface RCTMLNRasterLayer : RCTMLNLayer + +@end diff --git a/ios/RCTMLN/RCTMLNRasterLayer.m b/ios/RCTMLN/RCTMLNRasterLayer.m new file mode 100644 index 000000000..bf7afea2f --- /dev/null +++ b/ios/RCTMLN/RCTMLNRasterLayer.m @@ -0,0 +1,30 @@ +// +// RCTMLNRasterLayer.m +// RCTMLN +// +// Created by Nick Italiano on 9/25/17. +// Copyright © 2017 Mapbox Inc. All rights reserved. +// + +#import "RCTMLNRasterLayer.h" +#import "RCTMLNStyle.h" + +@implementation RCTMLNRasterLayer + +- (MLNStyleLayer*)makeLayer:(MLNStyle*)style +{ + MLNSource *source = [style sourceWithIdentifier:self.sourceID]; + if (source == nil) { return nil; } + MLNRasterStyleLayer *layer = [[MLNRasterStyleLayer alloc] initWithIdentifier:self.id source:source]; + return layer; +} + +- (void)addStyles +{ + RCTMLNStyle *style = [[RCTMLNStyle alloc] initWithMLNStyle:self.style]; + style.bridge = self.bridge; + [style rasterLayer:(MLNRasterStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; + }]; +} + +@end diff --git a/ios/RCTMGL/RCTMGLRasterLayerManager.h b/ios/RCTMLN/RCTMLNRasterLayerManager.h similarity index 59% rename from ios/RCTMGL/RCTMGLRasterLayerManager.h rename to ios/RCTMLN/RCTMLNRasterLayerManager.h index cc6d56add..5634fbaf1 100644 --- a/ios/RCTMGL/RCTMGLRasterLayerManager.h +++ b/ios/RCTMLN/RCTMLNRasterLayerManager.h @@ -1,6 +1,6 @@ // -// RCTMGLRasterLayerManager.h -// RCTMGL +// RCTMLNRasterLayerManager.h +// RCTMLN // // Created by Nick Italiano on 9/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLRasterLayerManager : ViewManager +@interface RCTMLNRasterLayerManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLRasterLayerManager.m b/ios/RCTMLN/RCTMLNRasterLayerManager.m similarity index 74% rename from ios/RCTMGL/RCTMGLRasterLayerManager.m rename to ios/RCTMLN/RCTMLNRasterLayerManager.m index 7d8dba840..5aa41cd2a 100644 --- a/ios/RCTMGL/RCTMGLRasterLayerManager.m +++ b/ios/RCTMLN/RCTMLNRasterLayerManager.m @@ -1,15 +1,15 @@ // -// RCTMGLRasterLayerManager.m -// RCTMGL +// RCTMLNRasterLayerManager.m +// RCTMLN // // Created by Nick Italiano on 9/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLRasterLayerManager.h" -#import "RCTMGLRasterLayer.h" +#import "RCTMLNRasterLayerManager.h" +#import "RCTMLNRasterLayer.h" -@implementation RCTMGLRasterLayerManager +@implementation RCTMLNRasterLayerManager RCT_EXPORT_MODULE() @@ -27,7 +27,7 @@ @implementation RCTMGLRasterLayerManager - (UIView*)view { - RCTMGLRasterLayer *layer = [[RCTMGLRasterLayer alloc] init]; + RCTMLNRasterLayer *layer = [[RCTMLNRasterLayer alloc] init]; layer.bridge = self.bridge; return layer; } diff --git a/ios/RCTMGL/RCTMGLRasterSource.h b/ios/RCTMLN/RCTMLNRasterSource.h similarity index 55% rename from ios/RCTMGL/RCTMGLRasterSource.h rename to ios/RCTMLN/RCTMLNRasterSource.h index c9b60012c..8417fc433 100644 --- a/ios/RCTMGL/RCTMGLRasterSource.h +++ b/ios/RCTMLN/RCTMLNRasterSource.h @@ -1,15 +1,15 @@ // -// RCTMGLRasterSource.h -// RCTMGL +// RCTMLNRasterSource.h +// RCTMLN // // Created by Nick Italiano on 9/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLTileSource.h" -@import Mapbox; +#import "RCTMLNTileSource.h" +@import MapLibre; -@interface RCTMGLRasterSource : RCTMGLTileSource +@interface RCTMLNRasterSource : RCTMLNTileSource @property (nonatomic, strong) NSNumber *tileSize; diff --git a/ios/RCTMGL/RCTMGLRasterSource.m b/ios/RCTMLN/RCTMLNRasterSource.m similarity index 52% rename from ios/RCTMGL/RCTMGLRasterSource.m rename to ios/RCTMLN/RCTMLNRasterSource.m index 049da0db8..1b4750e1e 100644 --- a/ios/RCTMGL/RCTMGLRasterSource.m +++ b/ios/RCTMLN/RCTMLNRasterSource.m @@ -1,32 +1,32 @@ // -// RCTMGLRasterSource.m -// RCTMGL +// RCTMLNRasterSource.m +// RCTMLN // // Created by Nick Italiano on 9/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLRasterSource.h" +#import "RCTMLNRasterSource.h" -@implementation RCTMGLRasterSource +@implementation RCTMLNRasterSource -- (nullable MGLSource*)makeSource +- (nullable MLNSource*)makeSource { if (self.url != nil) { NSURL *url = [NSURL URLWithString:self.url]; if (self.tileSize != nil) { - return [[MGLRasterTileSource alloc] initWithIdentifier:self.id configurationURL:url tileSize:[self.tileSize floatValue]]; + return [[MLNRasterTileSource alloc] initWithIdentifier:self.id configurationURL:url tileSize:[self.tileSize floatValue]]; } - return [[MGLRasterTileSource alloc] initWithIdentifier:self.id configurationURL:url]; + return [[MLNRasterTileSource alloc] initWithIdentifier:self.id configurationURL:url]; } - return [[MGLRasterTileSource alloc] initWithIdentifier:self.id tileURLTemplates:self.tileUrlTemplates options:[self getOptions]]; + return [[MLNRasterTileSource alloc] initWithIdentifier:self.id tileURLTemplates:self.tileUrlTemplates options:[self getOptions]]; } -- (NSDictionary *)getOptions { - NSMutableDictionary *options = [[NSMutableDictionary alloc] initWithDictionary:[super getOptions]]; +- (NSDictionary *)getOptions { + NSMutableDictionary *options = [[NSMutableDictionary alloc] initWithDictionary:[super getOptions]]; if (self.tileSize != nil) { - options[MGLTileSourceOptionTileSize] = _tileSize; + options[MLNTileSourceOptionTileSize] = _tileSize; } return options; diff --git a/ios/RCTMGL/RCTMGLRasterSourceManager.h b/ios/RCTMLN/RCTMLNRasterSourceManager.h similarity index 59% rename from ios/RCTMGL/RCTMGLRasterSourceManager.h rename to ios/RCTMLN/RCTMLNRasterSourceManager.h index b654b4b94..46a744993 100644 --- a/ios/RCTMGL/RCTMGLRasterSourceManager.h +++ b/ios/RCTMLN/RCTMLNRasterSourceManager.h @@ -1,6 +1,6 @@ // -// RCTMGLRasterSourceManager.h -// RCTMGL +// RCTMLNRasterSourceManager.h +// RCTMLN // // Created by Nick Italiano on 9/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLRasterSourceManager : ViewManager +@interface RCTMLNRasterSourceManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLRasterSourceManager.m b/ios/RCTMLN/RCTMLNRasterSourceManager.m similarity index 72% rename from ios/RCTMGL/RCTMGLRasterSourceManager.m rename to ios/RCTMLN/RCTMLNRasterSourceManager.m index d5da4a4dc..656c2df00 100644 --- a/ios/RCTMGL/RCTMGLRasterSourceManager.m +++ b/ios/RCTMLN/RCTMLNRasterSourceManager.m @@ -1,15 +1,15 @@ // -// RCTMGLRasterSourceManager.m -// RCTMGL +// RCTMLNRasterSourceManager.m +// RCTMLN // // Created by Nick Italiano on 9/25/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLRasterSourceManager.h" -#import "RCTMGLRasterSource.h" +#import "RCTMLNRasterSourceManager.h" +#import "RCTMLNRasterSource.h" -@implementation RCTMGLRasterSourceManager +@implementation RCTMLNRasterSourceManager RCT_EXPORT_MODULE() @@ -26,7 +26,7 @@ @implementation RCTMGLRasterSourceManager - (UIView*)view { - return [RCTMGLRasterSource new]; + return [RCTMLNRasterSource new]; } @end diff --git a/ios/RCTMGL/RCTMGLShapeSource.h b/ios/RCTMLN/RCTMLNShapeSource.h similarity index 79% rename from ios/RCTMGL/RCTMGLShapeSource.h rename to ios/RCTMLN/RCTMLNShapeSource.h index 282e3653c..ac2ac1917 100644 --- a/ios/RCTMGL/RCTMGLShapeSource.h +++ b/ios/RCTMLN/RCTMLNShapeSource.h @@ -1,17 +1,17 @@ // -// RCTMGLShapeSource.h -// RCTMGL +// RCTMLNShapeSource.h +// RCTMLN // // Created by Nick Italiano on 9/19/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -#import "RCTMGLSource.h" +#import "RCTMLNSource.h" -@import Mapbox; +@import MapLibre; -@interface RCTMGLShapeSource : RCTMGLSource +@interface RCTMLNShapeSource : RCTMLNSource @property (nonatomic, weak) RCTBridge *bridge; @@ -31,21 +31,21 @@ @property (nonatomic, copy) RCTBubblingEventBlock onPress; @property (nonatomic, assign) BOOL hasPressListener; -- (nonnull NSArray> *)featuresMatchingPredicate:(nullable NSPredicate *)predicate; -- (nonnull NSArray> *)getClusterLeaves:(nonnull NSString *)featureJSON +- (nonnull NSArray> *)featuresMatchingPredicate:(nullable NSPredicate *)predicate; +- (nonnull NSArray> *)getClusterLeaves:(nonnull NSString *)featureJSON number:(NSUInteger)number offset:(NSUInteger)offset; -- (nonnull NSArray> *)getClusterChildren:(nonnull NSString *)featureJSON; +- (nonnull NSArray> *)getClusterChildren:(nonnull NSString *)featureJSON; - (double)getClusterExpansionZoom:(nonnull NSString *)featureJSON; // Deprecated. Will be removed in 9+ ver. -- (nonnull NSArray> *)getClusterLeavesById:(nonnull NSNumber *)clusterId +- (nonnull NSArray> *)getClusterLeavesById:(nonnull NSNumber *)clusterId number:(NSUInteger)number offset:(NSUInteger)offset; // Deprecated. Will be removed in 9+ ver. -- (nonnull NSArray> *)getClusterChildrenById:(nonnull NSNumber *)clusterId; +- (nonnull NSArray> *)getClusterChildrenById:(nonnull NSNumber *)clusterId; // Deprecated. Will be removed in 9+ ver. - (double)getClusterExpansionZoomById:(nonnull NSNumber *)clusterId; diff --git a/ios/RCTMGL/RCTMGLShapeSource.m b/ios/RCTMLN/RCTMLNShapeSource.m similarity index 53% rename from ios/RCTMGL/RCTMGLShapeSource.m rename to ios/RCTMLN/RCTMLNShapeSource.m index ac0e201f7..798e1c84a 100644 --- a/ios/RCTMGL/RCTMGLShapeSource.m +++ b/ios/RCTMLN/RCTMLNShapeSource.m @@ -1,16 +1,16 @@ // -// RCTMGLShapeSource.m -// RCTMGL +// RCTMLNShapeSource.m +// RCTMLN // // Created by Nick Italiano on 9/19/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLShapeSource.h" -#import "RCTMGLUtils.h" -#import "RCTMGLMapView.h" +#import "RCTMLNShapeSource.h" +#import "RCTMLNUtils.h" +#import "RCTMLNMapView.h" -@implementation RCTMGLShapeSource +@implementation RCTMLNShapeSource static UIImage * _placeHolderImage; @@ -18,7 +18,7 @@ - (void)setUrl: (NSString*) url { _url = url; if (self.source != nil) { - MGLShapeSource *source = (MGLShapeSource *)self.source; + MLNShapeSource *source = (MLNShapeSource *)self.source; [source setURL: url == nil ? nil : [NSURL URLWithString:url]]; } } @@ -28,8 +28,8 @@ - (void)setShape:(NSString *)shape _shape = shape; if (self.source != nil) { - MGLShapeSource *source = (MGLShapeSource *)self.source; - [source setShape: shape == nil ? nil : [RCTMGLUtils shapeFromGeoJSON:_shape]]; + MLNShapeSource *source = (MLNShapeSource *)self.source; + [source setShape: shape == nil ? nil : [RCTMLNUtils shapeFromGeoJSON:_shape]]; } } @@ -50,36 +50,36 @@ - (void)removeFromMap [super removeFromMap]; } -- (nullable MGLSource*)makeSource +- (nullable MLNSource*)makeSource { - NSDictionary *options = [self _getOptions]; + NSDictionary *options = [self _getOptions]; if (_shape != nil) { - MGLShape *shape = [RCTMGLUtils shapeFromGeoJSON:_shape]; - return [[MGLShapeSource alloc] initWithIdentifier:self.id shape:shape options:options]; + MLNShape *shape = [RCTMLNUtils shapeFromGeoJSON:_shape]; + return [[MLNShapeSource alloc] initWithIdentifier:self.id shape:shape options:options]; } if (_url != nil) { NSURL *url = [[NSURL alloc] initWithString:_url]; - return [[MGLShapeSource alloc] initWithIdentifier:self.id URL:url options:options]; + return [[MLNShapeSource alloc] initWithIdentifier:self.id URL:url options:options]; } return nil; } -- (NSDictionary*)_getOptions +- (NSDictionary*)_getOptions { - NSMutableDictionary *options = [[NSMutableDictionary alloc] init]; + NSMutableDictionary *options = [[NSMutableDictionary alloc] init]; if (_cluster != nil) { - options[MGLShapeSourceOptionClustered] = [NSNumber numberWithBool:[_cluster intValue] == 1]; + options[MLNShapeSourceOptionClustered] = [NSNumber numberWithBool:[_cluster intValue] == 1]; } if (_clusterRadius != nil) { - options[MGLShapeSourceOptionClusterRadius] = _clusterRadius; + options[MLNShapeSourceOptionClusterRadius] = _clusterRadius; } if (_clusterMaxZoomLevel != nil) { - options[MGLShapeSourceOptionMaximumZoomLevelForClustering] = _clusterMaxZoomLevel; + options[MLNShapeSourceOptionMaximumZoomLevelForClustering] = _clusterMaxZoomLevel; } if (_clusterProperties != nil) { @@ -87,69 +87,69 @@ - (nullable MGLSource*)makeSource for (NSString *propertyName in _clusterProperties.allKeys) { NSArray *expressions = [_clusterProperties objectForKey: propertyName]; - NSExpression *firstExpression = [NSExpression expressionWithMGLJSONObject:[expressions objectAtIndex: 0]]; - NSExpression *secondExpression = [NSExpression expressionWithMGLJSONObject:[expressions objectAtIndex: 1]]; + NSExpression *firstExpression = [NSExpression expressionWithMLNJSONObject:[expressions objectAtIndex: 0]]; + NSExpression *secondExpression = [NSExpression expressionWithMLNJSONObject:[expressions objectAtIndex: 1]]; [properties setObject:@[firstExpression, secondExpression] forKey:propertyName]; } - options[MGLShapeSourceOptionClusterProperties] = properties; + options[MLNShapeSourceOptionClusterProperties] = properties; } if (_maxZoomLevel != nil) { - options[MGLShapeSourceOptionMaximumZoomLevel] = _maxZoomLevel; + options[MLNShapeSourceOptionMaximumZoomLevel] = _maxZoomLevel; } if (_buffer != nil) { - options[MGLShapeSourceOptionBuffer] = _buffer; + options[MLNShapeSourceOptionBuffer] = _buffer; } if (_tolerance != nil) { - options[MGLShapeSourceOptionSimplificationTolerance] = _tolerance; + options[MLNShapeSourceOptionSimplificationTolerance] = _tolerance; } if (_lineMetrics != nil) { - options[MGLShapeSourceOptionLineDistanceMetrics] = _lineMetrics; + options[MLNShapeSourceOptionLineDistanceMetrics] = _lineMetrics; } return options; } -- (nonnull NSArray> *)featuresMatchingPredicate:(nullable NSPredicate *)predicate +- (nonnull NSArray> *)featuresMatchingPredicate:(nullable NSPredicate *)predicate { - MGLShapeSource *shapeSource = (MGLShapeSource *)self.source; + MLNShapeSource *shapeSource = (MLNShapeSource *)self.source; return [shapeSource featuresMatchingPredicate:predicate]; } - (double)getClusterExpansionZoom:(nonnull NSString *)featureJSON { - MGLShapeSource *shapeSource = (MGLShapeSource *)self.source; + MLNShapeSource *shapeSource = (MLNShapeSource *)self.source; - MGLPointFeature *feature = (MGLPointFeature*)[RCTMGLUtils shapeFromGeoJSON:featureJSON]; + MLNPointFeature *feature = (MLNPointFeature*)[RCTMLNUtils shapeFromGeoJSON:featureJSON]; - return [shapeSource zoomLevelForExpandingCluster:(MGLPointFeatureCluster *)feature]; + return [shapeSource zoomLevelForExpandingCluster:(MLNPointFeatureCluster *)feature]; } -- (nonnull NSArray> *)getClusterLeaves:(nonnull NSString *)featureJSON +- (nonnull NSArray> *)getClusterLeaves:(nonnull NSString *)featureJSON number:(NSUInteger)number offset:(NSUInteger)offset { - MGLShapeSource *shapeSource = (MGLShapeSource *)self.source; + MLNShapeSource *shapeSource = (MLNShapeSource *)self.source; - MGLPointFeature *feature = (MGLPointFeature*)[RCTMGLUtils shapeFromGeoJSON:featureJSON]; + MLNPointFeature *feature = (MLNPointFeature*)[RCTMLNUtils shapeFromGeoJSON:featureJSON]; - MGLPointFeatureCluster * cluster = (MGLPointFeatureCluster *)feature; + MLNPointFeatureCluster * cluster = (MLNPointFeatureCluster *)feature; return [shapeSource leavesOfCluster:cluster offset:offset limit:number]; } -- (nonnull NSArray> *)getClusterChildren:(nonnull NSString *)featureJSON +- (nonnull NSArray> *)getClusterChildren:(nonnull NSString *)featureJSON { - MGLShapeSource *shapeSource = (MGLShapeSource *)self.source; + MLNShapeSource *shapeSource = (MLNShapeSource *)self.source; - MGLPointFeature *feature = (MGLPointFeature*)[RCTMGLUtils shapeFromGeoJSON:featureJSON]; + MLNPointFeature *feature = (MLNPointFeature*)[RCTMLNUtils shapeFromGeoJSON:featureJSON]; - MGLPointFeatureCluster * cluster = (MGLPointFeatureCluster *)feature; + MLNPointFeatureCluster * cluster = (MLNPointFeatureCluster *)feature; return [shapeSource childrenOfCluster:cluster]; } @@ -157,37 +157,37 @@ - (double)getClusterExpansionZoom:(nonnull NSString *)featureJSON // Deprecated. Will be removed in 9+ ver. - (double)getClusterExpansionZoomById:(nonnull NSNumber *)clusterId { - MGLShapeSource *shapeSource = (MGLShapeSource *)self.source; - NSArray> *features = [shapeSource featuresMatchingPredicate: [NSPredicate predicateWithFormat:@"%K = %i", @"cluster_id", clusterId.intValue]]; + MLNShapeSource *shapeSource = (MLNShapeSource *)self.source; + NSArray> *features = [shapeSource featuresMatchingPredicate: [NSPredicate predicateWithFormat:@"%K = %i", @"cluster_id", clusterId.intValue]]; if (features.count == 0) { return -1; } - return [shapeSource zoomLevelForExpandingCluster:(MGLPointFeatureCluster *)features[0]]; + return [shapeSource zoomLevelForExpandingCluster:(MLNPointFeatureCluster *)features[0]]; } // Deprecated. Will be removed in 9+ ver. -- (nonnull NSArray> *)getClusterLeavesById:(nonnull NSNumber *)clusterId +- (nonnull NSArray> *)getClusterLeavesById:(nonnull NSNumber *)clusterId number:(NSUInteger)number offset:(NSUInteger)offset { - MGLShapeSource *shapeSource = (MGLShapeSource *)self.source; + MLNShapeSource *shapeSource = (MLNShapeSource *)self.source; NSPredicate* predicate = [NSPredicate predicateWithFormat:@"cluster_id == %@", clusterId]; - NSArray> *features = [shapeSource featuresMatchingPredicate:predicate]; + NSArray> *features = [shapeSource featuresMatchingPredicate:predicate]; - MGLPointFeatureCluster * cluster = (MGLPointFeatureCluster *)features[0]; + MLNPointFeatureCluster * cluster = (MLNPointFeatureCluster *)features[0]; return [shapeSource leavesOfCluster:cluster offset:offset limit:number]; } // Deprecated. Will be removed in 9+ ver. -- (nonnull NSArray> *)getClusterChildrenById:(nonnull NSNumber *)clusterId +- (nonnull NSArray> *)getClusterChildrenById:(nonnull NSNumber *)clusterId { - MGLShapeSource *shapeSource = (MGLShapeSource *)self.source; + MLNShapeSource *shapeSource = (MLNShapeSource *)self.source; NSPredicate* predicate = [NSPredicate predicateWithFormat:@"cluster_id == %@", clusterId]; - NSArray> *features = [shapeSource featuresMatchingPredicate:predicate]; + NSArray> *features = [shapeSource featuresMatchingPredicate:predicate]; - MGLPointFeatureCluster * cluster = (MGLPointFeatureCluster *)features[0]; + MLNPointFeatureCluster * cluster = (MLNPointFeatureCluster *)features[0]; return [shapeSource childrenOfCluster:cluster]; } diff --git a/ios/RCTMGL/RCTMGLShapeSourceManager.h b/ios/RCTMLN/RCTMLNShapeSourceManager.h similarity index 62% rename from ios/RCTMGL/RCTMGLShapeSourceManager.h rename to ios/RCTMLN/RCTMLNShapeSourceManager.h index 4fde63538..7295ba4d3 100644 --- a/ios/RCTMGL/RCTMGLShapeSourceManager.h +++ b/ios/RCTMLN/RCTMLNShapeSourceManager.h @@ -1,6 +1,6 @@ // -// RCTMGLShapeSourceManager.h -// RCTMGL +// RCTMLNShapeSourceManager.h +// RCTMLN // // Created by Nick Italiano on 9/19/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -9,6 +9,6 @@ #import "ViewManager.h" #import -@interface RCTMGLShapeSourceManager : ViewManager +@interface RCTMLNShapeSourceManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLShapeSourceManager.m b/ios/RCTMLN/RCTMLNShapeSourceManager.m similarity index 85% rename from ios/RCTMGL/RCTMGLShapeSourceManager.m rename to ios/RCTMLN/RCTMLNShapeSourceManager.m index 3735aea22..98d41bf47 100644 --- a/ios/RCTMGL/RCTMGLShapeSourceManager.m +++ b/ios/RCTMLN/RCTMLNShapeSourceManager.m @@ -1,20 +1,20 @@ // -// RCTMGLShapeSourceManager.m -// RCTMGL +// RCTMLNShapeSourceManager.m +// RCTMLN // // Created by Nick Italiano on 9/19/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -#import "RCTMGLShapeSourceManager.h" -#import "RCTMGLShapeSource.h" +#import "RCTMLNShapeSourceManager.h" +#import "RCTMLNShapeSource.h" #import "FilterParser.h" -@implementation RCTMGLShapeSourceManager +@implementation RCTMLNShapeSourceManager -RCT_EXPORT_MODULE(RCTMGLShapeSource) +RCT_EXPORT_MODULE(RCTMLNShapeSource) RCT_EXPORT_VIEW_PROPERTY(id, NSString) RCT_EXPORT_VIEW_PROPERTY(url, NSString) @@ -36,7 +36,7 @@ @implementation RCTMGLShapeSourceManager - (UIView*)view { - RCTMGLShapeSource *source = [RCTMGLShapeSource new]; + RCTMLNShapeSource *source = [RCTMLNShapeSource new]; source.bridge = self.bridge; return source; } @@ -47,15 +47,15 @@ - (UIView*)view rejecter:(RCTPromiseRejectBlock)reject) { [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { - RCTMGLShapeSource* shapeSource = viewRegistry[reactTag]; + RCTMLNShapeSource* shapeSource = viewRegistry[reactTag]; - if (![shapeSource isKindOfClass:[RCTMGLShapeSource class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![shapeSource isKindOfClass:[RCTMLNShapeSource class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } NSPredicate* predicate = [FilterParser parse:filter]; - NSArray> *shapes = [shapeSource featuresMatchingPredicate: predicate]; + NSArray> *shapes = [shapeSource featuresMatchingPredicate: predicate]; NSMutableArray *features = [[NSMutableArray alloc] initWithCapacity:shapes.count]; for (int i = 0; i < shapes.count; i++) { @@ -74,10 +74,10 @@ - (UIView*)view rejecter:(RCTPromiseRejectBlock)reject) { [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { - RCTMGLShapeSource* shapeSource = (RCTMGLShapeSource *)viewRegistry[reactTag]; + RCTMLNShapeSource* shapeSource = (RCTMLNShapeSource *)viewRegistry[reactTag]; - if (![shapeSource isKindOfClass:[RCTMGLShapeSource class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![shapeSource isKindOfClass:[RCTMLNShapeSource class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } @@ -99,9 +99,9 @@ - (UIView*)view rejecter:(RCTPromiseRejectBlock)reject) { [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { - RCTMGLShapeSource* shapeSource = (RCTMGLShapeSource *)viewRegistry[reactTag]; + RCTMLNShapeSource* shapeSource = (RCTMLNShapeSource *)viewRegistry[reactTag]; - NSArray> *shapes = [shapeSource getClusterLeaves:featureJSON number:number offset:offset]; + NSArray> *shapes = [shapeSource getClusterLeaves:featureJSON number:number offset:offset]; NSMutableArray *features = [[NSMutableArray alloc] initWithCapacity:shapes.count]; for (int i = 0; i < shapes.count; i++) { @@ -120,9 +120,9 @@ - (UIView*)view rejecter:(RCTPromiseRejectBlock)reject) { [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { - RCTMGLShapeSource* shapeSource = (RCTMGLShapeSource *)viewRegistry[reactTag]; + RCTMLNShapeSource* shapeSource = (RCTMLNShapeSource *)viewRegistry[reactTag]; - NSArray> *shapes = [shapeSource getClusterChildren: featureJSON]; + NSArray> *shapes = [shapeSource getClusterChildren: featureJSON]; NSMutableArray *features = [[NSMutableArray alloc] initWithCapacity:shapes.count]; for (int i = 0; i < shapes.count; i++) { @@ -142,10 +142,10 @@ - (UIView*)view rejecter:(RCTPromiseRejectBlock)reject) { [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { - RCTMGLShapeSource* shapeSource = (RCTMGLShapeSource *)viewRegistry[reactTag]; + RCTMLNShapeSource* shapeSource = (RCTMLNShapeSource *)viewRegistry[reactTag]; - if (![shapeSource isKindOfClass:[RCTMGLShapeSource class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![shapeSource isKindOfClass:[RCTMLNShapeSource class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } @@ -167,9 +167,9 @@ - (UIView*)view rejecter:(RCTPromiseRejectBlock)reject) { [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { - RCTMGLShapeSource* shapeSource = (RCTMGLShapeSource *)viewRegistry[reactTag]; + RCTMLNShapeSource* shapeSource = (RCTMLNShapeSource *)viewRegistry[reactTag]; - NSArray> *shapes = [shapeSource getClusterLeavesById:clusterId number:number offset:offset]; + NSArray> *shapes = [shapeSource getClusterLeavesById:clusterId number:number offset:offset]; NSMutableArray *features = [[NSMutableArray alloc] initWithCapacity:shapes.count]; for (int i = 0; i < shapes.count; i++) { @@ -188,9 +188,9 @@ - (UIView*)view rejecter:(RCTPromiseRejectBlock)reject) { [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { - RCTMGLShapeSource* shapeSource = (RCTMGLShapeSource *)viewRegistry[reactTag]; + RCTMLNShapeSource* shapeSource = (RCTMLNShapeSource *)viewRegistry[reactTag]; - NSArray> *shapes = [shapeSource getClusterChildrenById: clusterId]; + NSArray> *shapes = [shapeSource getClusterChildrenById: clusterId]; NSMutableArray *features = [[NSMutableArray alloc] initWithCapacity:shapes.count]; for (int i = 0; i < shapes.count; i++) { diff --git a/ios/RCTMGL/RCTMGLSource.h b/ios/RCTMLN/RCTMLNSource.h similarity index 70% rename from ios/RCTMGL/RCTMGLSource.h rename to ios/RCTMLN/RCTMLNSource.h index 03c66c5e1..bebac8e41 100644 --- a/ios/RCTMGL/RCTMGLSource.h +++ b/ios/RCTMLN/RCTMLNSource.h @@ -1,24 +1,24 @@ // // BaseSource.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -#import "RCTMGLLayer.h" +#import "RCTMLNLayer.h" #import -@import Mapbox; +@import MapLibre; -@interface RCTMGLSource : UIView +@interface RCTMLNSource : UIView extern NSString * _Nonnull const DEFAULT_SOURCE_ID; @property (nonatomic, strong) NSMutableArray> *reactSubviews; -@property (nonatomic, strong) NSMutableArray *layers; -@property (nonatomic, strong) MGLSource *source; -@property (nonatomic, strong) RCTMGLMapView *map; +@property (nonatomic, strong) NSMutableArray *layers; +@property (nonatomic, strong) MLNSource *source; +@property (nonatomic, strong) RCTMLNMapView *map; @property (nonatomic, strong) NSDictionary *hitbox; @property (nonatomic, copy) NSString *id; @@ -27,7 +27,7 @@ extern NSString * _Nonnull const DEFAULT_SOURCE_ID; - (void)addToMap; - (void)removeFromMap; -- (nullable MGLSource*)makeSource; +- (nullable MLNSource*)makeSource; - (NSArray *)getLayerIDs; + (BOOL)isDefaultSource:(NSString*)sourceID; diff --git a/ios/RCTMGL/RCTMGLSource.m b/ios/RCTMLN/RCTMLNSource.m similarity index 82% rename from ios/RCTMGL/RCTMGLSource.m rename to ios/RCTMLN/RCTMLNSource.m index fa2e7ee96..92ea10b47 100644 --- a/ios/RCTMGL/RCTMGLSource.m +++ b/ios/RCTMLN/RCTMLNSource.m @@ -1,17 +1,17 @@ // // BaseSource.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLSource.h" +#import "RCTMLNSource.h" #import -#import "RCTMGLMapView.h" +#import "RCTMLNMapView.h" #import -@implementation RCTMGLSource +@implementation RCTMLNSource double const DEFAULT_HITBOX_AREA = 44.0; NSString *const DEFAULT_SOURCE_ID = @"composite"; @@ -30,8 +30,8 @@ - (instancetype)initWithFrame:(CGRect)frame #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wobjc-missing-super-calls" - (void)insertReactSubview:(id)subview atIndex:(NSInteger)atIndex { - if ([subview isKindOfClass:[RCTMGLLayer class]]) { - RCTMGLLayer *layer = (RCTMGLLayer*)subview; + if ([subview isKindOfClass:[RCTMLNLayer class]]) { + RCTMLNLayer *layer = (RCTMLNLayer*)subview; if (_map.style != nil) { [layer addToMap:_map style:_map.style]; @@ -46,8 +46,8 @@ - (void)insertReactSubview:(id)subview atIndex:(NSInteger)atIndex #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wobjc-missing-super-calls" - (void)removeReactSubview:(id)subview { - if ([subview isKindOfClass:[RCTMGLLayer class]]) { - RCTMGLLayer *layer = (RCTMGLLayer*)subview; + if ([subview isKindOfClass:[RCTMLNLayer class]]) { + RCTMLNLayer *layer = (RCTMLNLayer*)subview; [layer removeFromMap:_map.style]; [_layers removeObject:layer]; [_reactSubviews removeObject:layer]; @@ -62,7 +62,7 @@ - (void)removeReactSubview:(id)subview { } #pragma clang diagnostic pop -- (void)setMap:(RCTMGLMapView *)map +- (void)setMap:(RCTMLNMapView *)map { if (map == nil) { [self removeFromMap]; @@ -79,7 +79,7 @@ - (void)addToMap return; } - MGLSource *existingSource = [_map.style sourceWithIdentifier:_id]; + MLNSource *existingSource = [_map.style sourceWithIdentifier:_id]; if (existingSource != nil) { _source = existingSource; } else { @@ -93,7 +93,7 @@ - (void)addToMap if (_layers.count > 0) { for (int i = 0; i < _layers.count; i++) { - RCTMGLLayer *layer = [_layers objectAtIndex:i]; + RCTMLNLayer *layer = [_layers objectAtIndex:i]; [layer addToMap:_map style:_map.style]; } } @@ -106,18 +106,18 @@ - (void)removeFromMap } for (int i = 0; i < _layers.count; i++) { - RCTMGLLayer *layer = [_layers objectAtIndex:i]; + RCTMLNLayer *layer = [_layers objectAtIndex:i]; [layer removeFromMap:_map.style]; } - if (![RCTMGLSource isDefaultSource:_id]) { + if (![RCTMLNSource isDefaultSource:_id]) { if (_source != nil) { [_map.style removeSource:_source]; } } } -- (nullable MGLSource*)makeSource +- (nullable MLNSource*)makeSource { @throw [NSException exceptionWithName:NSInternalInconsistencyException reason:[NSString stringWithFormat:@"You must override %@ in a subclass", NSStringFromSelector(_cmd)] @@ -128,7 +128,7 @@ - (nullable MGLSource*)makeSource { NSMutableArray *layerIDs = [[NSMutableArray alloc] init]; - for (RCTMGLLayer *layer in _layers) { + for (RCTMLNLayer *layer in _layers) { [layerIDs addObject:layer.id]; } diff --git a/ios/RCTMLN/RCTMLNStyle.h b/ios/RCTMLN/RCTMLNStyle.h new file mode 100644 index 000000000..383e6dea3 --- /dev/null +++ b/ios/RCTMLN/RCTMLNStyle.h @@ -0,0 +1,222 @@ +// DO NOT MODIFY +// THIS FILE IS AUTOGENERATED + +#import "RCTMLNStyle.h" +#import "RCTMLNStyleValue.h" +#import + +@import MapLibre; + +@interface RCTMLNStyle : NSObject + +@property (nonatomic, weak) RCTBridge *bridge; +@property (nonatomic, strong) MLNStyle *style; + +- (id)initWithMLNStyle:(MLNStyle*)mlnStyle; + +- (void)fillLayer:(MLNFillStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; +- (void)lineLayer:(MLNLineStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; +- (void)symbolLayer:(MLNSymbolStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; +- (void)circleLayer:(MLNCircleStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; +- (void)heatmapLayer:(MLNHeatmapStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; +- (void)fillExtrusionLayer:(MLNFillExtrusionStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; +- (void)rasterLayer:(MLNRasterStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; +- (void)hillshadeLayer:(MLNHillshadeStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; +- (void)backgroundLayer:(MLNBackgroundStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; +- (void)lightLayer:(MLNLight *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; + +- (void)setFillSortKey:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillStyleLayerVisibility:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillAntialias:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillOpacity:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillOpacityTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillColor:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillColorTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillOutlineColor:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillOutlineColorTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillTranslate:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillTranslateTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillTranslateAnchor:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillPattern:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillPatternTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineCap:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineJoin:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineMiterLimit:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineRoundLimit:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineSortKey:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineStyleLayerVisibility:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineOpacity:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineOpacityTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineColor:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineColorTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineTranslate:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineTranslateTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineTranslateAnchor:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineWidth:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineWidthTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineGapWidth:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineGapWidthTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineOffset:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineOffsetTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineBlur:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineBlurTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineDasharray:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineDasharrayTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLinePattern:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLinePatternTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setLineGradient:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setSymbolPlacement:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setSymbolSpacing:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setSymbolAvoidEdges:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setSymbolSortKey:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setSymbolZOrder:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconAllowOverlap:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconIgnorePlacement:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconOptional:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconRotationAlignment:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconSize:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconTextFit:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconTextFitPadding:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconImage:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconRotate:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconPadding:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconKeepUpright:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconOffset:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconPitchAlignment:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextPitchAlignment:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextRotationAlignment:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextField:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextFont:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextSize:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextMaxWidth:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextLineHeight:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextLetterSpacing:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextJustify:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextRadialOffset:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextVariableAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextMaxAngle:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextWritingMode:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextRotate:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextPadding:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextKeepUpright:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextTransform:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextOffset:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextAllowOverlap:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextIgnorePlacement:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextOptional:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setSymbolStyleLayerVisibility:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconOpacity:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconOpacityTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconColor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconColorTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconHaloColor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconHaloColorTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconHaloWidth:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconHaloWidthTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconHaloBlur:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconHaloBlurTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconTranslate:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconTranslateTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIconTranslateAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextOpacity:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextOpacityTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextColor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextColorTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextHaloColor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextHaloColorTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextHaloWidth:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextHaloWidthTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextHaloBlur:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextHaloBlurTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextTranslate:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextTranslateTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setTextTranslateAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleSortKey:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleStyleLayerVisibility:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleRadius:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleRadiusTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleColor:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleColorTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleBlur:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleBlurTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleOpacity:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleOpacityTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleTranslate:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleTranslateTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleTranslateAnchor:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCirclePitchScale:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCirclePitchAlignment:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleStrokeWidth:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleStrokeWidthTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleStrokeColor:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleStrokeColorTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleStrokeOpacity:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setCircleStrokeOpacityTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHeatmapStyleLayerVisibility:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHeatmapRadius:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHeatmapRadiusTransition:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHeatmapWeight:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHeatmapIntensity:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHeatmapIntensityTransition:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHeatmapColor:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHeatmapOpacity:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHeatmapOpacityTransition:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionStyleLayerVisibility:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionOpacity:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionOpacityTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionColor:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionColorTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionTranslate:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionTranslateTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionTranslateAnchor:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionPattern:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionPatternTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionHeight:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionHeightTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionBase:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setFillExtrusionBaseTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterStyleLayerVisibility:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterOpacity:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterOpacityTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterHueRotate:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterHueRotateTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterBrightnessMin:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterBrightnessMinTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterBrightnessMax:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterBrightnessMaxTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterSaturation:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterSaturationTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterContrast:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterContrastTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterResampling:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setRasterFadeDuration:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeStyleLayerVisibility:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeIlluminationDirection:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeIlluminationAnchor:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeExaggeration:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeExaggerationTransition:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeShadowColor:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeShadowColorTransition:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeHighlightColor:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeHighlightColorTransition:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeAccentColor:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setHillshadeAccentColorTransition:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setBackgroundStyleLayerVisibility:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setBackgroundColor:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setBackgroundColorTransition:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setBackgroundPattern:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setBackgroundPatternTransition:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setBackgroundOpacity:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setBackgroundOpacityTransition:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setAnchor:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setPosition:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setPositionTransition:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setColor:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setColorTransition:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIntensity:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; +- (void)setIntensityTransition:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; + + +@end diff --git a/ios/RCTMGL/RCTMGLStyle.m b/ios/RCTMLN/RCTMLNStyle.m similarity index 56% rename from ios/RCTMGL/RCTMGLStyle.m rename to ios/RCTMLN/RCTMLNStyle.m index c6e4bb4c1..a6be18488 100644 --- a/ios/RCTMGL/RCTMGLStyle.m +++ b/ios/RCTMLN/RCTMLNStyle.m @@ -1,21 +1,21 @@ // DO NOT MODIFY // THIS FILE IS AUTOGENERATED -#import "RCTMGLStyle.h" -#import "RCTMGLUtils.h" +#import "RCTMLNStyle.h" +#import "RCTMLNUtils.h" -@implementation RCTMGLStyle +@implementation RCTMLNStyle -- (id)initWithMGLStyle:(MGLStyle*)mglStyle +- (id)initWithMLNStyle:(MLNStyle*)mlnStyle { if (self = [super init]) { - _style = mglStyle; + _style = mlnStyle; } return self; } -- (void)fillLayer:(MGLFillStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)fillLayer:(MLNFillStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -28,7 +28,7 @@ - (void)fillLayer:(MGLFillStyleLayer *)layer withReactStyle:(NSDictionary *)reac continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"fillSortKey"]) { [self setFillSortKey:layer withReactStyleValue:styleValue]; @@ -60,7 +60,7 @@ - (void)fillLayer:(MGLFillStyleLayer *)layer withReactStyle:(NSDictionary *)reac } else { NSString *imageURI = [styleValue getImageURI]; - [RCTMGLUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { + [RCTMLNUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { if (image != nil) { dispatch_async(dispatch_get_main_queue(), ^{ if (isValid()) { @@ -79,7 +79,7 @@ - (void)fillLayer:(MGLFillStyleLayer *)layer withReactStyle:(NSDictionary *)reac } } -- (void)lineLayer:(MGLLineStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)lineLayer:(MLNLineStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -92,7 +92,7 @@ - (void)lineLayer:(MGLLineStyleLayer *)layer withReactStyle:(NSDictionary *)reac continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"lineCap"]) { [self setLineCap:layer withReactStyleValue:styleValue]; @@ -146,7 +146,7 @@ - (void)lineLayer:(MGLLineStyleLayer *)layer withReactStyle:(NSDictionary *)reac } else { NSString *imageURI = [styleValue getImageURI]; - [RCTMGLUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { + [RCTMLNUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { if (image != nil) { dispatch_async(dispatch_get_main_queue(), ^{ if (isValid()) { @@ -167,7 +167,7 @@ - (void)lineLayer:(MGLLineStyleLayer *)layer withReactStyle:(NSDictionary *)reac } } -- (void)symbolLayer:(MGLSymbolStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)symbolLayer:(MLNSymbolStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -180,7 +180,7 @@ - (void)symbolLayer:(MGLSymbolStyleLayer *)layer withReactStyle:(NSDictionary *) continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"symbolPlacement"]) { [self setSymbolPlacement:layer withReactStyleValue:styleValue]; @@ -212,7 +212,7 @@ - (void)symbolLayer:(MGLSymbolStyleLayer *)layer withReactStyle:(NSDictionary *) } else { NSString *imageURI = [styleValue getImageURI]; - [RCTMGLUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { + [RCTMLNUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { if (image != nil) { dispatch_async(dispatch_get_main_queue(), ^{ if (isValid()) { @@ -339,7 +339,7 @@ - (void)symbolLayer:(MGLSymbolStyleLayer *)layer withReactStyle:(NSDictionary *) } } -- (void)circleLayer:(MGLCircleStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)circleLayer:(MLNCircleStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -352,7 +352,7 @@ - (void)circleLayer:(MGLCircleStyleLayer *)layer withReactStyle:(NSDictionary *) continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"circleSortKey"]) { [self setCircleSortKey:layer withReactStyleValue:styleValue]; @@ -402,7 +402,7 @@ - (void)circleLayer:(MGLCircleStyleLayer *)layer withReactStyle:(NSDictionary *) } } -- (void)heatmapLayer:(MGLHeatmapStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)heatmapLayer:(MLNHeatmapStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -415,7 +415,7 @@ - (void)heatmapLayer:(MGLHeatmapStyleLayer *)layer withReactStyle:(NSDictionary continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"visibility"]) { [self setHeatmapStyleLayerVisibility:layer withReactStyleValue:styleValue]; @@ -441,7 +441,7 @@ - (void)heatmapLayer:(MGLHeatmapStyleLayer *)layer withReactStyle:(NSDictionary } } -- (void)fillExtrusionLayer:(MGLFillExtrusionStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)fillExtrusionLayer:(MLNFillExtrusionStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -454,7 +454,7 @@ - (void)fillExtrusionLayer:(MGLFillExtrusionStyleLayer *)layer withReactStyle:(N continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"visibility"]) { [self setFillExtrusionStyleLayerVisibility:layer withReactStyleValue:styleValue]; @@ -478,7 +478,7 @@ - (void)fillExtrusionLayer:(MGLFillExtrusionStyleLayer *)layer withReactStyle:(N } else { NSString *imageURI = [styleValue getImageURI]; - [RCTMGLUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { + [RCTMLNUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { if (image != nil) { dispatch_async(dispatch_get_main_queue(), ^{ if (isValid()) { @@ -505,7 +505,7 @@ - (void)fillExtrusionLayer:(MGLFillExtrusionStyleLayer *)layer withReactStyle:(N } } -- (void)rasterLayer:(MGLRasterStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)rasterLayer:(MLNRasterStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -518,7 +518,7 @@ - (void)rasterLayer:(MGLRasterStyleLayer *)layer withReactStyle:(NSDictionary *) continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"visibility"]) { [self setRasterStyleLayerVisibility:layer withReactStyleValue:styleValue]; @@ -556,7 +556,7 @@ - (void)rasterLayer:(MGLRasterStyleLayer *)layer withReactStyle:(NSDictionary *) } } -- (void)hillshadeLayer:(MGLHillshadeStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)hillshadeLayer:(MLNHillshadeStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -569,7 +569,7 @@ - (void)hillshadeLayer:(MGLHillshadeStyleLayer *)layer withReactStyle:(NSDiction continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"visibility"]) { [self setHillshadeStyleLayerVisibility:layer withReactStyleValue:styleValue]; @@ -599,7 +599,7 @@ - (void)hillshadeLayer:(MGLHillshadeStyleLayer *)layer withReactStyle:(NSDiction } } -- (void)backgroundLayer:(MGLBackgroundStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)backgroundLayer:(MLNBackgroundStyleLayer *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -612,7 +612,7 @@ - (void)backgroundLayer:(MGLBackgroundStyleLayer *)layer withReactStyle:(NSDicti continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"visibility"]) { [self setBackgroundStyleLayerVisibility:layer withReactStyleValue:styleValue]; @@ -626,7 +626,7 @@ - (void)backgroundLayer:(MGLBackgroundStyleLayer *)layer withReactStyle:(NSDicti } else { NSString *imageURI = [styleValue getImageURI]; - [RCTMGLUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { + [RCTMLNUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { if (image != nil) { dispatch_async(dispatch_get_main_queue(), ^{ if (isValid()) { @@ -649,7 +649,7 @@ - (void)backgroundLayer:(MGLBackgroundStyleLayer *)layer withReactStyle:(NSDicti } } -- (void)lightLayer:(MGLLight *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid +- (void)lightLayer:(MLNLight *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid { if (![self _hasReactStyle:reactStyle]) { // TODO throw exception @@ -662,7 +662,7 @@ - (void)lightLayer:(MGLLight *)layer withReactStyle:(NSDictionary *)reactStyle i continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; if ([prop isEqualToString:@"anchor"]) { [self setAnchor:layer withReactStyleValue:styleValue]; @@ -687,980 +687,980 @@ - (void)lightLayer:(MGLLight *)layer withReactStyle:(NSDictionary *)reactStyle i -- (void)setFillSortKey:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillSortKey:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillSortKey = styleValue.mglStyleValue; + layer.fillSortKey = styleValue.mlnStyleValue; } -- (void)setFillStyleLayerVisibility:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillStyleLayerVisibility:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.visible = [styleValue isVisible]; } -- (void)setFillAntialias:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillAntialias:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillAntialiased = styleValue.mglStyleValue; + layer.fillAntialiased = styleValue.mlnStyleValue; } -- (void)setFillOpacity:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillOpacity:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillOpacity = styleValue.mglStyleValue; + layer.fillOpacity = styleValue.mlnStyleValue; } -- (void)setFillOpacityTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillOpacityTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillOpacityTransition = [styleValue getTransition]; } -- (void)setFillColor:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillColor:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillColor = styleValue.mglStyleValue; + layer.fillColor = styleValue.mlnStyleValue; } -- (void)setFillColorTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillColorTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillColorTransition = [styleValue getTransition]; } -- (void)setFillOutlineColor:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillOutlineColor:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillOutlineColor = styleValue.mglStyleValue; + layer.fillOutlineColor = styleValue.mlnStyleValue; } -- (void)setFillOutlineColorTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillOutlineColorTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillOutlineColorTransition = [styleValue getTransition]; } -- (void)setFillTranslate:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillTranslate:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillTranslation = styleValue.mglStyleValue; + layer.fillTranslation = styleValue.mlnStyleValue; } -- (void)setFillTranslateTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillTranslateTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillTranslationTransition = [styleValue getTransition]; } -- (void)setFillTranslateAnchor:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillTranslateAnchor:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillTranslationAnchor = styleValue.mglStyleValue; + layer.fillTranslationAnchor = styleValue.mlnStyleValue; } -- (void)setFillPattern:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillPattern:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillPattern = styleValue.mglStyleValue; + layer.fillPattern = styleValue.mlnStyleValue; } -- (void)setFillPatternTransition:(MGLFillStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillPatternTransition:(MLNFillStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillPatternTransition = [styleValue getTransition]; } -- (void)setLineCap:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineCap:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineCap = styleValue.mglStyleValue; + layer.lineCap = styleValue.mlnStyleValue; } -- (void)setLineJoin:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineJoin:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineJoin = styleValue.mglStyleValue; + layer.lineJoin = styleValue.mlnStyleValue; } -- (void)setLineMiterLimit:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineMiterLimit:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineMiterLimit = styleValue.mglStyleValue; + layer.lineMiterLimit = styleValue.mlnStyleValue; } -- (void)setLineRoundLimit:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineRoundLimit:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineRoundLimit = styleValue.mglStyleValue; + layer.lineRoundLimit = styleValue.mlnStyleValue; } -- (void)setLineSortKey:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineSortKey:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineSortKey = styleValue.mglStyleValue; + layer.lineSortKey = styleValue.mlnStyleValue; } -- (void)setLineStyleLayerVisibility:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineStyleLayerVisibility:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.visible = [styleValue isVisible]; } -- (void)setLineOpacity:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineOpacity:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineOpacity = styleValue.mglStyleValue; + layer.lineOpacity = styleValue.mlnStyleValue; } -- (void)setLineOpacityTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineOpacityTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.lineOpacityTransition = [styleValue getTransition]; } -- (void)setLineColor:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineColor:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineColor = styleValue.mglStyleValue; + layer.lineColor = styleValue.mlnStyleValue; } -- (void)setLineColorTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineColorTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.lineColorTransition = [styleValue getTransition]; } -- (void)setLineTranslate:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineTranslate:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineTranslation = styleValue.mglStyleValue; + layer.lineTranslation = styleValue.mlnStyleValue; } -- (void)setLineTranslateTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineTranslateTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.lineTranslationTransition = [styleValue getTransition]; } -- (void)setLineTranslateAnchor:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineTranslateAnchor:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineTranslationAnchor = styleValue.mglStyleValue; + layer.lineTranslationAnchor = styleValue.mlnStyleValue; } -- (void)setLineWidth:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineWidth:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineWidth = styleValue.mglStyleValue; + layer.lineWidth = styleValue.mlnStyleValue; } -- (void)setLineWidthTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineWidthTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.lineWidthTransition = [styleValue getTransition]; } -- (void)setLineGapWidth:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineGapWidth:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineGapWidth = styleValue.mglStyleValue; + layer.lineGapWidth = styleValue.mlnStyleValue; } -- (void)setLineGapWidthTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineGapWidthTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.lineGapWidthTransition = [styleValue getTransition]; } -- (void)setLineOffset:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineOffset:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineOffset = styleValue.mglStyleValue; + layer.lineOffset = styleValue.mlnStyleValue; } -- (void)setLineOffsetTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineOffsetTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.lineOffsetTransition = [styleValue getTransition]; } -- (void)setLineBlur:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineBlur:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineBlur = styleValue.mglStyleValue; + layer.lineBlur = styleValue.mlnStyleValue; } -- (void)setLineBlurTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineBlurTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.lineBlurTransition = [styleValue getTransition]; } -- (void)setLineDasharray:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineDasharray:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineDashPattern = styleValue.mglStyleValue; + layer.lineDashPattern = styleValue.mlnStyleValue; } -- (void)setLineDasharrayTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineDasharrayTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.lineDashPatternTransition = [styleValue getTransition]; } -- (void)setLinePattern:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLinePattern:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.linePattern = styleValue.mglStyleValue; + layer.linePattern = styleValue.mlnStyleValue; } -- (void)setLinePatternTransition:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLinePatternTransition:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.linePatternTransition = [styleValue getTransition]; } -- (void)setLineGradient:(MGLLineStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setLineGradient:(MLNLineStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.lineGradient = styleValue.mglStyleValue; + layer.lineGradient = styleValue.mlnStyleValue; } -- (void)setSymbolPlacement:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setSymbolPlacement:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.symbolPlacement = styleValue.mglStyleValue; + layer.symbolPlacement = styleValue.mlnStyleValue; } -- (void)setSymbolSpacing:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setSymbolSpacing:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.symbolSpacing = styleValue.mglStyleValue; + layer.symbolSpacing = styleValue.mlnStyleValue; } -- (void)setSymbolAvoidEdges:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setSymbolAvoidEdges:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.symbolAvoidsEdges = styleValue.mglStyleValue; + layer.symbolAvoidsEdges = styleValue.mlnStyleValue; } -- (void)setSymbolSortKey:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setSymbolSortKey:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.symbolSortKey = styleValue.mglStyleValue; + layer.symbolSortKey = styleValue.mlnStyleValue; } -- (void)setSymbolZOrder:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setSymbolZOrder:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.symbolZOrder = styleValue.mglStyleValue; + layer.symbolZOrder = styleValue.mlnStyleValue; } -- (void)setIconAllowOverlap:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconAllowOverlap:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconAllowsOverlap = styleValue.mglStyleValue; + layer.iconAllowsOverlap = styleValue.mlnStyleValue; } -- (void)setIconIgnorePlacement:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconIgnorePlacement:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconIgnoresPlacement = styleValue.mglStyleValue; + layer.iconIgnoresPlacement = styleValue.mlnStyleValue; } -- (void)setIconOptional:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconOptional:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconOptional = styleValue.mglStyleValue; + layer.iconOptional = styleValue.mlnStyleValue; } -- (void)setIconRotationAlignment:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconRotationAlignment:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconRotationAlignment = styleValue.mglStyleValue; + layer.iconRotationAlignment = styleValue.mlnStyleValue; } -- (void)setIconSize:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconSize:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconScale = styleValue.mglStyleValue; + layer.iconScale = styleValue.mlnStyleValue; } -- (void)setIconTextFit:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconTextFit:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconTextFit = styleValue.mglStyleValue; + layer.iconTextFit = styleValue.mlnStyleValue; } -- (void)setIconTextFitPadding:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconTextFitPadding:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconTextFitPadding = styleValue.mglStyleValue; + layer.iconTextFitPadding = styleValue.mlnStyleValue; } -- (void)setIconImage:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconImage:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconImageName = styleValue.mglStyleValue; + layer.iconImageName = styleValue.mlnStyleValue; } -- (void)setIconRotate:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconRotate:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconRotation = styleValue.mglStyleValue; + layer.iconRotation = styleValue.mlnStyleValue; } -- (void)setIconPadding:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconPadding:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconPadding = styleValue.mglStyleValue; + layer.iconPadding = styleValue.mlnStyleValue; } -- (void)setIconKeepUpright:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconKeepUpright:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.keepsIconUpright = styleValue.mglStyleValue; + layer.keepsIconUpright = styleValue.mlnStyleValue; } -- (void)setIconOffset:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconOffset:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconOffset = styleValue.mglStyleValue; + layer.iconOffset = styleValue.mlnStyleValue; } -- (void)setIconAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconAnchor = styleValue.mglStyleValue; + layer.iconAnchor = styleValue.mlnStyleValue; } -- (void)setIconPitchAlignment:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconPitchAlignment:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconPitchAlignment = styleValue.mglStyleValue; + layer.iconPitchAlignment = styleValue.mlnStyleValue; } -- (void)setTextPitchAlignment:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextPitchAlignment:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textPitchAlignment = styleValue.mglStyleValue; + layer.textPitchAlignment = styleValue.mlnStyleValue; } -- (void)setTextRotationAlignment:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextRotationAlignment:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textRotationAlignment = styleValue.mglStyleValue; + layer.textRotationAlignment = styleValue.mlnStyleValue; } -- (void)setTextField:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextField:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.text = styleValue.mglStyleValue; + layer.text = styleValue.mlnStyleValue; } -- (void)setTextFont:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextFont:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textFontNames = styleValue.mglStyleValue; + layer.textFontNames = styleValue.mlnStyleValue; } -- (void)setTextSize:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextSize:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textFontSize = styleValue.mglStyleValue; + layer.textFontSize = styleValue.mlnStyleValue; } -- (void)setTextMaxWidth:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextMaxWidth:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.maximumTextWidth = styleValue.mglStyleValue; + layer.maximumTextWidth = styleValue.mlnStyleValue; } -- (void)setTextLineHeight:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextLineHeight:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textLineHeight = styleValue.mglStyleValue; + layer.textLineHeight = styleValue.mlnStyleValue; } -- (void)setTextLetterSpacing:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextLetterSpacing:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textLetterSpacing = styleValue.mglStyleValue; + layer.textLetterSpacing = styleValue.mlnStyleValue; } -- (void)setTextJustify:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextJustify:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textJustification = styleValue.mglStyleValue; + layer.textJustification = styleValue.mlnStyleValue; } -- (void)setTextRadialOffset:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextRadialOffset:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textRadialOffset = styleValue.mglStyleValue; + layer.textRadialOffset = styleValue.mlnStyleValue; } -- (void)setTextVariableAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextVariableAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textVariableAnchor = styleValue.mglStyleValue; + layer.textVariableAnchor = styleValue.mlnStyleValue; } -- (void)setTextAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textAnchor = styleValue.mglStyleValue; + layer.textAnchor = styleValue.mlnStyleValue; } -- (void)setTextMaxAngle:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextMaxAngle:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.maximumTextAngle = styleValue.mglStyleValue; + layer.maximumTextAngle = styleValue.mlnStyleValue; } -- (void)setTextWritingMode:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextWritingMode:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textWritingModes = styleValue.mglStyleValue; + layer.textWritingModes = styleValue.mlnStyleValue; } -- (void)setTextRotate:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextRotate:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textRotation = styleValue.mglStyleValue; + layer.textRotation = styleValue.mlnStyleValue; } -- (void)setTextPadding:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextPadding:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textPadding = styleValue.mglStyleValue; + layer.textPadding = styleValue.mlnStyleValue; } -- (void)setTextKeepUpright:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextKeepUpright:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.keepsTextUpright = styleValue.mglStyleValue; + layer.keepsTextUpright = styleValue.mlnStyleValue; } -- (void)setTextTransform:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextTransform:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textTransform = styleValue.mglStyleValue; + layer.textTransform = styleValue.mlnStyleValue; } -- (void)setTextOffset:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextOffset:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textOffset = styleValue.mglStyleValue; + layer.textOffset = styleValue.mlnStyleValue; } -- (void)setTextAllowOverlap:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextAllowOverlap:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textAllowsOverlap = styleValue.mglStyleValue; + layer.textAllowsOverlap = styleValue.mlnStyleValue; } -- (void)setTextIgnorePlacement:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextIgnorePlacement:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textIgnoresPlacement = styleValue.mglStyleValue; + layer.textIgnoresPlacement = styleValue.mlnStyleValue; } -- (void)setTextOptional:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextOptional:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textOptional = styleValue.mglStyleValue; + layer.textOptional = styleValue.mlnStyleValue; } -- (void)setSymbolStyleLayerVisibility:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setSymbolStyleLayerVisibility:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.visible = [styleValue isVisible]; } -- (void)setIconOpacity:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconOpacity:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconOpacity = styleValue.mglStyleValue; + layer.iconOpacity = styleValue.mlnStyleValue; } -- (void)setIconOpacityTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconOpacityTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.iconOpacityTransition = [styleValue getTransition]; } -- (void)setIconColor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconColor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconColor = styleValue.mglStyleValue; + layer.iconColor = styleValue.mlnStyleValue; } -- (void)setIconColorTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconColorTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.iconColorTransition = [styleValue getTransition]; } -- (void)setIconHaloColor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconHaloColor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconHaloColor = styleValue.mglStyleValue; + layer.iconHaloColor = styleValue.mlnStyleValue; } -- (void)setIconHaloColorTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconHaloColorTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.iconHaloColorTransition = [styleValue getTransition]; } -- (void)setIconHaloWidth:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconHaloWidth:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconHaloWidth = styleValue.mglStyleValue; + layer.iconHaloWidth = styleValue.mlnStyleValue; } -- (void)setIconHaloWidthTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconHaloWidthTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.iconHaloWidthTransition = [styleValue getTransition]; } -- (void)setIconHaloBlur:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconHaloBlur:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconHaloBlur = styleValue.mglStyleValue; + layer.iconHaloBlur = styleValue.mlnStyleValue; } -- (void)setIconHaloBlurTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconHaloBlurTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.iconHaloBlurTransition = [styleValue getTransition]; } -- (void)setIconTranslate:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconTranslate:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconTranslation = styleValue.mglStyleValue; + layer.iconTranslation = styleValue.mlnStyleValue; } -- (void)setIconTranslateTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconTranslateTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.iconTranslationTransition = [styleValue getTransition]; } -- (void)setIconTranslateAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIconTranslateAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.iconTranslationAnchor = styleValue.mglStyleValue; + layer.iconTranslationAnchor = styleValue.mlnStyleValue; } -- (void)setTextOpacity:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextOpacity:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textOpacity = styleValue.mglStyleValue; + layer.textOpacity = styleValue.mlnStyleValue; } -- (void)setTextOpacityTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextOpacityTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.textOpacityTransition = [styleValue getTransition]; } -- (void)setTextColor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextColor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textColor = styleValue.mglStyleValue; + layer.textColor = styleValue.mlnStyleValue; } -- (void)setTextColorTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextColorTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.textColorTransition = [styleValue getTransition]; } -- (void)setTextHaloColor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextHaloColor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textHaloColor = styleValue.mglStyleValue; + layer.textHaloColor = styleValue.mlnStyleValue; } -- (void)setTextHaloColorTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextHaloColorTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.textHaloColorTransition = [styleValue getTransition]; } -- (void)setTextHaloWidth:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextHaloWidth:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textHaloWidth = styleValue.mglStyleValue; + layer.textHaloWidth = styleValue.mlnStyleValue; } -- (void)setTextHaloWidthTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextHaloWidthTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.textHaloWidthTransition = [styleValue getTransition]; } -- (void)setTextHaloBlur:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextHaloBlur:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textHaloBlur = styleValue.mglStyleValue; + layer.textHaloBlur = styleValue.mlnStyleValue; } -- (void)setTextHaloBlurTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextHaloBlurTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.textHaloBlurTransition = [styleValue getTransition]; } -- (void)setTextTranslate:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextTranslate:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textTranslation = styleValue.mglStyleValue; + layer.textTranslation = styleValue.mlnStyleValue; } -- (void)setTextTranslateTransition:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextTranslateTransition:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.textTranslationTransition = [styleValue getTransition]; } -- (void)setTextTranslateAnchor:(MGLSymbolStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setTextTranslateAnchor:(MLNSymbolStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.textTranslationAnchor = styleValue.mglStyleValue; + layer.textTranslationAnchor = styleValue.mlnStyleValue; } -- (void)setCircleSortKey:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleSortKey:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleSortKey = styleValue.mglStyleValue; + layer.circleSortKey = styleValue.mlnStyleValue; } -- (void)setCircleStyleLayerVisibility:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleStyleLayerVisibility:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.visible = [styleValue isVisible]; } -- (void)setCircleRadius:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleRadius:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleRadius = styleValue.mglStyleValue; + layer.circleRadius = styleValue.mlnStyleValue; } -- (void)setCircleRadiusTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleRadiusTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.circleRadiusTransition = [styleValue getTransition]; } -- (void)setCircleColor:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleColor:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleColor = styleValue.mglStyleValue; + layer.circleColor = styleValue.mlnStyleValue; } -- (void)setCircleColorTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleColorTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.circleColorTransition = [styleValue getTransition]; } -- (void)setCircleBlur:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleBlur:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleBlur = styleValue.mglStyleValue; + layer.circleBlur = styleValue.mlnStyleValue; } -- (void)setCircleBlurTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleBlurTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.circleBlurTransition = [styleValue getTransition]; } -- (void)setCircleOpacity:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleOpacity:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleOpacity = styleValue.mglStyleValue; + layer.circleOpacity = styleValue.mlnStyleValue; } -- (void)setCircleOpacityTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleOpacityTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.circleOpacityTransition = [styleValue getTransition]; } -- (void)setCircleTranslate:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleTranslate:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleTranslation = styleValue.mglStyleValue; + layer.circleTranslation = styleValue.mlnStyleValue; } -- (void)setCircleTranslateTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleTranslateTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.circleTranslationTransition = [styleValue getTransition]; } -- (void)setCircleTranslateAnchor:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleTranslateAnchor:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleTranslationAnchor = styleValue.mglStyleValue; + layer.circleTranslationAnchor = styleValue.mlnStyleValue; } -- (void)setCirclePitchScale:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCirclePitchScale:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleScaleAlignment = styleValue.mglStyleValue; + layer.circleScaleAlignment = styleValue.mlnStyleValue; } -- (void)setCirclePitchAlignment:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCirclePitchAlignment:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circlePitchAlignment = styleValue.mglStyleValue; + layer.circlePitchAlignment = styleValue.mlnStyleValue; } -- (void)setCircleStrokeWidth:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleStrokeWidth:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleStrokeWidth = styleValue.mglStyleValue; + layer.circleStrokeWidth = styleValue.mlnStyleValue; } -- (void)setCircleStrokeWidthTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleStrokeWidthTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.circleStrokeWidthTransition = [styleValue getTransition]; } -- (void)setCircleStrokeColor:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleStrokeColor:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleStrokeColor = styleValue.mglStyleValue; + layer.circleStrokeColor = styleValue.mlnStyleValue; } -- (void)setCircleStrokeColorTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleStrokeColorTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.circleStrokeColorTransition = [styleValue getTransition]; } -- (void)setCircleStrokeOpacity:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleStrokeOpacity:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.circleStrokeOpacity = styleValue.mglStyleValue; + layer.circleStrokeOpacity = styleValue.mlnStyleValue; } -- (void)setCircleStrokeOpacityTransition:(MGLCircleStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setCircleStrokeOpacityTransition:(MLNCircleStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.circleStrokeOpacityTransition = [styleValue getTransition]; } -- (void)setHeatmapStyleLayerVisibility:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHeatmapStyleLayerVisibility:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.visible = [styleValue isVisible]; } -- (void)setHeatmapRadius:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHeatmapRadius:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.heatmapRadius = styleValue.mglStyleValue; + layer.heatmapRadius = styleValue.mlnStyleValue; } -- (void)setHeatmapRadiusTransition:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHeatmapRadiusTransition:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.heatmapRadiusTransition = [styleValue getTransition]; } -- (void)setHeatmapWeight:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHeatmapWeight:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.heatmapWeight = styleValue.mglStyleValue; + layer.heatmapWeight = styleValue.mlnStyleValue; } -- (void)setHeatmapIntensity:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHeatmapIntensity:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.heatmapIntensity = styleValue.mglStyleValue; + layer.heatmapIntensity = styleValue.mlnStyleValue; } -- (void)setHeatmapIntensityTransition:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHeatmapIntensityTransition:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.heatmapIntensityTransition = [styleValue getTransition]; } -- (void)setHeatmapColor:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHeatmapColor:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.heatmapColor = styleValue.mglStyleValue; + layer.heatmapColor = styleValue.mlnStyleValue; } -- (void)setHeatmapOpacity:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHeatmapOpacity:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.heatmapOpacity = styleValue.mglStyleValue; + layer.heatmapOpacity = styleValue.mlnStyleValue; } -- (void)setHeatmapOpacityTransition:(MGLHeatmapStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHeatmapOpacityTransition:(MLNHeatmapStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.heatmapOpacityTransition = [styleValue getTransition]; } -- (void)setFillExtrusionStyleLayerVisibility:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionStyleLayerVisibility:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.visible = [styleValue isVisible]; } -- (void)setFillExtrusionOpacity:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionOpacity:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillExtrusionOpacity = styleValue.mglStyleValue; + layer.fillExtrusionOpacity = styleValue.mlnStyleValue; } -- (void)setFillExtrusionOpacityTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionOpacityTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillExtrusionOpacityTransition = [styleValue getTransition]; } -- (void)setFillExtrusionColor:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionColor:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillExtrusionColor = styleValue.mglStyleValue; + layer.fillExtrusionColor = styleValue.mlnStyleValue; } -- (void)setFillExtrusionColorTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionColorTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillExtrusionColorTransition = [styleValue getTransition]; } -- (void)setFillExtrusionTranslate:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionTranslate:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillExtrusionTranslation = styleValue.mglStyleValue; + layer.fillExtrusionTranslation = styleValue.mlnStyleValue; } -- (void)setFillExtrusionTranslateTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionTranslateTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillExtrusionTranslationTransition = [styleValue getTransition]; } -- (void)setFillExtrusionTranslateAnchor:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionTranslateAnchor:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillExtrusionTranslationAnchor = styleValue.mglStyleValue; + layer.fillExtrusionTranslationAnchor = styleValue.mlnStyleValue; } -- (void)setFillExtrusionPattern:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionPattern:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillExtrusionPattern = styleValue.mglStyleValue; + layer.fillExtrusionPattern = styleValue.mlnStyleValue; } -- (void)setFillExtrusionPatternTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionPatternTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillExtrusionPatternTransition = [styleValue getTransition]; } -- (void)setFillExtrusionHeight:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionHeight:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillExtrusionHeight = styleValue.mglStyleValue; + layer.fillExtrusionHeight = styleValue.mlnStyleValue; } -- (void)setFillExtrusionHeightTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionHeightTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillExtrusionHeightTransition = [styleValue getTransition]; } -- (void)setFillExtrusionBase:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionBase:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.fillExtrusionBase = styleValue.mglStyleValue; + layer.fillExtrusionBase = styleValue.mlnStyleValue; } -- (void)setFillExtrusionBaseTransition:(MGLFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setFillExtrusionBaseTransition:(MLNFillExtrusionStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.fillExtrusionBaseTransition = [styleValue getTransition]; } -- (void)setRasterStyleLayerVisibility:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterStyleLayerVisibility:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.visible = [styleValue isVisible]; } -- (void)setRasterOpacity:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterOpacity:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.rasterOpacity = styleValue.mglStyleValue; + layer.rasterOpacity = styleValue.mlnStyleValue; } -- (void)setRasterOpacityTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterOpacityTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.rasterOpacityTransition = [styleValue getTransition]; } -- (void)setRasterHueRotate:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterHueRotate:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.rasterHueRotation = styleValue.mglStyleValue; + layer.rasterHueRotation = styleValue.mlnStyleValue; } -- (void)setRasterHueRotateTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterHueRotateTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.rasterHueRotationTransition = [styleValue getTransition]; } -- (void)setRasterBrightnessMin:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterBrightnessMin:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.minimumRasterBrightness = styleValue.mglStyleValue; + layer.minimumRasterBrightness = styleValue.mlnStyleValue; } -- (void)setRasterBrightnessMinTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterBrightnessMinTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.minimumRasterBrightnessTransition = [styleValue getTransition]; } -- (void)setRasterBrightnessMax:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterBrightnessMax:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.maximumRasterBrightness = styleValue.mglStyleValue; + layer.maximumRasterBrightness = styleValue.mlnStyleValue; } -- (void)setRasterBrightnessMaxTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterBrightnessMaxTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.maximumRasterBrightnessTransition = [styleValue getTransition]; } -- (void)setRasterSaturation:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterSaturation:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.rasterSaturation = styleValue.mglStyleValue; + layer.rasterSaturation = styleValue.mlnStyleValue; } -- (void)setRasterSaturationTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterSaturationTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.rasterSaturationTransition = [styleValue getTransition]; } -- (void)setRasterContrast:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterContrast:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.rasterContrast = styleValue.mglStyleValue; + layer.rasterContrast = styleValue.mlnStyleValue; } -- (void)setRasterContrastTransition:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterContrastTransition:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.rasterContrastTransition = [styleValue getTransition]; } -- (void)setRasterResampling:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterResampling:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.rasterResamplingMode = styleValue.mglStyleValue; + layer.rasterResamplingMode = styleValue.mlnStyleValue; } -- (void)setRasterFadeDuration:(MGLRasterStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setRasterFadeDuration:(MLNRasterStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.rasterFadeDuration = styleValue.mglStyleValue; + layer.rasterFadeDuration = styleValue.mlnStyleValue; } -- (void)setHillshadeStyleLayerVisibility:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeStyleLayerVisibility:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.visible = [styleValue isVisible]; } -- (void)setHillshadeIlluminationDirection:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeIlluminationDirection:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.hillshadeIlluminationDirection = styleValue.mglStyleValue; + layer.hillshadeIlluminationDirection = styleValue.mlnStyleValue; } -- (void)setHillshadeIlluminationAnchor:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeIlluminationAnchor:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.hillshadeIlluminationAnchor = styleValue.mglStyleValue; + layer.hillshadeIlluminationAnchor = styleValue.mlnStyleValue; } -- (void)setHillshadeExaggeration:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeExaggeration:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.hillshadeExaggeration = styleValue.mglStyleValue; + layer.hillshadeExaggeration = styleValue.mlnStyleValue; } -- (void)setHillshadeExaggerationTransition:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeExaggerationTransition:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.hillshadeExaggerationTransition = [styleValue getTransition]; } -- (void)setHillshadeShadowColor:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeShadowColor:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.hillshadeShadowColor = styleValue.mglStyleValue; + layer.hillshadeShadowColor = styleValue.mlnStyleValue; } -- (void)setHillshadeShadowColorTransition:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeShadowColorTransition:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.hillshadeShadowColorTransition = [styleValue getTransition]; } -- (void)setHillshadeHighlightColor:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeHighlightColor:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.hillshadeHighlightColor = styleValue.mglStyleValue; + layer.hillshadeHighlightColor = styleValue.mlnStyleValue; } -- (void)setHillshadeHighlightColorTransition:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeHighlightColorTransition:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.hillshadeHighlightColorTransition = [styleValue getTransition]; } -- (void)setHillshadeAccentColor:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeAccentColor:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.hillshadeAccentColor = styleValue.mglStyleValue; + layer.hillshadeAccentColor = styleValue.mlnStyleValue; } -- (void)setHillshadeAccentColorTransition:(MGLHillshadeStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setHillshadeAccentColorTransition:(MLNHillshadeStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.hillshadeAccentColorTransition = [styleValue getTransition]; } -- (void)setBackgroundStyleLayerVisibility:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setBackgroundStyleLayerVisibility:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.visible = [styleValue isVisible]; } -- (void)setBackgroundColor:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setBackgroundColor:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.backgroundColor = styleValue.mglStyleValue; + layer.backgroundColor = styleValue.mlnStyleValue; } -- (void)setBackgroundColorTransition:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setBackgroundColorTransition:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.backgroundColorTransition = [styleValue getTransition]; } -- (void)setBackgroundPattern:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setBackgroundPattern:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.backgroundPattern = styleValue.mglStyleValue; + layer.backgroundPattern = styleValue.mlnStyleValue; } -- (void)setBackgroundPatternTransition:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setBackgroundPatternTransition:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.backgroundPatternTransition = [styleValue getTransition]; } -- (void)setBackgroundOpacity:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setBackgroundOpacity:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.backgroundOpacity = styleValue.mglStyleValue; + layer.backgroundOpacity = styleValue.mlnStyleValue; } -- (void)setBackgroundOpacityTransition:(MGLBackgroundStyleLayer *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setBackgroundOpacityTransition:(MLNBackgroundStyleLayer *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.backgroundOpacityTransition = [styleValue getTransition]; } -- (void)setAnchor:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setAnchor:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.anchor = styleValue.mglStyleValue; + layer.anchor = styleValue.mlnStyleValue; } -- (void)setPosition:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setPosition:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.position = [styleValue getSphericalPosition]; } -- (void)setPositionTransition:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setPositionTransition:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.positionTransition = [styleValue getTransition]; } -- (void)setColor:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setColor:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.color = styleValue.mglStyleValue; + layer.color = styleValue.mlnStyleValue; } -- (void)setColorTransition:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setColorTransition:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.colorTransition = [styleValue getTransition]; } -- (void)setIntensity:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIntensity:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { - layer.intensity = styleValue.mglStyleValue; + layer.intensity = styleValue.mlnStyleValue; } -- (void)setIntensityTransition:(MGLLight *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)setIntensityTransition:(MLNLight *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.intensityTransition = [styleValue getTransition]; } diff --git a/ios/RCTMGL/RCTMGLStyleValue.h b/ios/RCTMLN/RCTMLNStyleValue.h similarity index 62% rename from ios/RCTMGL/RCTMGLStyleValue.h rename to ios/RCTMLN/RCTMLNStyleValue.h index 645aaca3f..29743dc22 100644 --- a/ios/RCTMGL/RCTMGLStyleValue.h +++ b/ios/RCTMLN/RCTMLNStyleValue.h @@ -1,27 +1,27 @@ // -// RCTMGLStyleValue.h -// RCTMGL +// RCTMLNStyleValue.h +// RCTMLN // // Created by Nick Italiano on 9/11/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -@import Mapbox; +@import MapLibre; -@interface RCTMGLStyleValue : NSObject +@interface RCTMLNStyleValue : NSObject @property (nonatomic, strong) NSString *styleType; @property (nonatomic, strong) NSDictionary *rawStyleValue; -@property (nonatomic, readonly) NSExpression *mglStyleValue; +@property (nonatomic, readonly) NSExpression *mlnStyleValue; - (BOOL)shouldAddImage; - (NSString *)getImageURI; - (double)getImageScale; -- (MGLTransition)getTransition; +- (MLNTransition)getTransition; - (NSExpression *)getSphericalPosition; - (BOOL)isVisible; -+ (RCTMGLStyleValue*)make:(NSString*)expressionJSONStr; ++ (RCTMLNStyleValue*)make:(NSString*)expressionJSONStr; @end diff --git a/ios/RCTMGL/RCTMGLStyleValue.m b/ios/RCTMLN/RCTMLNStyleValue.m similarity index 80% rename from ios/RCTMGL/RCTMGLStyleValue.m rename to ios/RCTMLN/RCTMLNStyleValue.m index 6a6ddea51..3b7db284d 100644 --- a/ios/RCTMGL/RCTMGLStyleValue.m +++ b/ios/RCTMLN/RCTMLNStyleValue.m @@ -1,46 +1,46 @@ // -// RCTMGLStyleValue.m -// RCTMGL +// RCTMLNStyleValue.m +// RCTMLN // // Created by Nick Italiano on 9/11/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLStyleValue.h" -#import "RCTMGLUtils.h" +#import "RCTMLNStyleValue.h" +#import "RCTMLNUtils.h" #import -@implementation RCTMGLStyleValue +@implementation RCTMLNStyleValue { NSObject *expressionJSON; } -- (NSExpression *)mglStyleValue +- (NSExpression *)mlnStyleValue { if ([_styleType isEqualToString:@"color"] && [expressionJSON respondsToSelector:@selector(objectEnumerator)] && [[[(NSArray*)expressionJSON objectEnumerator] nextObject] isKindOfClass:[NSNumber class]]) { - UIColor *color = [RCTMGLUtils toColor:expressionJSON]; - return [NSExpression expressionWithMGLJSONObject:color]; + UIColor *color = [RCTMLNUtils toColor:expressionJSON]; + return [NSExpression expressionWithMLNJSONObject:color]; } else if ([_styleType isEqualToString:@"color"] && [expressionJSON isKindOfClass:[NSNumber class]]) { - UIColor *color = [RCTMGLUtils toColor:expressionJSON]; - return [NSExpression expressionWithMGLJSONObject:color]; + UIColor *color = [RCTMLNUtils toColor:expressionJSON]; + return [NSExpression expressionWithMLNJSONObject:color]; } else if ([_styleType isEqualToString:@"vector"] && [expressionJSON respondsToSelector:@selector(objectEnumerator)] && [[[(NSArray*)expressionJSON objectEnumerator] nextObject] isKindOfClass:[NSNumber class]]) { - CGVector vector = [RCTMGLUtils toCGVector:(NSArray *)expressionJSON]; - return [NSExpression expressionWithMGLJSONObject:[NSValue valueWithCGVector:vector]]; + CGVector vector = [RCTMLNUtils toCGVector:(NSArray *)expressionJSON]; + return [NSExpression expressionWithMLNJSONObject:[NSValue valueWithCGVector:vector]]; } else if ([_styleType isEqualToString:@"image"] && [expressionJSON isKindOfClass:[NSDictionary class]]) { return [NSExpression expressionForConstantValue:[self getImageURI]]; } else if ([_styleType isEqual:@"edgeinsets"] && [expressionJSON respondsToSelector:@selector(objectEnumerator)] && [[[(NSArray*)expressionJSON objectEnumerator] nextObject] isKindOfClass:[NSNumber class]]){ - UIEdgeInsets edgeInsets = [RCTMGLUtils toUIEdgeInsets:(NSArray *)expressionJSON]; - return [NSExpression expressionWithMGLJSONObject:[NSValue valueWithUIEdgeInsets:edgeInsets]]; + UIEdgeInsets edgeInsets = [RCTMLNUtils toUIEdgeInsets:(NSArray *)expressionJSON]; + return [NSExpression expressionWithMLNJSONObject:[NSValue valueWithUIEdgeInsets:edgeInsets]]; } else if ([_styleType isEqualToString:@"enum"] && [expressionJSON isKindOfClass:[NSNumber class]]) { - // ensure we pass through values as NSUInteger when mapping to an MGL enum + // ensure we pass through values as NSUInteger when mapping to an MLN enum NSUInteger uintValue = [(NSNumber*)expressionJSON unsignedIntegerValue]; id rawValue = [NSValue value:&uintValue withObjCType:@encode(NSUInteger)]; - return [NSExpression expressionWithMGLJSONObject:rawValue]; + return [NSExpression expressionWithMLNJSONObject:rawValue]; } else if ([expressionJSON respondsToSelector:@selector(objectEnumerator)] && [[[(NSArray*)expressionJSON objectEnumerator] nextObject] isKindOfClass:[NSNumber class]]) { return [NSExpression expressionForConstantValue:expressionJSON]; } else { - return [NSExpression expressionWithMGLJSONObject:expressionJSON]; + return [NSExpression expressionWithMLNJSONObject:expressionJSON]; } } @@ -119,10 +119,10 @@ - (double)getImageScale } } -- (MGLTransition)getTransition +- (MLNTransition)getTransition { if (![expressionJSON isKindOfClass:[NSDictionary class]]) { - return MGLTransitionMake(0.f, 0.f); + return MLNTransitionMake(0.f, 0.f); } NSDictionary *config = (NSDictionary *)expressionJSON; @@ -131,7 +131,7 @@ - (MGLTransition)getTransition const double millisecondsToSeconds = 1.0/1000.0; - return MGLTransitionMake(duration * millisecondsToSeconds, delay * millisecondsToSeconds); + return MLNTransitionMake(duration * millisecondsToSeconds, delay * millisecondsToSeconds); } - (NSExpression *)getSphericalPosition @@ -142,8 +142,8 @@ - (NSExpression *)getSphericalPosition CLLocationDistance azimuthal = [values[1] doubleValue]; CLLocationDistance polar = [values[2] doubleValue]; - MGLSphericalPosition pos = MGLSphericalPositionMake(radial, azimuthal, polar); - return [NSExpression expressionWithMGLJSONObject:@(pos)]; + MLNSphericalPosition pos = MLNSphericalPositionMake(radial, azimuthal, polar); + return [NSExpression expressionWithMLNJSONObject:@(pos)]; } - (BOOL)isVisible @@ -155,9 +155,9 @@ - (BOOL)isVisible return YES; } -+ (RCTMGLStyleValue*)make:(NSDictionary*)rawStyleValue; ++ (RCTMLNStyleValue*)make:(NSDictionary*)rawStyleValue; { - RCTMGLStyleValue *styleValue = [[RCTMGLStyleValue alloc] init]; + RCTMLNStyleValue *styleValue = [[RCTMLNStyleValue alloc] init]; styleValue.styleType = (NSString *)rawStyleValue[@"styletype"]; NSObject *object = [styleValue parse:(NSDictionary *)rawStyleValue[@"stylevalue"]]; [styleValue setStyleObject:object]; diff --git a/ios/RCTMGL/RCTMGLSymbolLayer.h b/ios/RCTMLN/RCTMLNSymbolLayer.h similarity index 71% rename from ios/RCTMGL/RCTMGLSymbolLayer.h rename to ios/RCTMLN/RCTMLNSymbolLayer.h index c35c12934..8beeffdad 100644 --- a/ios/RCTMGL/RCTMGLSymbolLayer.h +++ b/ios/RCTMLN/RCTMLNSymbolLayer.h @@ -1,15 +1,15 @@ // -// RCTMGLSymbolLayer.h -// RCTMGL +// RCTMLNSymbolLayer.h +// RCTMLN // // Created by Nick Italiano on 9/19/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -#import "RCTMGLVectorLayer.h" +#import "RCTMLNVectorLayer.h" -@interface RCTMGLSymbolLayer : RCTMGLVectorLayer +@interface RCTMLNSymbolLayer : RCTMLNVectorLayer @property (nonatomic, strong) NSMutableArray> *reactSubviews; diff --git a/ios/RCTMGL/RCTMGLSymbolLayer.m b/ios/RCTMLN/RCTMLNSymbolLayer.m similarity index 83% rename from ios/RCTMGL/RCTMGLSymbolLayer.m rename to ios/RCTMLN/RCTMLNSymbolLayer.m index 475cb45c4..b55f1cf22 100644 --- a/ios/RCTMGL/RCTMGLSymbolLayer.m +++ b/ios/RCTMLN/RCTMLNSymbolLayer.m @@ -1,17 +1,17 @@ // -// RCTMGLSymbolLayer.m -// RCTMGL +// RCTMLNSymbolLayer.m +// RCTMLN // // Created by Nick Italiano on 9/19/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLSymbolLayer.h" -#import "RCTMGLStyle.h" +#import "RCTMLNSymbolLayer.h" +#import "RCTMLNStyle.h" #import #import -@implementation RCTMGLSymbolLayer +@implementation RCTMLNSymbolLayer - (instancetype)initWithFrame:(CGRect)frame { @@ -55,7 +55,7 @@ - (void)setSnapshot:(BOOL)snapshot if (self.style != nil) { UIImage *image; - MGLSymbolStyleLayer *layer = (MGLSymbolStyleLayer *) self.styleLayer; + MLNSymbolStyleLayer *layer = (MLNSymbolStyleLayer *) self.styleLayer; if (_snapshot == YES) { image = [self _createViewSnapshot]; @@ -82,26 +82,26 @@ - (void)addedToMap if (image != nil) { [self.style setImage:image forName:self.id]; - MGLSymbolStyleLayer *layer = (MGLSymbolStyleLayer *)self.styleLayer; + MLNSymbolStyleLayer *layer = (MLNSymbolStyleLayer *)self.styleLayer; layer.iconImageName = [NSExpression expressionForConstantValue:self.id]; } } } -- (MGLSymbolStyleLayer*)makeLayer:(MGLStyle*)style +- (MLNSymbolStyleLayer*)makeLayer:(MLNStyle*)style { - MGLSource *source = [self layerWithSourceIDInStyle: style]; + MLNSource *source = [self layerWithSourceIDInStyle: style]; if (source == nil) { return nil; } - MGLSymbolStyleLayer *layer = [[MGLSymbolStyleLayer alloc] initWithIdentifier:self.id source:source]; + MLNSymbolStyleLayer *layer = [[MLNSymbolStyleLayer alloc] initWithIdentifier:self.id source:source]; layer.sourceLayerIdentifier = self.sourceLayerID; return layer; } - (void)addStyles { - RCTMGLStyle *style = [[RCTMGLStyle alloc] initWithMGLStyle:self.style]; + RCTMLNStyle *style = [[RCTMLNStyle alloc] initWithMLNStyle:self.style]; style.bridge = self.bridge; - [style symbolLayer:(MGLSymbolStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; + [style symbolLayer:(MLNSymbolStyleLayer*)self.styleLayer withReactStyle:self.reactStyle isValid:^{ return [self isAddedToMap]; }]; } diff --git a/ios/RCTMGL/RCTMGLSymbolLayerManager.h b/ios/RCTMLN/RCTMLNSymbolLayerManager.h similarity index 59% rename from ios/RCTMGL/RCTMGLSymbolLayerManager.h rename to ios/RCTMLN/RCTMLNSymbolLayerManager.h index cdfeb6178..962a05c7a 100644 --- a/ios/RCTMGL/RCTMGLSymbolLayerManager.h +++ b/ios/RCTMLN/RCTMLNSymbolLayerManager.h @@ -1,6 +1,6 @@ // -// RCTMGLSymbolLayerManager.h -// RCTMGL +// RCTMLNSymbolLayerManager.h +// RCTMLN // // Created by Nick Italiano on 9/19/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,6 +8,6 @@ #import "ViewManager.h" -@interface RCTMGLSymbolLayerManager : ViewManager +@interface RCTMLNSymbolLayerManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLSymbolLayerManager.m b/ios/RCTMLN/RCTMLNSymbolLayerManager.m similarity index 79% rename from ios/RCTMGL/RCTMGLSymbolLayerManager.m rename to ios/RCTMLN/RCTMLNSymbolLayerManager.m index 5fd8b3e05..5111ea456 100644 --- a/ios/RCTMGL/RCTMGLSymbolLayerManager.m +++ b/ios/RCTMLN/RCTMLNSymbolLayerManager.m @@ -1,15 +1,15 @@ // -// RCTMGLSymbolLayerManager.m -// RCTMGL +// RCTMLNSymbolLayerManager.m +// RCTMLN // // Created by Nick Italiano on 9/19/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLSymbolLayerManager.h" -#import "RCTMGLSymbolLayer.h" +#import "RCTMLNSymbolLayerManager.h" +#import "RCTMLNSymbolLayer.h" -@implementation RCTMGLSymbolLayerManager +@implementation RCTMLNSymbolLayerManager RCT_EXPORT_MODULE() @@ -32,7 +32,7 @@ @implementation RCTMGLSymbolLayerManager - (UIView*)view { - RCTMGLSymbolLayer *layer = [RCTMGLSymbolLayer new]; + RCTMLNSymbolLayer *layer = [RCTMLNSymbolLayer new]; layer.bridge = self.bridge; return layer; } diff --git a/ios/RCTMGL/RCTMGLTileSource.h b/ios/RCTMLN/RCTMLNTileSource.h similarity index 65% rename from ios/RCTMGL/RCTMGLTileSource.h rename to ios/RCTMLN/RCTMLNTileSource.h index 5736fb4ec..1a8ff7d5c 100644 --- a/ios/RCTMGL/RCTMGLTileSource.h +++ b/ios/RCTMLN/RCTMLNTileSource.h @@ -1,12 +1,12 @@ // -// RCTMGLTileSource.h -// RCTMGL +// RCTMLNTileSource.h +// RCTMLN // -#import "RCTMGLSource.h" -@import Mapbox; +#import "RCTMLNSource.h" +@import MapLibre; -@interface RCTMGLTileSource : RCTMGLSource +@interface RCTMLNTileSource : RCTMLNSource @property (nonatomic, copy) NSString *url; @property (nonatomic, strong) NSArray *tileUrlTemplates; @@ -17,6 +17,6 @@ @property (nonatomic, assign) BOOL tms; -- (NSDictionary*)getOptions; +- (NSDictionary*)getOptions; @end diff --git a/ios/RCTMLN/RCTMLNTileSource.m b/ios/RCTMLN/RCTMLNTileSource.m new file mode 100644 index 000000000..78765b926 --- /dev/null +++ b/ios/RCTMLN/RCTMLNTileSource.m @@ -0,0 +1,31 @@ +// +// BaseSource.m +// RCTMLN +// + +#import "RCTMLNTileSource.h" + +@implementation RCTMLNTileSource + +- (NSDictionary*)getOptions { + NSMutableDictionary *options = [[NSMutableDictionary alloc] init]; + + if (self.maxZoomLevel != nil) { + options[MLNTileSourceOptionMaximumZoomLevel] = self.maxZoomLevel; + } + + if (self.minZoomLevel != nil) { + options[MLNTileSourceOptionMinimumZoomLevel] = self.minZoomLevel; + } + + if (self.tms) { + options[MLNTileSourceOptionTileCoordinateSystem] = [NSNumber numberWithUnsignedInteger:MLNTileCoordinateSystemTMS]; + } + + if (self.attribution != nil) { + options[MLNTileSourceOptionAttributionHTMLString] = self.attribution; + } + + return options; +} +@end diff --git a/ios/RCTMLN/RCTMLNUserLocation.h b/ios/RCTMLN/RCTMLNUserLocation.h new file mode 100644 index 000000000..8df54436a --- /dev/null +++ b/ios/RCTMLN/RCTMLNUserLocation.h @@ -0,0 +1,15 @@ +// +// RCTMLNUserLocation.h +// RCTMLN + +#import +#import +#import + +@interface RCTMLNUserLocation : NSObject + ++ (id)sharedInstance; + +- (MLNUserLocationAnnotationView*)hiddenUserAnnotation; + +@end diff --git a/ios/RCTMGL/RCTMGLUserLocation.m b/ios/RCTMLN/RCTMLNUserLocation.m similarity index 52% rename from ios/RCTMGL/RCTMGLUserLocation.m rename to ios/RCTMLN/RCTMLNUserLocation.m index 6880af290..a807182e5 100644 --- a/ios/RCTMGL/RCTMGLUserLocation.m +++ b/ios/RCTMLN/RCTMLNUserLocation.m @@ -1,12 +1,12 @@ // -// RCTMGLUserLocation.m -// RCTMGL +// RCTMLNUserLocation.m +// RCTMLN // -#import "RCTMGLUserLocation.h" -#import +#import "RCTMLNUserLocation.h" +#import -@interface HiddenUserLocationAnnotationView : MGLUserLocationAnnotationView +@interface HiddenUserLocationAnnotationView : MLNUserLocationAnnotationView @end @@ -20,17 +20,17 @@ - (void)update { @end -@implementation RCTMGLUserLocation : NSObject +@implementation RCTMLNUserLocation : NSObject + (id)sharedInstance { - static RCTMGLUserLocation *userLocation = nil; + static RCTMLNUserLocation *userLocation = nil; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ userLocation = [[self alloc] init]; }); return userLocation; } -- (MGLUserLocationAnnotationView*)hiddenUserAnnotation +- (MLNUserLocationAnnotationView*)hiddenUserAnnotation { return [[HiddenUserLocationAnnotationView alloc] init]; } diff --git a/ios/RCTMGL/RCTMGLUtils.h b/ios/RCTMLN/RCTMLNUtils.h similarity index 74% rename from ios/RCTMGL/RCTMGLUtils.h rename to ios/RCTMLN/RCTMLNUtils.h index d32381eab..f72513bf4 100644 --- a/ios/RCTMGL/RCTMGLUtils.h +++ b/ios/RCTMLN/RCTMLNUtils.h @@ -1,6 +1,6 @@ // // RCTConvert+Mapbox.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -11,19 +11,19 @@ #import #import -@import Mapbox; +@import MapLibre; -@interface RCTMGLUtils: NSObject +@interface RCTMLNUtils: NSObject + (CLLocationCoordinate2D)fromFeature:(NSString*)json; -+ (MGLShape*)shapeFromGeoJSON:(NSString*)json; -+ (MGLCoordinateBounds)fromFeatureCollection:(NSString*)json; -+ (NSArray *)fromCoordinateBounds:(MGLCoordinateBounds)bounds; ++ (MLNShape*)shapeFromGeoJSON:(NSString*)json; ++ (MLNCoordinateBounds)fromFeatureCollection:(NSString*)json; ++ (NSArray *)fromCoordinateBounds:(MLNCoordinateBounds)bounds; + (NSTimeInterval)fromMS:(NSNumber*)number; + (NSNumber*)clamp:(NSNumber*)value min:(NSNumber*)min max:(NSNumber*)max; + (UIColor*)toColor:(id)value; + (void)fetchImage:(RCTBridge*)bridge url:(NSString*)url scale:(double)scale callback:(RCTImageLoaderCompletionBlock)callback; -+ (void)fetchImages:(RCTBridge *)bridge style:(MGLStyle *)style objects:(NSDictionary*)objects forceUpdate:(BOOL)forceUpdate callback:(void (^)(void))callback; ++ (void)fetchImages:(RCTBridge *)bridge style:(MLNStyle *)style objects:(NSDictionary*)objects forceUpdate:(BOOL)forceUpdate callback:(void (^)(void))callback; + (CGVector)toCGVector:(NSArray*)arr; + (UIEdgeInsets)toUIEdgeInsets:(NSArray *)arr; + (NSURL*)styleURLFromStyleJSON:(NSString *)styleJSON; diff --git a/ios/RCTMGL/RCTMGLUtils.m b/ios/RCTMLN/RCTMLNUtils.m similarity index 85% rename from ios/RCTMGL/RCTMGLUtils.m rename to ios/RCTMLN/RCTMLNUtils.m index 1dca4bed4..1e3caa54b 100644 --- a/ios/RCTMGL/RCTMGLUtils.m +++ b/ios/RCTMLN/RCTMLNUtils.m @@ -1,24 +1,24 @@ // // RCTConvert+Mapbox.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 8/23/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLUtils.h" -#import "RCTMGLImageQueue.h" +#import "RCTMLNUtils.h" +#import "RCTMLNImageQueue.h" -@import Mapbox; +@import MapLibre; -@implementation RCTMGLUtils +@implementation RCTMLNUtils static double const MS_TO_S = 0.001; + (CLLocationCoordinate2D)fromFeature:(NSString*)jsonStr { NSData* data = [jsonStr dataUsingEncoding:NSUTF8StringEncoding]; - MGLPointFeature *feature = (MGLPointFeature*)[MGLShape shapeWithData:data encoding:NSUTF8StringEncoding error:nil]; + MLNPointFeature *feature = (MLNPointFeature*)[MLNShape shapeWithData:data encoding:NSUTF8StringEncoding error:nil]; return feature.coordinate; } @@ -27,11 +27,11 @@ + (UIEdgeInsets)toUIEdgeInsets:(NSArray *)arr return UIEdgeInsetsMake([arr[0] floatValue], [arr[1] floatValue], [arr[2] floatValue], [arr[3] floatValue]); } -+ (MGLShape*)shapeFromGeoJSON:(NSString*)jsonStr ++ (MLNShape*)shapeFromGeoJSON:(NSString*)jsonStr { NSData* data = [jsonStr dataUsingEncoding:NSUTF8StringEncoding]; NSError* error = nil; - MGLShape* result = [MGLShape shapeWithData:data encoding:NSUTF8StringEncoding error:&error]; + MLNShape* result = [MLNShape shapeWithData:data encoding:NSUTF8StringEncoding error:&error]; if (error != nil) { RCTLogWarn(@"Failed to convert data to shape error:%@ src:%@", error, jsonStr); } @@ -47,18 +47,18 @@ + (NSString *)hashURI:(NSString *)uri return [NSString stringWithFormat:@"%lu", (unsigned long)hash]; } -+ (MGLCoordinateBounds)fromFeatureCollection:(NSString*)jsonStr ++ (MLNCoordinateBounds)fromFeatureCollection:(NSString*)jsonStr { NSData* data = [jsonStr dataUsingEncoding:NSUTF8StringEncoding]; - MGLShapeCollectionFeature *featureCollection = (MGLShapeCollectionFeature*)[MGLShapeCollectionFeature shapeWithData:data encoding:NSUTF8StringEncoding error:nil]; + MLNShapeCollectionFeature *featureCollection = (MLNShapeCollectionFeature*)[MLNShapeCollectionFeature shapeWithData:data encoding:NSUTF8StringEncoding error:nil]; CLLocationCoordinate2D ne = featureCollection.shapes[0].coordinate; CLLocationCoordinate2D sw = featureCollection.shapes[1].coordinate; - return MGLCoordinateBoundsMake(sw, ne); + return MLNCoordinateBoundsMake(sw, ne); } -+ (NSArray *)fromCoordinateBounds:(MGLCoordinateBounds)bounds ++ (NSArray *)fromCoordinateBounds:(MLNCoordinateBounds)bounds { return @[ @[@(bounds.ne.longitude), @(bounds.ne.latitude)], @@ -90,10 +90,10 @@ + (CGVector)toCGVector:(NSArray *)arr + (void)fetchImage:(RCTBridge*)bridge url:(NSString *)url scale:(double)scale callback:(RCTImageLoaderCompletionBlock)callback { - [RCTMGLImageQueue.sharedInstance addImage:url scale:scale bridge:bridge completionHandler:callback]; + [RCTMLNImageQueue.sharedInstance addImage:url scale:scale bridge:bridge completionHandler:callback]; } -+ (void)fetchImages:(RCTBridge *)bridge style:(MGLStyle *)style objects:(NSDictionary*)objects forceUpdate:(BOOL)forceUpdate callback:(void (^)(void))callback ++ (void)fetchImages:(RCTBridge *)bridge style:(MLNStyle *)style objects:(NSDictionary*)objects forceUpdate:(BOOL)forceUpdate callback:(void (^)(void))callback { if (objects == nil) { callback(); @@ -107,7 +107,7 @@ + (void)fetchImages:(RCTBridge *)bridge style:(MGLStyle *)style objects:(NSDicti } __block NSUInteger imagesLeftToLoad = imageNames.count; - __weak MGLStyle *weakStyle = style; + __weak MLNStyle *weakStyle = style; void (^imageLoadedBlock)(void) = ^{ imagesLeftToLoad--; @@ -124,7 +124,7 @@ + (void)fetchImages:(RCTBridge *)bridge style:(MGLStyle *)style objects:(NSDicti NSDictionary* image = objects[imageName]; BOOL hasScale = [image isKindOfClass:[NSDictionary class]] && ([image objectForKey:@"scale"] != nil); double scale = hasScale ? [[image objectForKey:@"scale"] doubleValue] : 1.0; - [RCTMGLImageQueue.sharedInstance addImage:objects[imageName] scale:scale bridge:bridge completionHandler:^(NSError *error, UIImage *image) { + [RCTMLNImageQueue.sharedInstance addImage:objects[imageName] scale:scale bridge:bridge completionHandler:^(NSError *error, UIImage *image) { if (!image) { RCTLogWarn(@"Failed to fetch image: %@ error:%@", imageName, error); } @@ -145,7 +145,7 @@ + (NSString*)getStyleJsonTempDirectory { static NSString *styleJsonTempDirectory; if (!styleJsonTempDirectory) { - styleJsonTempDirectory = [NSTemporaryDirectory() stringByAppendingPathComponent:@"RCTMGLStyleJSON"]; + styleJsonTempDirectory = [NSTemporaryDirectory() stringByAppendingPathComponent:@"RCTMLNStyleJSON"]; } return styleJsonTempDirectory; } @@ -159,7 +159,7 @@ + (NSString*)getStyleJsonTempDirectory + (void)cleanCustomStyleJSONCacheIfNeeded { NSFileManager *fileManager = [NSFileManager defaultManager]; - NSString *styleJsonTempDirectory = [RCTMGLUtils getStyleJsonTempDirectory]; + NSString *styleJsonTempDirectory = [RCTMLNUtils getStyleJsonTempDirectory]; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ @@ -175,10 +175,10 @@ + (void)cleanCustomStyleJSONCacheIfNeeded */ + (NSURL*)styleURLFromStyleJSON:(NSString *)styleJSON { - [RCTMGLUtils cleanCustomStyleJSONCacheIfNeeded]; + [RCTMLNUtils cleanCustomStyleJSONCacheIfNeeded]; NSFileManager *fileManager = [NSFileManager defaultManager]; - NSString *styleJsonTempDirectory = [RCTMGLUtils getStyleJsonTempDirectory]; + NSString *styleJsonTempDirectory = [RCTMLNUtils getStyleJsonTempDirectory]; // attempt to create the temporary directory if (![fileManager fileExistsAtPath:styleJsonTempDirectory]) { diff --git a/ios/RCTMGL/RCTMGLVectorLayer.h b/ios/RCTMLN/RCTMLNVectorLayer.h similarity index 62% rename from ios/RCTMGL/RCTMGLVectorLayer.h rename to ios/RCTMLN/RCTMLNVectorLayer.h index 6e7e2385d..ff0edff8e 100644 --- a/ios/RCTMGL/RCTMGLVectorLayer.h +++ b/ios/RCTMLN/RCTMLNVectorLayer.h @@ -1,14 +1,14 @@ // -// RCTMGLCircleLayer.h -// RCTMGL +// RCTMLNCircleLayer.h +// RCTMLN // // Created by Nick Italiano on 9/18/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLLayer.h" +#import "RCTMLNLayer.h" -@interface RCTMGLVectorLayer : RCTMGLLayer +@interface RCTMLNVectorLayer : RCTMLNLayer @property (nonatomic, copy) NSString *sourceLayerID; diff --git a/ios/RCTMGL/RCTMGLVectorLayer.m b/ios/RCTMLN/RCTMLNVectorLayer.m similarity index 80% rename from ios/RCTMGL/RCTMGLVectorLayer.m rename to ios/RCTMLN/RCTMLNVectorLayer.m index 39a188ed1..04295095f 100644 --- a/ios/RCTMGL/RCTMGLVectorLayer.m +++ b/ios/RCTMLN/RCTMLNVectorLayer.m @@ -1,17 +1,17 @@ // -// RCTMGLCircleLayer.m -// RCTMGL +// RCTMLNCircleLayer.m +// RCTMLN // // Created by Nick Italiano on 9/18/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLVectorLayer.h" -#import "RCTMGLStyle.h" +#import "RCTMLNVectorLayer.h" +#import "RCTMLNStyle.h" #import "FilterParser.h" #import -@implementation RCTMGLVectorLayer +@implementation RCTMLNVectorLayer - (NSPredicate*)buildFilters @@ -22,7 +22,7 @@ - (NSPredicate*)buildFilters - (void)updateFilter:(NSPredicate *)predicate { @try { - ((MGLVectorStyleLayer *) self.styleLayer).predicate = predicate; + ((MLNVectorStyleLayer *) self.styleLayer).predicate = predicate; } @catch (NSException* exception) { RCTLogError(@"Invalid predicate: %@ on layer %@ - %@ reason: %@", predicate, self, exception.name, exception.reason); @@ -34,7 +34,7 @@ - (void)setSourceLayerID:(NSString *)sourceLayerID _sourceLayerID = sourceLayerID; if (self.styleLayer != nil) { - ((MGLVectorStyleLayer*) self.styleLayer).sourceLayerIdentifier = _sourceLayerID; + ((MLNVectorStyleLayer*) self.styleLayer).sourceLayerIdentifier = _sourceLayerID; } } diff --git a/ios/RCTMGL/RCTMGLVectorSource.h b/ios/RCTMLN/RCTMLNVectorSource.h similarity index 53% rename from ios/RCTMGL/RCTMGLVectorSource.h rename to ios/RCTMLN/RCTMLNVectorSource.h index 98263940d..f68cb5d15 100644 --- a/ios/RCTMGL/RCTMGLVectorSource.h +++ b/ios/RCTMLN/RCTMLNVectorSource.h @@ -1,16 +1,16 @@ // -// RCTMGLVectorSource.h -// RCTMGL +// RCTMLNVectorSource.h +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLTileSource.h" -@import Mapbox; +#import "RCTMLNTileSource.h" +@import MapLibre; -@interface RCTMGLVectorSource : RCTMGLTileSource +@interface RCTMLNVectorSource : RCTMLNTileSource -- (nonnull NSArray> *)featuresInSourceLayersWithIdentifiers:(nonnull NSSet *)sourceLayerIdentifiers predicate:(nullable NSPredicate *)predicate; +- (nonnull NSArray> *)featuresInSourceLayersWithIdentifiers:(nonnull NSSet *)sourceLayerIdentifiers predicate:(nullable NSPredicate *)predicate; @end diff --git a/ios/RCTMGL/RCTMGLVectorSource.m b/ios/RCTMLN/RCTMLNVectorSource.m similarity index 56% rename from ios/RCTMGL/RCTMGLVectorSource.m rename to ios/RCTMLN/RCTMLNVectorSource.m index 84e5ff51f..1eb6f4f5b 100644 --- a/ios/RCTMGL/RCTMGLVectorSource.m +++ b/ios/RCTMLN/RCTMLNVectorSource.m @@ -1,26 +1,26 @@ // -// RCTMGLVectorSource.m -// RCTMGL +// RCTMLNVectorSource.m +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // -#import "RCTMGLVectorSource.h" +#import "RCTMLNVectorSource.h" -@implementation RCTMGLVectorSource +@implementation RCTMLNVectorSource -- (nullable MGLSource*)makeSource +- (nullable MLNSource*)makeSource { if (self.url != nil) { - return [[MGLVectorTileSource alloc] initWithIdentifier:self.id configurationURL:[NSURL URLWithString:self.url]]; + return [[MLNVectorTileSource alloc] initWithIdentifier:self.id configurationURL:[NSURL URLWithString:self.url]]; } - return [[MGLVectorTileSource alloc] initWithIdentifier:self.id tileURLTemplates:self.tileUrlTemplates options:[self getOptions]]; + return [[MLNVectorTileSource alloc] initWithIdentifier:self.id tileURLTemplates:self.tileUrlTemplates options:[self getOptions]]; } -- (nonnull NSArray> *)featuresInSourceLayersWithIdentifiers:(nonnull NSSet *)sourceLayerIdentifiers predicate:(nullable NSPredicate *)predicate +- (nonnull NSArray> *)featuresInSourceLayersWithIdentifiers:(nonnull NSSet *)sourceLayerIdentifiers predicate:(nullable NSPredicate *)predicate { - MGLVectorTileSource* vectorSource = (MGLVectorTileSource*)self.source; + MLNVectorTileSource* vectorSource = (MLNVectorTileSource*)self.source; return [vectorSource featuresInSourceLayersWithIdentifiers:sourceLayerIdentifiers predicate: predicate]; } diff --git a/ios/RCTMGL/RCTMGLVectorSourceManager.h b/ios/RCTMLN/RCTMLNVectorSourceManager.h similarity index 61% rename from ios/RCTMGL/RCTMGLVectorSourceManager.h rename to ios/RCTMLN/RCTMLNVectorSourceManager.h index 5d1b5cefd..66eb42070 100644 --- a/ios/RCTMGL/RCTMGLVectorSourceManager.h +++ b/ios/RCTMLN/RCTMLNVectorSourceManager.h @@ -1,6 +1,6 @@ // -// RCTMGLVectorSourceManager.h -// RCTMGL +// RCTMLNVectorSourceManager.h +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -9,6 +9,6 @@ #import "ViewManager.h" #import -@interface RCTMGLVectorSourceManager : ViewManager +@interface RCTMLNVectorSourceManager : ViewManager @end diff --git a/ios/RCTMGL/RCTMGLVectorSourceManager.m b/ios/RCTMLN/RCTMLNVectorSourceManager.m similarity index 83% rename from ios/RCTMGL/RCTMGLVectorSourceManager.m rename to ios/RCTMLN/RCTMLNVectorSourceManager.m index 662156e90..a0aed68c1 100644 --- a/ios/RCTMGL/RCTMGLVectorSourceManager.m +++ b/ios/RCTMLN/RCTMLNVectorSourceManager.m @@ -1,6 +1,6 @@ // -// RCTMGLVectorSourceManager.m -// RCTMGL +// RCTMLNVectorSourceManager.m +// RCTMLN // // Created by Nick Italiano on 9/8/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -8,20 +8,20 @@ #import -#import "RCTMGLVectorSourceManager.h" -#import "RCTMGLVectorSource.h" +#import "RCTMLNVectorSourceManager.h" +#import "RCTMLNVectorSource.h" #import "FilterParser.h" -@implementation RCTMGLVectorSourceManager +@implementation RCTMLNVectorSourceManager -RCT_EXPORT_MODULE(RCTMGLVectorSource); +RCT_EXPORT_MODULE(RCTMLNVectorSource); RCT_EXPORT_VIEW_PROPERTY(id, NSString); - (UIView*)view { - return [RCTMGLVectorSource new]; + return [RCTMLNVectorSource new]; } RCT_EXPORT_VIEW_PROPERTY(url, NSString) @@ -44,10 +44,10 @@ - (UIView*)view rejecter:(RCTPromiseRejectBlock)reject) { [self.bridge.uiManager addUIBlock:^(__unused RCTUIManager *manager, NSDictionary *viewRegistry) { - RCTMGLVectorSource* vectorSource = viewRegistry[reactTag]; + RCTMLNVectorSource* vectorSource = viewRegistry[reactTag]; - if (![vectorSource isKindOfClass:[RCTMGLVectorSource class]]) { - RCTLogError(@"Invalid react tag, could not find RCTMGLMapView"); + if (![vectorSource isKindOfClass:[RCTMLNVectorSource class]]) { + RCTLogError(@"Invalid react tag, could not find RCTMLNMapView"); return; } @@ -56,7 +56,7 @@ - (UIView*)view layerIDSet = [NSSet setWithArray:layerIDs]; } NSPredicate* predicate = [FilterParser parse:filter]; - NSArray> *shapes = [vectorSource + NSArray> *shapes = [vectorSource featuresInSourceLayersWithIdentifiers: layerIDSet predicate: predicate]; diff --git a/ios/RCTMGL/RNMBImageUtils.h b/ios/RCTMLN/RNMBImageUtils.h similarity index 96% rename from ios/RCTMGL/RNMBImageUtils.h rename to ios/RCTMLN/RNMBImageUtils.h index 8800fe3ca..1f095ec6f 100644 --- a/ios/RCTMGL/RNMBImageUtils.h +++ b/ios/RCTMLN/RNMBImageUtils.h @@ -1,6 +1,6 @@ // // RNMBImageUtils.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 1/18/18. // Copyright © 2018 Mapbox Inc. All rights reserved. diff --git a/ios/RCTMGL/RNMBImageUtils.m b/ios/RCTMLN/RNMBImageUtils.m similarity index 93% rename from ios/RCTMGL/RNMBImageUtils.m rename to ios/RCTMLN/RNMBImageUtils.m index be9674998..12a280949 100644 --- a/ios/RCTMGL/RNMBImageUtils.m +++ b/ios/RCTMLN/RNMBImageUtils.m @@ -1,6 +1,6 @@ // // RNMBImageUtils.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 1/18/18. // Copyright © 2018 Mapbox Inc. All rights reserved. @@ -13,7 +13,7 @@ @implementation RNMBImageUtils + (NSString *)createTempFile:(UIImage *)image { NSString *fileID = [[NSUUID UUID] UUIDString]; - NSString *pathComponent = [NSString stringWithFormat:@"Documents/rctmgl-snapshot-%@.%@", fileID, @"png"]; + NSString *pathComponent = [NSString stringWithFormat:@"Documents/rctmln-snapshot-%@.%@", fileID, @"png"]; NSString *filePath = [NSHomeDirectory() stringByAppendingPathComponent: pathComponent]; NSData *data = UIImagePNGRepresentation(image); diff --git a/ios/RCTMGL/ViewManager.h b/ios/RCTMLN/ViewManager.h similarity index 69% rename from ios/RCTMGL/ViewManager.h rename to ios/RCTMLN/ViewManager.h index 83a5b1d8b..9d6329a7c 100644 --- a/ios/RCTMGL/ViewManager.h +++ b/ios/RCTMLN/ViewManager.h @@ -1,16 +1,16 @@ // // ViewManager.h -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 8/31/17. // Copyright © 2017 Mapbox Inc. All rights reserved. // #import -#import "RCTMGLEvent.h" +#import "RCTMLNEvent.h" @interface ViewManager : RCTViewManager --(void)fireEvent:(RCTMGLEvent*)event withCallback:(RCTBubblingEventBlock)callback; +-(void)fireEvent:(RCTMLNEvent*)event withCallback:(RCTBubblingEventBlock)callback; @end diff --git a/ios/RCTMGL/ViewManager.m b/ios/RCTMLN/ViewManager.m similarity index 88% rename from ios/RCTMGL/ViewManager.m rename to ios/RCTMLN/ViewManager.m index 6eb5cd2aa..92045f1bc 100644 --- a/ios/RCTMGL/ViewManager.m +++ b/ios/RCTMLN/ViewManager.m @@ -1,6 +1,6 @@ // // ViewManager.m -// RCTMGL +// RCTMLN // // Created by Nick Italiano on 8/31/17. // Copyright © 2017 Mapbox Inc. All rights reserved. @@ -35,7 +35,7 @@ - (instancetype)init return self; } -- (void)fireEvent:(RCTMGLEvent*)event withCallback:(RCTBubblingEventBlock)callback +- (void)fireEvent:(RCTMLNEvent*)event withCallback:(RCTBubblingEventBlock)callback { if (![self _shouldDropEvent:event]) { NSString *cacheKey = [self _getCacheKey:event]; @@ -48,14 +48,14 @@ - (void)fireEvent:(RCTMGLEvent*)event withCallback:(RCTBubblingEventBlock)callba } } -- (BOOL)_shouldDropEvent:(RCTMGLEvent *)event +- (BOOL)_shouldDropEvent:(RCTMLNEvent *)event { NSString *cacheKey = [self _getCacheKey:event]; NSNumber *lastTimestamp = [eventTimestampCache objectForKey:cacheKey]; return lastTimestamp != nil && (event.timestamp - [lastTimestamp doubleValue]) <= EVENT_THROTTLE_S; } -- (NSString*)_getCacheKey:(RCTMGLEvent*)event +- (NSString*)_getCacheKey:(RCTMLNEvent*)event { return event.type; } diff --git a/ios/RCTMGL/index.d.ts b/ios/RCTMLN/index.d.ts similarity index 100% rename from ios/RCTMGL/index.d.ts rename to ios/RCTMLN/index.d.ts diff --git a/ios/install.md b/ios/install.md index 79612ff24..cf2997985 100644 --- a/ios/install.md +++ b/ios/install.md @@ -12,7 +12,7 @@ Add the following to your `ios/Podfile`: end ``` -Running `pod install` will add version `5.13.0` of the MapLibre SDK. +Running `pod install` will add version `6.4.0` of the MapLibre SDK. ```sh # Go to the ios directory @@ -34,7 +34,7 @@ until this is fixed upstream. iOS devs can open the workspace in Xcode and run f ## Installing a specific version -The current default MapLibre version is `5.13.0`. +The current default MapLibre version is `6.4.0`. If you want to install a different version, you can override as follows in your `Podfile`: @@ -43,8 +43,8 @@ $RNMBGL_Use_SPM = { url: "https://github.com/maplibre/maplibre-gl-native-distribution", requirement: { kind: "upToNextMajorVersion", - minimumVersion: "5.13.0" + minimumVersion: "6.4.0" }, - product_name: "Mapbox" + product_name: "MapLibre" } ``` diff --git a/javascript/MGLModule.ts b/javascript/MLNModule.ts similarity index 87% rename from javascript/MGLModule.ts rename to javascript/MLNModule.ts index 9d030af54..d90d705c4 100644 --- a/javascript/MGLModule.ts +++ b/javascript/MLNModule.ts @@ -1,6 +1,6 @@ import {NativeModules} from 'react-native'; -interface IMGLModule { +interface IMLNModule { StyleURL: { Default: URL; }; @@ -24,7 +24,7 @@ interface IMGLModule { setConnected(connected: boolean): void; } -const MGLModule: IMGLModule = {...NativeModules.MGLModule}; +const MLNModule: IMLNModule = {...NativeModules.MLNModule}; export const { StyleURL, @@ -34,4 +34,4 @@ export const { setAccessToken, getAccessToken, setConnected, -} = MGLModule; +} = MLNModule; diff --git a/javascript/Maplibre.ts b/javascript/Maplibre.ts index 91e28b889..48ce643bc 100644 --- a/javascript/Maplibre.ts +++ b/javascript/Maplibre.ts @@ -1,4 +1,4 @@ -export * from './MGLModule'; +export * from './MLNModule'; export { default as Camera, UserTrackingMode, diff --git a/javascript/components/BackgroundLayer.tsx b/javascript/components/BackgroundLayer.tsx index 8b2ced253..4ee5a849f 100644 --- a/javascript/components/BackgroundLayer.tsx +++ b/javascript/components/BackgroundLayer.tsx @@ -6,9 +6,9 @@ import AbstractLayer, {BaseLayerProps, NativeBaseProps} from './AbstractLayer'; import React, {ReactNode} from 'react'; import {NativeModules, requireNativeComponent} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLBackgroundLayer'; +export const NATIVE_MODULE_NAME = 'RCTMLNBackgroundLayer'; interface BackgroundLayerProps extends BaseProps, BaseLayerProps { /** @@ -28,8 +28,8 @@ class BackgroundLayer extends AbstractLayer { render(): ReactNode { return ( - @@ -37,7 +37,7 @@ class BackgroundLayer extends AbstractLayer { } } -const RCTMGLBackgroundLayer = +const RCTMLNBackgroundLayer = requireNativeComponent(NATIVE_MODULE_NAME); export default BackgroundLayer; diff --git a/javascript/components/Callout.tsx b/javascript/components/Callout.tsx index df0faf81f..2a1abc201 100644 --- a/javascript/components/Callout.tsx +++ b/javascript/components/Callout.tsx @@ -10,7 +10,7 @@ import { StyleProp, } from 'react-native'; -export const NATIVE_MODULE_NAME = 'RCTMGLCallout'; +export const NATIVE_MODULE_NAME = 'RCTMLNCallout'; const styles = StyleSheet.create({ container: { @@ -58,7 +58,7 @@ interface CalloutProps extends Omit { */ style?: ViewStyle; /** - * Style property for the native RCTMGLCallout container, set at your own risk. + * Style property for the native RCTMLNCallout container, set at your own risk. */ containerStyle?: ViewStyle; /** @@ -129,13 +129,13 @@ class Callout extends React.PureComponent { ? this._renderCustomCallout() : this._renderDefaultCallout(); return ( - + {calloutContent} - +
); } } -const RCTMGLCallout = requireNativeComponent(NATIVE_MODULE_NAME); +const RCTMLNCallout = requireNativeComponent(NATIVE_MODULE_NAME); export default Callout; diff --git a/javascript/components/Camera.tsx b/javascript/components/Camera.tsx index 048409936..4d327e928 100644 --- a/javascript/components/Camera.tsx +++ b/javascript/components/Camera.tsx @@ -10,9 +10,9 @@ import { } from 'react-native'; import React, {Component, MutableRefObject, ReactElement} from 'react'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLCamera'; +export const NATIVE_MODULE_NAME = 'RCTMLNCamera'; export enum UserTrackingMode { Follow = 'normal', @@ -656,7 +656,7 @@ class Camera extends React.Component { }; return ( - { } } -const RCTMGLCamera = requireNativeComponent(NATIVE_MODULE_NAME); +const RCTMLNCamera = requireNativeComponent(NATIVE_MODULE_NAME); export default Camera; diff --git a/javascript/components/CircleLayer.tsx b/javascript/components/CircleLayer.tsx index 48582119f..359c8a6d8 100644 --- a/javascript/components/CircleLayer.tsx +++ b/javascript/components/CircleLayer.tsx @@ -6,9 +6,9 @@ import AbstractLayer, {BaseLayerProps, NativeBaseProps} from './AbstractLayer'; import React, {ReactElement} from 'react'; import {NativeModules, requireNativeComponent} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLCircleLayer'; +export const NATIVE_MODULE_NAME = 'RCTMLNCircleLayer'; interface CircleLayerProps extends BaseProps, BaseLayerProps { /** @@ -31,8 +31,8 @@ class CircleLayer extends AbstractLayer { render(): ReactElement { return ( - @@ -40,7 +40,7 @@ class CircleLayer extends AbstractLayer { } } -const RCTMGLCircleLayer = +const RCTMLNCircleLayer = requireNativeComponent(NATIVE_MODULE_NAME); export default CircleLayer; diff --git a/javascript/components/FillExtrusionLayer.tsx b/javascript/components/FillExtrusionLayer.tsx index 5107d8ca5..84e8581fb 100644 --- a/javascript/components/FillExtrusionLayer.tsx +++ b/javascript/components/FillExtrusionLayer.tsx @@ -6,9 +6,9 @@ import AbstractLayer, {BaseLayerProps, NativeBaseProps} from './AbstractLayer'; import React, {ReactElement} from 'react'; import {NativeModules, requireNativeComponent} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLFillExtrusionLayer'; +export const NATIVE_MODULE_NAME = 'RCTMLNFillExtrusionLayer'; interface FillExtrusionLayerProps extends BaseProps, BaseLayerProps { /** @@ -37,11 +37,11 @@ class FillExtrusionLayer extends AbstractLayer< ...this.baseProps, sourceLayerID: this.props.sourceLayerID, }; - return ; + return ; } } -const RCTMGLFillExtrusionLayer = +const RCTMLNFillExtrusionLayer = requireNativeComponent(NATIVE_MODULE_NAME); export default FillExtrusionLayer; diff --git a/javascript/components/FillLayer.tsx b/javascript/components/FillLayer.tsx index 8d3211bb9..7bd34d499 100644 --- a/javascript/components/FillLayer.tsx +++ b/javascript/components/FillLayer.tsx @@ -6,9 +6,9 @@ import AbstractLayer, {BaseLayerProps, NativeBaseProps} from './AbstractLayer'; import React, {ReactElement} from 'react'; import {NativeModules, requireNativeComponent} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLFillLayer'; +export const NATIVE_MODULE_NAME = 'RCTMLNFillLayer'; interface FillLayerProps extends BaseProps, BaseLayerProps { /** @@ -32,10 +32,10 @@ class FillLayer extends AbstractLayer { ...this.baseProps, sourceLayerID: this.props.sourceLayerID, }; - return ; + return ; } } -const RCTMGLFillLayer = requireNativeComponent(NATIVE_MODULE_NAME); +const RCTMLNFillLayer = requireNativeComponent(NATIVE_MODULE_NAME); export default FillLayer; diff --git a/javascript/components/HeatmapLayer.tsx b/javascript/components/HeatmapLayer.tsx index b60e1ebc2..0348bbcff 100644 --- a/javascript/components/HeatmapLayer.tsx +++ b/javascript/components/HeatmapLayer.tsx @@ -6,9 +6,9 @@ import AbstractLayer, {BaseLayerProps, NativeBaseProps} from './AbstractLayer'; import React, {ReactElement} from 'react'; import {NativeModules, requireNativeComponent} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLHeatmapLayer'; +export const NATIVE_MODULE_NAME = 'RCTMLNHeatmapLayer'; interface HeatmapLayerProps extends BaseProps, BaseLayerProps { /** @@ -34,11 +34,11 @@ class HeatmapLayer extends AbstractLayer { ...this.baseProps, sourceLayerID: this.props.sourceLayerID, }; - return ; + return ; } } -const RCTMGLHeatmapLayer = +const RCTMLNHeatmapLayer = requireNativeComponent(NATIVE_MODULE_NAME); export default HeatmapLayer; diff --git a/javascript/components/ImageSource.tsx b/javascript/components/ImageSource.tsx index bb67c3ee7..1df3d0208 100644 --- a/javascript/components/ImageSource.tsx +++ b/javascript/components/ImageSource.tsx @@ -10,7 +10,7 @@ import AbstractSource from './AbstractSource'; import {requireNativeComponent} from 'react-native'; import React, {ReactElement} from 'react'; -export const NATIVE_MODULE_NAME = 'RCTMGLImageSource'; +export const NATIVE_MODULE_NAME = 'RCTMLNImageSource'; interface ImageSourceProps extends BaseProps { /** @@ -63,16 +63,16 @@ class ImageSource extends AbstractSource { }; return ( - + {cloneReactChildrenWithProps(this.props.children, { sourceID: this.props.id, })} - + ); } } -const RCTMGLImageSource = +const RCTMLNImageSource = requireNativeComponent(NATIVE_MODULE_NAME); export default ImageSource; diff --git a/javascript/components/Images.tsx b/javascript/components/Images.tsx index 388dd8465..0c721041b 100644 --- a/javascript/components/Images.tsx +++ b/javascript/components/Images.tsx @@ -11,7 +11,7 @@ import { ImageURISource, } from 'react-native'; -export const NATIVE_MODULE_NAME = 'RCTMGLImages'; +export const NATIVE_MODULE_NAME = 'RCTMLNImages'; export type ImageEntry = string | ImageSourcePropType; @@ -125,10 +125,10 @@ class Images extends React.Component { ...this._getImages(), }; - return {this.props.children}; + return {this.props.children}; } } -const RCTMGLImages = requireNativeComponent(NATIVE_MODULE_NAME); +const RCTMLNImages = requireNativeComponent(NATIVE_MODULE_NAME); export default Images; diff --git a/javascript/components/Light.tsx b/javascript/components/Light.tsx index e75ec6b0f..b34c4d068 100644 --- a/javascript/components/Light.tsx +++ b/javascript/components/Light.tsx @@ -12,7 +12,7 @@ import React, { } from 'react'; import {NativeMethods, requireNativeComponent} from 'react-native'; -export const NATIVE_MODULE_NAME = 'RCTMGLLight'; +export const NATIVE_MODULE_NAME = 'RCTMLNLight'; interface LightProps extends BaseProps { /** @@ -52,9 +52,9 @@ class Light extends AbstractLayer { render(): ReactElement { return ( - @@ -62,6 +62,6 @@ class Light extends AbstractLayer { } } -const RCTMGLLight = requireNativeComponent(NATIVE_MODULE_NAME); +const RCTMLNLight = requireNativeComponent(NATIVE_MODULE_NAME); export default Light; diff --git a/javascript/components/LineLayer.tsx b/javascript/components/LineLayer.tsx index b1a5447f0..f4b5cf8a5 100644 --- a/javascript/components/LineLayer.tsx +++ b/javascript/components/LineLayer.tsx @@ -6,9 +6,9 @@ import AbstractLayer, {BaseLayerProps, NativeBaseProps} from './AbstractLayer'; import React, {ReactElement} from 'react'; import {NativeModules, requireNativeComponent} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLLineLayer'; +export const NATIVE_MODULE_NAME = 'RCTMLNLineLayer'; interface LineLayerProps extends BaseProps, BaseLayerProps { /** @@ -32,11 +32,11 @@ class LineLayer extends AbstractLayer { ...this.baseProps, sourceLayerID: this.props.sourceLayerID, }; - return ; + return ; } } -const RCTMGLLineLayer = +const RCTMLNLineLayer = requireNativeComponent(NATIVE_MODULE_NAME); export default LineLayer; diff --git a/javascript/components/MapView.tsx b/javascript/components/MapView.tsx index 4e48ac3ff..d6bc9f6ce 100644 --- a/javascript/components/MapView.tsx +++ b/javascript/components/MapView.tsx @@ -20,16 +20,16 @@ import { } from 'react-native'; import debounce from 'debounce'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; if (MapLibreGL == null) { console.error( 'Native part of Mapbox React Native libraries were not registered properly, double check our native installation guides.', ); } -export const NATIVE_MODULE_NAME = 'RCTMGLMapView'; +export const NATIVE_MODULE_NAME = 'RCTMLNMapView'; -export const ANDROID_TEXTURE_NATIVE_MODULE_NAME = 'RCTMGLAndroidTextureMapView'; +export const ANDROID_TEXTURE_NATIVE_MODULE_NAME = 'RCTMLNAndroidTextureMapView'; const styles = StyleSheet.create({ matchParent: {flex: 1}, @@ -70,7 +70,7 @@ interface MapViewProps extends BaseProps { styleJSON?: string; /** * iOS: The preferred frame rate at which the map view is rendered. - * The default value for this property is MGLMapViewPreferredFramesPerSecondDefault, + * The default value for this property is MLNMapViewPreferredFramesPerSecondDefault, * which will adaptively set the preferred frame rate based on the capability of * the user’s device to maintain a smooth experience. This property can be set to arbitrary integer values. * @@ -298,7 +298,7 @@ class MapView extends NativeBridgeComponent( }; logger: Logger; - _nativeRef?: RCTMGLMapViewRefType; + _nativeRef?: RCTMLNMapViewRefType; _onDebouncedRegionWillChange: ReturnType; _onDebouncedRegionDidChange: ReturnType; @@ -741,7 +741,7 @@ class MapView extends NativeBridgeComponent( return this.props.contentInset; } - _setNativeRef(nativeRef: RCTMGLMapViewRefType): void { + _setNativeRef(nativeRef: RCTMLNMapViewRefType): void { this._nativeRef = nativeRef; super._runPendingNativeCommands(nativeRef); } @@ -780,7 +780,7 @@ class MapView extends NativeBridgeComponent( this._setStyleURL(props); const callbacks = { - ref: (ref: RCTMGLMapViewRefType) => this._setNativeRef(ref), + ref: (ref: RCTMLNMapViewRefType) => this._setNativeRef(ref), onPress: this._onPress, onLongPress: this._onLongPress, onMapChange: this._onChange, @@ -790,15 +790,15 @@ class MapView extends NativeBridgeComponent( let mapView: ReactElement | null = null; if (isAndroid() && !this.props.surfaceView && this.state.isReady) { mapView = ( - + {this.props.children} - + ); } else if (this.state.isReady) { mapView = ( - + {this.props.children} - + ); } @@ -813,12 +813,12 @@ class MapView extends NativeBridgeComponent( } } -type RCTMGLMapViewRefType = Component & Readonly; -const RCTMGLMapView = requireNativeComponent(NATIVE_MODULE_NAME); +type RCTMLNMapViewRefType = Component & Readonly; +const RCTMLNMapView = requireNativeComponent(NATIVE_MODULE_NAME); -let RCTMGLAndroidTextureMapView: typeof RCTMGLMapView; +let RCTMLNAndroidTextureMapView: typeof RCTMLNMapView; if (isAndroid()) { - RCTMGLAndroidTextureMapView = requireNativeComponent( + RCTMLNAndroidTextureMapView = requireNativeComponent( ANDROID_TEXTURE_NATIVE_MODULE_NAME, ); } diff --git a/javascript/components/MarkerView.tsx b/javascript/components/MarkerView.tsx index 514db12b0..0a705abfc 100644 --- a/javascript/components/MarkerView.tsx +++ b/javascript/components/MarkerView.tsx @@ -6,7 +6,7 @@ import PointAnnotation from './PointAnnotation'; import React, {ReactElement} from 'react'; import {Platform, requireNativeComponent, ViewProps} from 'react-native'; -export const NATIVE_MODULE_NAME = 'RCTMGLMarkerView'; +export const NATIVE_MODULE_NAME = 'RCTMLNMarkerView'; interface MarkerViewProps extends ViewProps { /** @@ -93,12 +93,12 @@ class MarkerView extends React.PureComponent { }; return ( - {this.props.children} + {this.props.children} ); } } -const RCTMGLMarkerView = +const RCTMLNMarkerView = requireNativeComponent(NATIVE_MODULE_NAME); export default MarkerView; diff --git a/javascript/components/NativeUserLocation.tsx b/javascript/components/NativeUserLocation.tsx index 72799f033..8dcd58829 100644 --- a/javascript/components/NativeUserLocation.tsx +++ b/javascript/components/NativeUserLocation.tsx @@ -1,7 +1,7 @@ import React, {ReactElement} from 'react'; import {requireNativeComponent} from 'react-native'; -const NATIVE_MODULE_NAME = 'RCTMGLNativeUserLocation'; +const NATIVE_MODULE_NAME = 'RCTMLNNativeUserLocation'; interface NativeUserLocationProps { /** @@ -24,10 +24,10 @@ interface NativeUserLocationProps { class NativeUserLocation extends React.Component { render(): ReactElement { - return ; + return ; } } -const RCTMGLNativeUserLocation = requireNativeComponent(NATIVE_MODULE_NAME); +const RCTMLNNativeUserLocation = requireNativeComponent(NATIVE_MODULE_NAME); export default NativeUserLocation; diff --git a/javascript/components/PointAnnotation.tsx b/javascript/components/PointAnnotation.tsx index 788353abf..6d91163da 100644 --- a/javascript/components/PointAnnotation.tsx +++ b/javascript/components/PointAnnotation.tsx @@ -11,7 +11,7 @@ import { ViewProps, } from 'react-native'; -export const NATIVE_MODULE_NAME = 'RCTMGLPointAnnotation'; +export const NATIVE_MODULE_NAME = 'RCTMLNPointAnnotation'; const styles = StyleSheet.create({ container: { @@ -204,9 +204,9 @@ class PointAnnotation extends NativeBridgeComponent( coordinate: this._getCoordinate(), }; return ( - + {this.props.children} - + ); } } @@ -215,7 +215,7 @@ interface NativeProps extends Omit { coordinate?: string; } -const RCTMGLPointAnnotation = +const RCTMLNPointAnnotation = requireNativeComponent(NATIVE_MODULE_NAME); export default PointAnnotation; diff --git a/javascript/components/RasterLayer.tsx b/javascript/components/RasterLayer.tsx index c07e69786..4dad99e06 100644 --- a/javascript/components/RasterLayer.tsx +++ b/javascript/components/RasterLayer.tsx @@ -6,9 +6,9 @@ import AbstractLayer, {BaseLayerProps, NativeBaseProps} from './AbstractLayer'; import React, {ReactElement} from 'react'; import {NativeModules, requireNativeComponent} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLRasterLayer'; +export const NATIVE_MODULE_NAME = 'RCTMLNRasterLayer'; interface RasterLayerProps extends BaseProps, BaseLayerProps { /** @@ -31,11 +31,11 @@ class RasterLayer extends AbstractLayer { ...this.baseProps, sourceLayerID: this.props.sourceLayerID, }; - return ; + return ; } } -const RCTMGLRasterLayer = +const RCTMLNRasterLayer = requireNativeComponent(NATIVE_MODULE_NAME); export default RasterLayer; diff --git a/javascript/components/RasterSource.tsx b/javascript/components/RasterSource.tsx index 95f0e7d18..3aa6bca1e 100644 --- a/javascript/components/RasterSource.tsx +++ b/javascript/components/RasterSource.tsx @@ -6,9 +6,9 @@ import AbstractSource from './AbstractSource'; import {NativeModules, requireNativeComponent} from 'react-native'; import React, {ReactElement} from 'react'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLRasterSource'; +export const NATIVE_MODULE_NAME = 'RCTMLNRasterSource'; const isTileTemplateUrl = (url?: string): url is string => !!url && @@ -102,16 +102,16 @@ class RasterSource extends AbstractSource { attribution: this.props.attribution, }; return ( - + {cloneReactChildrenWithProps(this.props.children, { sourceID: this.props.id, })} - + ); } } -const RCTMGLRasterSource = +const RCTMLNRasterSource = requireNativeComponent(NATIVE_MODULE_NAME); export default RasterSource; diff --git a/javascript/components/ShapeSource.tsx b/javascript/components/ShapeSource.tsx index da10996ba..8f96a0b45 100644 --- a/javascript/components/ShapeSource.tsx +++ b/javascript/components/ShapeSource.tsx @@ -22,9 +22,9 @@ import { } from 'react-native'; import {Feature, FeatureCollection} from '@turf/helpers'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLShapeSource'; +export const NATIVE_MODULE_NAME = 'RCTMLNShapeSource'; interface ShapeSourceProps extends BaseProps { /** @@ -368,16 +368,16 @@ class ShapeSource extends NativeBridgeComponent( }; return ( - + {cloneReactChildrenWithProps(this.props.children, { sourceID: this.props.id, })} - + ); } } -const RCTMGLShapeSource = +const RCTMLNShapeSource = requireNativeComponent(NATIVE_MODULE_NAME); export default ShapeSource; diff --git a/javascript/components/SymbolLayer.tsx b/javascript/components/SymbolLayer.tsx index d3722c2e8..b1ce50b09 100644 --- a/javascript/components/SymbolLayer.tsx +++ b/javascript/components/SymbolLayer.tsx @@ -6,9 +6,9 @@ import AbstractLayer, {BaseLayerProps, NativeBaseProps} from './AbstractLayer'; import React, {ReactElement} from 'react'; import {View, NativeModules, requireNativeComponent} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLSymbolLayer'; +export const NATIVE_MODULE_NAME = 'RCTMLNSymbolLayer'; interface SymbolLayerProps extends BaseProps, BaseLayerProps { /** @@ -59,14 +59,14 @@ class SymbolLayer extends AbstractLayer { }; return ( - + {this.props.children} - + ); } } -const RCTMGLSymbolLayer = +const RCTMLNSymbolLayer = requireNativeComponent(NATIVE_MODULE_NAME); export default SymbolLayer; diff --git a/javascript/components/VectorSource.tsx b/javascript/components/VectorSource.tsx index c0652c42f..6a461feb8 100644 --- a/javascript/components/VectorSource.tsx +++ b/javascript/components/VectorSource.tsx @@ -17,9 +17,9 @@ import { } from 'react-native'; import {featureCollection} from '@turf/helpers'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; -export const NATIVE_MODULE_NAME = 'RCTMGLVectorSource'; +export const NATIVE_MODULE_NAME = 'RCTMLNVectorSource'; interface VectorSourceProps extends BaseProps { /** @@ -192,16 +192,16 @@ class VectorSource extends NativeBridgeComponent( onAndroidCallback: isAndroid() ? this._onAndroidCallback : undefined, }; return ( - + {cloneReactChildrenWithProps(this.props.children, { sourceID: this.props.id, })} - + ); } } -const RCTMGLVectorSource = +const RCTMLNVectorSource = requireNativeComponent(NATIVE_MODULE_NAME); export default VectorSource; diff --git a/javascript/modules/location/locationManager.ts b/javascript/modules/location/locationManager.ts index 26bb840ae..8d01b436f 100644 --- a/javascript/modules/location/locationManager.ts +++ b/javascript/modules/location/locationManager.ts @@ -4,8 +4,8 @@ import { EmitterSubscription, } from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; -const MapLibreGLLocationManager = NativeModules.MGLLocationModule; +const MapLibreGL = NativeModules.MLNModule; +const MapLibreGLLocationManager = NativeModules.MLNLocationModule; export const LocationModuleEventEmitter = new NativeEventEmitter( MapLibreGLLocationManager, diff --git a/javascript/modules/offline/OfflinePack.ts b/javascript/modules/offline/OfflinePack.ts index ba7892c37..cbc28ca61 100644 --- a/javascript/modules/offline/OfflinePack.ts +++ b/javascript/modules/offline/OfflinePack.ts @@ -2,7 +2,7 @@ import OfflineCreatePackOptions from './OfflineCreatePackOptions'; import {NativeModules} from 'react-native'; -const MapLibreGLOfflineManager = NativeModules.MGLOfflineModule; +const MapLibreGLOfflineManager = NativeModules.MLNOfflineModule; type OfflinePackStatus = { name: string; diff --git a/javascript/modules/offline/offlineManager.ts b/javascript/modules/offline/offlineManager.ts index cdb5e56fa..015ba3ea5 100644 --- a/javascript/modules/offline/offlineManager.ts +++ b/javascript/modules/offline/offlineManager.ts @@ -11,8 +11,8 @@ import { EventSubscription, } from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; -const MapLibreGLOfflineManager = NativeModules.MGLOfflineModule; +const MapLibreGL = NativeModules.MLNModule; +const MapLibreGLOfflineManager = NativeModules.MLNOfflineModule; export const OfflineModuleEventEmitter = new NativeEventEmitter( MapLibreGLOfflineManager, ); diff --git a/javascript/modules/snapshot/SnapshotOptions.ts b/javascript/modules/snapshot/SnapshotOptions.ts index 7816c292c..b3801f380 100644 --- a/javascript/modules/snapshot/SnapshotOptions.ts +++ b/javascript/modules/snapshot/SnapshotOptions.ts @@ -3,7 +3,7 @@ import {makePoint, makeFeatureCollection} from '../../utils/geoUtils'; import {NativeModules} from 'react-native'; -const MapLibreGL = NativeModules.MGLModule; +const MapLibreGL = NativeModules.MLNModule; export interface SnapshotInputOptions { centerCoordinate?: GeoJSON.Position; diff --git a/javascript/modules/snapshot/snapshotManager.ts b/javascript/modules/snapshot/snapshotManager.ts index 2bf105099..802aa98ef 100644 --- a/javascript/modules/snapshot/snapshotManager.ts +++ b/javascript/modules/snapshot/snapshotManager.ts @@ -2,7 +2,7 @@ import SnapshotOptions, {SnapshotInputOptions} from './SnapshotOptions'; import {NativeModules} from 'react-native'; -const MapLibreGLSnapshotManger = NativeModules.MGLSnapshotModule; +const MapLibreGLSnapshotManger = NativeModules.MLNSnapshotModule; /** * The snapshotManager generates static raster images of the map. diff --git a/javascript/utils/Logger.ts b/javascript/utils/Logger.ts index 4772ac31f..1d6c23b1e 100644 --- a/javascript/utils/Logger.ts +++ b/javascript/utils/Logger.ts @@ -3,7 +3,7 @@ import { NativeEventEmitter, NativeModules, } from 'react-native'; -const {MGLLogging} = NativeModules; +const {MLNLogging} = NativeModules; export type LogLevel = 'error' | 'warning' | 'info' | 'debug' | 'verbose'; interface Log { @@ -30,7 +30,7 @@ class Logger { private subscription: EmitterSubscription | null; constructor() { - this.loggerEmitter = new NativeEventEmitter(MGLLogging); + this.loggerEmitter = new NativeEventEmitter(MLNLogging); this.startedCount = 0; this.logCallback = null; this.subscription = null; @@ -68,7 +68,7 @@ class Logger { * @param {LogLevel} level */ static setLogLevel(level: LogLevel): void { - MGLLogging.setLogLevel(level); + MLNLogging.setLogLevel(level); } /** diff --git a/javascript/utils/animated/AnimatedShape.ts b/javascript/utils/animated/AnimatedShape.ts index 50d36d149..f48503a57 100644 --- a/javascript/utils/animated/AnimatedShape.ts +++ b/javascript/utils/animated/AnimatedShape.ts @@ -1,5 +1,5 @@ /* eslint-disable @typescript-eslint/explicit-module-boundary-types */ -/* eslint-disable @typescript-eslint/no-explicit-any */ + import AnimatedCoordinatesArray from './AnimatedCoordinatesArray'; import AnimatedExtractCoordinateFromArray from './AnimatedExtractCoordinateFromArray'; import AnimatedRouteCoordinatesArray from './AnimatedRouteCoordinatesArray'; diff --git a/maplibre-react-native.podspec b/maplibre-react-native.podspec index 751f540f6..78af7a360 100644 --- a/maplibre-react-native.podspec +++ b/maplibre-react-native.podspec @@ -28,9 +28,9 @@ def $RNMBGL.post_install(installer) url: "https://github.com/maplibre/maplibre-gl-native-distribution", requirement: { kind: "exactVersion", - version: "5.13.0" + version: "6.4.0" }, - product_name: "Mapbox" + product_name: "MapLibre" } if $RNMBGL_SPM_Spec.is_a?(Hash) @@ -74,6 +74,6 @@ Pod::Spec.new do |s| s.dependency 'React' s.subspec 'DynamicLibrary' do |sp| - sp.source_files = "ios/RCTMGL/**/*.{h,m}" + sp.source_files = "ios/RCTMLN/**/*.{h,m}" end end diff --git a/package.json b/package.json index 145b6473b..c45d054da 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@maplibre/maplibre-react-native", "description": "A MapLibre GL Native plugin for creating maps in React Native", - "version": "10.0.0-alpha.3", + "version": "10.0.0-alpha.4", "publishConfig": { "access": "public" }, @@ -32,7 +32,6 @@ "test:plugin": "jest plugin", "build:plugin": "tsc --build plugin", "lint:plugin": "eslint plugin/src/*", - "postinstall": "husky install", "postpack": "pinst --enable" }, "peerDependenciesMeta": { diff --git a/react-native.config.js b/react-native.config.js index 47c4b4879..6e8c8ee4e 100644 --- a/react-native.config.js +++ b/react-native.config.js @@ -3,7 +3,7 @@ module.exports = { platforms: { ios: {}, android: { - sourceDir: './android/rctmgl', + sourceDir: './android/rctmln', }, }, }, diff --git a/scripts/autogenHelpers/globals.js b/scripts/autogenHelpers/globals.js index cd1638c20..5c161dee5 100644 --- a/scripts/autogenHelpers/globals.js +++ b/scripts/autogenHelpers/globals.js @@ -84,25 +84,25 @@ global.getLayerType = function (layer, platform) { switch (layer.name) { case 'fill': - return isIOS ? 'MGLFillStyleLayer' : 'FillLayer'; + return isIOS ? 'MLNFillStyleLayer' : 'FillLayer'; case 'fill-extrusion': - return isIOS ? 'MGLFillExtrusionStyleLayer' : 'FillExtrusionLayer'; + return isIOS ? 'MLNFillExtrusionStyleLayer' : 'FillExtrusionLayer'; case 'line': - return isIOS ? 'MGLLineStyleLayer' : 'LineLayer'; + return isIOS ? 'MLNLineStyleLayer' : 'LineLayer'; case 'symbol': - return isIOS ? 'MGLSymbolStyleLayer' : 'SymbolLayer'; + return isIOS ? 'MLNSymbolStyleLayer' : 'SymbolLayer'; case 'circle': - return isIOS ? 'MGLCircleStyleLayer' : 'CircleLayer'; + return isIOS ? 'MLNCircleStyleLayer' : 'CircleLayer'; case 'background': - return isIOS ? 'MGLBackgroundStyleLayer' : 'BackgroundLayer'; + return isIOS ? 'MLNBackgroundStyleLayer' : 'BackgroundLayer'; case 'raster': - return isIOS ? 'MGLRasterStyleLayer' : 'RasterLayer'; + return isIOS ? 'MLNRasterStyleLayer' : 'RasterLayer'; case 'heatmap': - return isIOS ? 'MGLHeatmapStyleLayer' : 'HeatmapLayer'; + return isIOS ? 'MLNHeatmapStyleLayer' : 'HeatmapLayer'; case 'hillshade': - return isIOS ? 'MGLHillshadeStyleLayer' : 'HillshadeLayer'; + return isIOS ? 'MLNHillshadeStyleLayer' : 'HillshadeLayer'; case 'light': - return isIOS ? 'MGLLight' : 'Light'; + return isIOS ? 'MLNLight' : 'Light'; default: throw new Error( `Is ${layer.name} a new layer? We should add support for it!`, diff --git a/scripts/autogenerate.js b/scripts/autogenerate.js index 3d3ea7b41..573309a31 100644 --- a/scripts/autogenerate.js +++ b/scripts/autogenerate.js @@ -32,7 +32,7 @@ function readAndroidVersion() { __dirname, '..', 'android', - 'rctmgl', + 'rctmln', 'build.gradle', ); const lines = fs.readFileSync(buildGradlePath, 'utf8').split('\n'); @@ -64,18 +64,18 @@ const OUTPUT_EXAMPLE_PREFIX = [ ]; const OUTPUT_PREFIX = outputToExample ? OUTPUT_EXAMPLE_PREFIX : ['..']; -const IOS_OUTPUT_PATH = path.join(__dirname, ...OUTPUT_PREFIX, 'ios', 'RCTMGL'); +const IOS_OUTPUT_PATH = path.join(__dirname, ...OUTPUT_PREFIX, 'ios', 'RCTMLN'); const ANDROID_OUTPUT_PATH = path.join( __dirname, ...OUTPUT_PREFIX, 'android', - 'rctmgl', + 'rctmln', 'src', 'main', 'java', 'com', - 'mapbox', - 'rctmgl', + 'maplibre', + 'rctmln', 'components', 'styles', ); @@ -322,8 +322,8 @@ function getAllowedFunctionTypes(paintAttr) { async function generate() { const templateMappings = [ { - input: path.join(TMPL_PATH, 'RCTMGLStyle.h.ejs'), - output: path.join(IOS_OUTPUT_PATH, 'RCTMGLStyle.h'), + input: path.join(TMPL_PATH, 'RCTMLNStyle.h.ejs'), + output: path.join(IOS_OUTPUT_PATH, 'RCTMLNStyle.h'), }, /*{ input: path.join(TMPL_PATH, 'index.d.ts.ejs'), @@ -334,12 +334,12 @@ async function generate() { output: path.join(JS_OUTPUT_PATH, 'MaplibreStyles.d.ts'), }, { - input: path.join(TMPL_PATH, 'RCTMGLStyle.m.ejs'), - output: path.join(IOS_OUTPUT_PATH, 'RCTMGLStyle.m'), + input: path.join(TMPL_PATH, 'RCTMLNStyle.m.ejs'), + output: path.join(IOS_OUTPUT_PATH, 'RCTMLNStyle.m'), }, { - input: path.join(TMPL_PATH, 'RCTMGLStyleFactory.java.ejs'), - output: path.join(ANDROID_OUTPUT_PATH, 'RCTMGLStyleFactory.java'), + input: path.join(TMPL_PATH, 'RCTMLNStyleFactory.java.ejs'), + output: path.join(ANDROID_OUTPUT_PATH, 'RCTMLNStyleFactory.java'), }, { input: path.join(TMPL_PATH, 'styleMap.ts.ejs'), diff --git a/scripts/templates/RCTMGLStyle.h.ejs b/scripts/templates/RCTMLNStyle.h.ejs similarity index 74% rename from scripts/templates/RCTMGLStyle.h.ejs rename to scripts/templates/RCTMLNStyle.h.ejs index 3d2d1cfd8..4567b2c9d 100644 --- a/scripts/templates/RCTMGLStyle.h.ejs +++ b/scripts/templates/RCTMLNStyle.h.ejs @@ -4,18 +4,18 @@ // DO NOT MODIFY // THIS FILE IS AUTOGENERATED -#import "RCTMGLStyle.h" -#import "RCTMGLStyleValue.h" +#import "RCTMLNStyle.h" +#import "RCTMLNStyleValue.h" #import -@import Mapbox; +@import MapLibre; -@interface RCTMGLStyle : NSObject +@interface RCTMLNStyle : NSObject @property (nonatomic, weak) RCTBridge *bridge; -@property (nonatomic, strong) MGLStyle *style; +@property (nonatomic, strong) MLNStyle *style; -- (id)initWithMGLStyle:(MGLStyle*)mglStyle; +- (id)initWithMLNStyle:(MLNStyle*)mlnStyle; <%_ for (const layer of layers) { _%> - (void)<%- setLayerMethodName(layer, 'ios') -%>:(<%- getLayerType(layer, 'ios') -%> *)layer withReactStyle:(NSDictionary *)reactStyle isValid:(BOOL (^)(void)) isValid; @@ -23,9 +23,9 @@ <%_ for (const layer of layers) { _%> <%_ for (const prop of layer.properties) { _%> -- (void)set<%- iosPropMethodName(layer, pascelCase(prop.name)) -%>:(<%- getLayerType(layer, 'ios') -%> *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; +- (void)set<%- iosPropMethodName(layer, pascelCase(prop.name)) -%>:(<%- getLayerType(layer, 'ios') -%> *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; <%_ if (prop.transition) { _%> -- (void)set<%- iosPropMethodName(layer, pascelCase(prop.name)) -%>Transition:(<%- getLayerType(layer, 'ios') -%> *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue; +- (void)set<%- iosPropMethodName(layer, pascelCase(prop.name)) -%>Transition:(<%- getLayerType(layer, 'ios') -%> *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue; <%_ } _%> <%_ } _%> <% } %> diff --git a/scripts/templates/RCTMGLStyle.m.ejs b/scripts/templates/RCTMLNStyle.m.ejs similarity index 87% rename from scripts/templates/RCTMGLStyle.m.ejs rename to scripts/templates/RCTMLNStyle.m.ejs index 7a3fcacec..6a4c43717 100644 --- a/scripts/templates/RCTMGLStyle.m.ejs +++ b/scripts/templates/RCTMLNStyle.m.ejs @@ -4,15 +4,15 @@ // DO NOT MODIFY // THIS FILE IS AUTOGENERATED -#import "RCTMGLStyle.h" -#import "RCTMGLUtils.h" +#import "RCTMLNStyle.h" +#import "RCTMLNUtils.h" -@implementation RCTMGLStyle +@implementation RCTMLNStyle -- (id)initWithMGLStyle:(MGLStyle*)mglStyle +- (id)initWithMLNStyle:(MLNStyle*)mlnStyle { if (self = [super init]) { - _style = mglStyle; + _style = mlnStyle; } return self; } @@ -31,7 +31,7 @@ continue; } - RCTMGLStyleValue *styleValue = [RCTMGLStyleValue make:reactStyle[prop]]; + RCTMLNStyleValue *styleValue = [RCTMLNStyleValue make:reactStyle[prop]]; <% for (let i = 0; i < layer.properties.length; i++) { -%> <%- ifOrElseIf(i) -%> ([prop isEqualToString:@"<%= layer.properties[i].name %>"]) { @@ -41,7 +41,7 @@ } else { NSString *imageURI = [styleValue getImageURI]; - [RCTMGLUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { + [RCTMLNUtils fetchImage:_bridge url:imageURI scale:[styleValue getImageScale] callback:^(NSError *error, UIImage *image) { if (image != nil) { dispatch_async(dispatch_get_main_queue(), ^{ if (isValid()) { @@ -69,19 +69,19 @@ <% for (const layer of layers) {%> <% for (const prop of layer.properties) {%> -- (void)set<%- iosPropMethodName(layer, pascelCase(prop.name)) -%>:(<%- getLayerType(layer, 'ios') -%> *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)set<%- iosPropMethodName(layer, pascelCase(prop.name)) -%>:(<%- getLayerType(layer, 'ios') -%> *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { <%_ if (layer.name === 'light' && prop.name === 'position') { _%> layer.position = [styleValue getSphericalPosition]; <%_ } else if (prop.name === 'visibility') { _%> layer.visible = [styleValue isVisible]; <%_ } else { _%> - layer.<%- iosPropName(prop.name) -%> = styleValue.mglStyleValue; + layer.<%- iosPropName(prop.name) -%> = styleValue.mlnStyleValue; <%_ } _%> } <%_ if (prop.transition) { _%> -- (void)set<%- iosPropMethodName(layer, pascelCase(prop.name)) -%>Transition:(<%- getLayerType(layer, 'ios') -%> *)layer withReactStyleValue:(RCTMGLStyleValue *)styleValue +- (void)set<%- iosPropMethodName(layer, pascelCase(prop.name)) -%>Transition:(<%- getLayerType(layer, 'ios') -%> *)layer withReactStyleValue:(RCTMLNStyleValue *)styleValue { layer.<%- iosPropName(prop.name) -%>Transition = [styleValue getTransition]; } diff --git a/scripts/templates/RCTMGLStyleFactory.java.ejs b/scripts/templates/RCTMLNStyleFactory.java.ejs similarity index 87% rename from scripts/templates/RCTMGLStyleFactory.java.ejs rename to scripts/templates/RCTMLNStyleFactory.java.ejs index bc62bb39a..84977407f 100644 --- a/scripts/templates/RCTMGLStyleFactory.java.ejs +++ b/scripts/templates/RCTMLNStyleFactory.java.ejs @@ -4,7 +4,7 @@ // DO NOT MODIFY // THIS FILE IS AUTOGENERATED -package com.mapbox.rctmgl.components.styles; +package com.maplibre.rctmln.components.styles; import com.mapbox.mapboxsdk.style.layers.BackgroundLayer; import com.mapbox.mapboxsdk.style.layers.CircleLayer; @@ -20,16 +20,16 @@ import com.mapbox.mapboxsdk.style.layers.HillshadeLayer; import com.mapbox.mapboxsdk.style.layers.TransitionOptions; import com.mapbox.mapboxsdk.style.light.Light; import com.mapbox.mapboxsdk.style.light.Position; -import com.mapbox.rctmgl.utils.DownloadMapImageTask; +import com.maplibre.rctmln.utils.DownloadMapImageTask; import java.util.List; -public class RCTMGLStyleFactory { +public class RCTMLNStyleFactory { public static final String VALUE_KEY = "value"; public static final String SHOULD_ADD_IMAGE_KEY = "shouldAddImage"; <%_ for (const layer of layers) { _%> - public static void <%- setLayerMethodName(layer) -%>(final <%- getLayerType(layer, 'android') -%> layer, RCTMGLStyle style) { + public static void <%- setLayerMethodName(layer) -%>(final <%- getLayerType(layer, 'android') -%> layer, RCTMLNStyle style) { List styleKeys = style.getAllStyleKeys(); if (styleKeys.size() == 0) { @@ -37,7 +37,7 @@ public class RCTMGLStyleFactory { } for (String styleKey : styleKeys) { - final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey); + final RCTMLNStyleValue styleValue = style.getStyleValueForKey(styleKey); switch (styleKey) { <%_ for (const prop of layer.properties) { _%> @@ -46,16 +46,16 @@ public class RCTMGLStyleFactory { style.addImage(styleValue, new DownloadMapImageTask.OnAllImagesLoaded() { @Override public void onAllImagesLoaded() { - RCTMGLStyleFactory.set<%- pascelCase(prop.name) -%>(layer, styleValue); + RCTMLNStyleFactory.set<%- pascelCase(prop.name) -%>(layer, styleValue); } }); <%_ } else { _%> - RCTMGLStyleFactory.set<%- pascelCase(prop.name) -%>(layer, styleValue); + RCTMLNStyleFactory.set<%- pascelCase(prop.name) -%>(layer, styleValue); <%_ } _%> break; <%_ if (prop.transition) { _%> case "<%= prop.name %>Transition": - RCTMGLStyleFactory.set<%- pascelCase(prop.name) -%>Transition(layer, styleValue); + RCTMLNStyleFactory.set<%- pascelCase(prop.name) -%>Transition(layer, styleValue); break; <%_ } _%> <%_ } _%> @@ -66,7 +66,7 @@ public class RCTMGLStyleFactory { <%_ for (const layer of layers) { _%> <%_ for (const prop of layer.properties) { _%> - public static void set<%- pascelCase(prop.name) -%>(<%- getLayerType(layer, 'android') -%> layer, RCTMGLStyleValue styleValue) { + public static void set<%- pascelCase(prop.name) -%>(<%- getLayerType(layer, 'android') -%> layer, RCTMLNStyleValue styleValue) { <%_ if (layer.name === 'light' && prop.name === 'position') { _%> Float[] values = styleValue.getFloatArray(VALUE_KEY); layer.set<%- pascelCase(prop.name) -%>(Position.fromPosition(values[0], values[1], values[2])); @@ -94,7 +94,7 @@ public class RCTMGLStyleFactory { } <%_ if (prop.transition) { %> - public static void set<%- pascelCase(prop.name) -%>Transition(<%- getLayerType(layer, 'android') -%> layer, RCTMGLStyleValue styleValue) { + public static void set<%- pascelCase(prop.name) -%>Transition(<%- getLayerType(layer, 'android') -%> layer, RCTMLNStyleValue styleValue) { TransitionOptions transition = styleValue.getTransition(); if (transition != null) { layer.set<%- pascelCase(prop.name) -%>Transition(transition); diff --git a/setup-jest.js b/setup-jest.js index 497f7f3d5..e785dbf70 100644 --- a/setup-jest.js +++ b/setup-jest.js @@ -7,7 +7,7 @@ function keyMirror(keys) { } // Mock of what the native code puts on the JS object -NativeModules.MGLModule = { +NativeModules.MLNModule = { // constants UserTrackingModes: keyMirror([ 'None', @@ -76,7 +76,7 @@ NativeModules.MGLModule = { setConnected: jest.fn(), }; -NativeModules.MGLOfflineModule = { +NativeModules.MLNOfflineModule = { createPack: packOptions => { return Promise.resolve({ bounds: packOptions.bounds, @@ -93,13 +93,13 @@ NativeModules.MGLOfflineModule = { setProgressEventThrottle: jest.fn(), }; -NativeModules.MGLSnapshotModule = { +NativeModules.MLNSnapshotModule = { takeSnap: () => { return Promise.resolve('file://test.png'); }, }; -NativeModules.MGLLocationModule = { +NativeModules.MLNLocationModule = { getLastKnownLocation: jest.fn(), setMinDisplacement: jest.fn(), start: jest.fn(),