react-native-google-maps-plus 1.4.0 → 1.4.1-dev.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/src/main/java/com/rngooglemapsplus/GoogleMapsViewImpl.kt +41 -144
- package/android/src/main/java/com/rngooglemapsplus/LocationHandler.kt +38 -36
- package/android/src/main/java/com/rngooglemapsplus/MapCircleBuilder.kt +31 -8
- package/android/src/main/java/com/rngooglemapsplus/MapMarkerBuilder.kt +69 -18
- package/android/src/main/java/com/rngooglemapsplus/MapPolygonBuilder.kt +53 -14
- package/android/src/main/java/com/rngooglemapsplus/MapPolylineBuilder.kt.kt +44 -11
- package/android/src/main/java/com/rngooglemapsplus/RNGoogleMapsPlusView.kt +4 -4
- package/android/src/main/java/com/rngooglemapsplus/extensions/CameraPositionExtension.kt +12 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/IntExtension.kt +28 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/LatLngBounds.kt +15 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/LocationExtension.kt +59 -0
- package/ios/GoogleMapViewImpl.swift +28 -138
- package/ios/LocationHandler.swift +5 -13
- package/ios/MapCircleBuilder.swift +29 -9
- package/ios/MapHelper.swift +20 -0
- package/ios/MapMarkerBuilder.swift +101 -84
- package/ios/MapPolygonBuilder.swift +50 -16
- package/ios/MapPolylineBuilder.swift +31 -15
- package/ios/RNGoogleMapsPlusView.swift +15 -11
- package/ios/extensions/CLError+Extension.swift +14 -0
- package/ios/extensions/CLLocation+Extension.swift +27 -0
- package/ios/extensions/GMSCameraPosition+Extension.swift +12 -0
- package/ios/extensions/GMSCoordinateBounds+Extension.swift +19 -0
- package/ios/extensions/RNMarker+Extension.swift +2 -3
- package/lib/module/GoogleMapsPlus.js +7 -0
- package/lib/module/GoogleMapsPlus.js.map +1 -0
- package/lib/module/index.js +3 -5
- package/lib/module/index.js.map +1 -1
- package/lib/module/types.js.map +1 -1
- package/lib/nitrogen/generated/shared/json/RNGoogleMapsPlusViewConfig.json +44 -0
- package/lib/typescript/src/GoogleMapsPlus.d.ts +5 -0
- package/lib/typescript/src/GoogleMapsPlus.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +3 -3
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/types.d.ts +25 -0
- package/lib/typescript/src/types.d.ts.map +1 -1
- package/nitrogen/generated/android/c++/JFunc_void_RNLocation.hpp +6 -0
- package/nitrogen/generated/android/c++/JHybridRNGoogleMapsPlusViewSpec.cpp +8 -0
- package/nitrogen/generated/android/c++/JRNLocation.hpp +32 -2
- package/nitrogen/generated/android/c++/JRNLocationAndroid.hpp +82 -0
- package/nitrogen/generated/android/c++/JRNLocationIOS.hpp +77 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNLocation.kt +19 -1
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNLocationAndroid.kt +50 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNLocationIOS.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/views/HybridRNGoogleMapsPlusViewManager.kt +7 -2
- package/nitrogen/generated/ios/RNGoogleMapsPlus-Swift-Cxx-Bridge.hpp +36 -0
- package/nitrogen/generated/ios/RNGoogleMapsPlus-Swift-Cxx-Umbrella.hpp +6 -0
- package/nitrogen/generated/ios/c++/HybridRNGoogleMapsPlusViewSpecSwift.hpp +6 -0
- package/nitrogen/generated/ios/c++/views/HybridRNGoogleMapsPlusViewComponent.mm +8 -0
- package/nitrogen/generated/ios/swift/RNLocation.swift +92 -2
- package/nitrogen/generated/ios/swift/RNLocationAndroid.swift +215 -0
- package/nitrogen/generated/ios/swift/RNLocationIOS.swift +185 -0
- package/nitrogen/generated/shared/c++/RNLocation.hpp +33 -2
- package/nitrogen/generated/shared/c++/RNLocationAndroid.hpp +104 -0
- package/nitrogen/generated/shared/c++/RNLocationIOS.hpp +99 -0
- package/package.json +6 -13
- package/src/GoogleMapsPlus.tsx +20 -0
- package/src/index.tsx +6 -14
- package/src/types.ts +27 -0
- package/lib/module/package.json +0 -1
- package/lib/typescript/package.json +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,8BAA8B,CAAC;AAChF,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAE7D,MAAM,MAAM,iBAAiB,GAAG,UAAU,CAAC,2BAA2B,CAAC,CAAC;AAExE,MAAM,MAAM,cAAc,GAAG;IAC3B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,QAAQ,CAAC;CACnB,CAAC;AAEF,MAAM,MAAM,eAAe,GAAG;IAC5B,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,wBAAwB,CAAC,EAAE,OAAO,CAAC;IACnC,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,uBAAuB,CAAC,EAAE,OAAO,CAAC;IAClC,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,+BAA+B,CAAC,EAAE,OAAO,CAAC;IAC1C,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,mBAAmB,CAAC,EAAE,OAAO,CAAC;CAC/B,CAAC;AAEF,MAAM,MAAM,QAAQ,GAAG;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG;IAC3B,SAAS,EAAE,QAAQ,CAAC;IACpB,SAAS,EAAE,Q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F,MAAM,MAAM,aAAa,GAAG;IAC1B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,oBAAY,mBAAmB;IAC7B,iBAAiB,IAAI;IACrB,oBAAoB,IAAI;IACxB,OAAO,IAAI;IACX,0BAA0B,IAAI;IAC9B,sBAAsB,IAAI;IAC1B,cAAc,KAAK;CACpB;AAED,oBAAY,cAAc;IACxB,qBAAqB,IAAI;IACzB,qBAAqB,IAAI;IACzB,sBAAsB,IAAI;IAC1B,sBAAsB,IAAI;IAC1B,6BAA6B,IAAI;IACjC,qBAAqB,IAAI;IACzB,OAAO,IAAI;CACZ"}
|
|
@@ -15,6 +15,12 @@
|
|
|
15
15
|
#include "JRNLocation.hpp"
|
|
16
16
|
#include "RNLatLng.hpp"
|
|
17
17
|
#include "JRNLatLng.hpp"
|
|
18
|
+
#include "RNLocationAndroid.hpp"
|
|
19
|
+
#include <optional>
|
|
20
|
+
#include "JRNLocationAndroid.hpp"
|
|
21
|
+
#include <string>
|
|
22
|
+
#include "RNLocationIOS.hpp"
|
|
23
|
+
#include "JRNLocationIOS.hpp"
|
|
18
24
|
|
|
19
25
|
namespace margelo::nitro::rngooglemapsplus {
|
|
20
26
|
|
|
@@ -63,6 +63,10 @@ namespace margelo::nitro::rngooglemapsplus { enum class RNIOSLocationAccuracy; }
|
|
|
63
63
|
namespace margelo::nitro::rngooglemapsplus { enum class RNMapErrorCode; }
|
|
64
64
|
// Forward declaration of `RNLocation` to properly resolve imports.
|
|
65
65
|
namespace margelo::nitro::rngooglemapsplus { struct RNLocation; }
|
|
66
|
+
// Forward declaration of `RNLocationAndroid` to properly resolve imports.
|
|
67
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationAndroid; }
|
|
68
|
+
// Forward declaration of `RNLocationIOS` to properly resolve imports.
|
|
69
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationIOS; }
|
|
66
70
|
// Forward declaration of `RNLocationErrorCode` to properly resolve imports.
|
|
67
71
|
namespace margelo::nitro::rngooglemapsplus { enum class RNLocationErrorCode; }
|
|
68
72
|
// Forward declaration of `RNIndoorBuilding` to properly resolve imports.
|
|
@@ -151,6 +155,10 @@ namespace margelo::nitro::rngooglemapsplus { enum class RNSnapshotResultType; }
|
|
|
151
155
|
#include "RNLocation.hpp"
|
|
152
156
|
#include "JFunc_void_RNLocation.hpp"
|
|
153
157
|
#include "JRNLocation.hpp"
|
|
158
|
+
#include "RNLocationAndroid.hpp"
|
|
159
|
+
#include "JRNLocationAndroid.hpp"
|
|
160
|
+
#include "RNLocationIOS.hpp"
|
|
161
|
+
#include "JRNLocationIOS.hpp"
|
|
154
162
|
#include "RNLocationErrorCode.hpp"
|
|
155
163
|
#include "JFunc_void_RNLocationErrorCode.hpp"
|
|
156
164
|
#include "JRNLocationErrorCode.hpp"
|
|
@@ -11,7 +11,13 @@
|
|
|
11
11
|
#include "RNLocation.hpp"
|
|
12
12
|
|
|
13
13
|
#include "JRNLatLng.hpp"
|
|
14
|
+
#include "JRNLocationAndroid.hpp"
|
|
15
|
+
#include "JRNLocationIOS.hpp"
|
|
14
16
|
#include "RNLatLng.hpp"
|
|
17
|
+
#include "RNLocationAndroid.hpp"
|
|
18
|
+
#include "RNLocationIOS.hpp"
|
|
19
|
+
#include <optional>
|
|
20
|
+
#include <string>
|
|
15
21
|
|
|
16
22
|
namespace margelo::nitro::rngooglemapsplus {
|
|
17
23
|
|
|
@@ -34,11 +40,29 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
34
40
|
static const auto clazz = javaClassStatic();
|
|
35
41
|
static const auto fieldCenter = clazz->getField<JRNLatLng>("center");
|
|
36
42
|
jni::local_ref<JRNLatLng> center = this->getFieldValue(fieldCenter);
|
|
43
|
+
static const auto fieldAltitude = clazz->getField<double>("altitude");
|
|
44
|
+
double altitude = this->getFieldValue(fieldAltitude);
|
|
45
|
+
static const auto fieldAccuracy = clazz->getField<double>("accuracy");
|
|
46
|
+
double accuracy = this->getFieldValue(fieldAccuracy);
|
|
37
47
|
static const auto fieldBearing = clazz->getField<double>("bearing");
|
|
38
48
|
double bearing = this->getFieldValue(fieldBearing);
|
|
49
|
+
static const auto fieldSpeed = clazz->getField<double>("speed");
|
|
50
|
+
double speed = this->getFieldValue(fieldSpeed);
|
|
51
|
+
static const auto fieldTime = clazz->getField<double>("time");
|
|
52
|
+
double time = this->getFieldValue(fieldTime);
|
|
53
|
+
static const auto fieldAndroid = clazz->getField<JRNLocationAndroid>("android");
|
|
54
|
+
jni::local_ref<JRNLocationAndroid> android = this->getFieldValue(fieldAndroid);
|
|
55
|
+
static const auto fieldIos = clazz->getField<JRNLocationIOS>("ios");
|
|
56
|
+
jni::local_ref<JRNLocationIOS> ios = this->getFieldValue(fieldIos);
|
|
39
57
|
return RNLocation(
|
|
40
58
|
center->toCpp(),
|
|
41
|
-
|
|
59
|
+
altitude,
|
|
60
|
+
accuracy,
|
|
61
|
+
bearing,
|
|
62
|
+
speed,
|
|
63
|
+
time,
|
|
64
|
+
android != nullptr ? std::make_optional(android->toCpp()) : std::nullopt,
|
|
65
|
+
ios != nullptr ? std::make_optional(ios->toCpp()) : std::nullopt
|
|
42
66
|
);
|
|
43
67
|
}
|
|
44
68
|
|
|
@@ -50,7 +74,13 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
50
74
|
static jni::local_ref<JRNLocation::javaobject> fromCpp(const RNLocation& value) {
|
|
51
75
|
return newInstance(
|
|
52
76
|
JRNLatLng::fromCpp(value.center),
|
|
53
|
-
value.
|
|
77
|
+
value.altitude,
|
|
78
|
+
value.accuracy,
|
|
79
|
+
value.bearing,
|
|
80
|
+
value.speed,
|
|
81
|
+
value.time,
|
|
82
|
+
value.android.has_value() ? JRNLocationAndroid::fromCpp(value.android.value()) : nullptr,
|
|
83
|
+
value.ios.has_value() ? JRNLocationIOS::fromCpp(value.ios.value()) : nullptr
|
|
54
84
|
);
|
|
55
85
|
}
|
|
56
86
|
};
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// JRNLocationAndroid.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2025 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#include <fbjni/fbjni.h>
|
|
11
|
+
#include "RNLocationAndroid.hpp"
|
|
12
|
+
|
|
13
|
+
#include <optional>
|
|
14
|
+
#include <string>
|
|
15
|
+
|
|
16
|
+
namespace margelo::nitro::rngooglemapsplus {
|
|
17
|
+
|
|
18
|
+
using namespace facebook;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* The C++ JNI bridge between the C++ struct "RNLocationAndroid" and the the Kotlin data class "RNLocationAndroid".
|
|
22
|
+
*/
|
|
23
|
+
struct JRNLocationAndroid final: public jni::JavaClass<JRNLocationAndroid> {
|
|
24
|
+
public:
|
|
25
|
+
static auto constexpr kJavaDescriptor = "Lcom/rngooglemapsplus/RNLocationAndroid;";
|
|
26
|
+
|
|
27
|
+
public:
|
|
28
|
+
/**
|
|
29
|
+
* Convert this Java/Kotlin-based struct to the C++ struct RNLocationAndroid by copying all values to C++.
|
|
30
|
+
*/
|
|
31
|
+
[[maybe_unused]]
|
|
32
|
+
[[nodiscard]]
|
|
33
|
+
RNLocationAndroid toCpp() const {
|
|
34
|
+
static const auto clazz = javaClassStatic();
|
|
35
|
+
static const auto fieldProvider = clazz->getField<jni::JString>("provider");
|
|
36
|
+
jni::local_ref<jni::JString> provider = this->getFieldValue(fieldProvider);
|
|
37
|
+
static const auto fieldElapsedRealtimeNanos = clazz->getField<jni::JDouble>("elapsedRealtimeNanos");
|
|
38
|
+
jni::local_ref<jni::JDouble> elapsedRealtimeNanos = this->getFieldValue(fieldElapsedRealtimeNanos);
|
|
39
|
+
static const auto fieldBearingAccuracyDegrees = clazz->getField<jni::JDouble>("bearingAccuracyDegrees");
|
|
40
|
+
jni::local_ref<jni::JDouble> bearingAccuracyDegrees = this->getFieldValue(fieldBearingAccuracyDegrees);
|
|
41
|
+
static const auto fieldSpeedAccuracyMetersPerSecond = clazz->getField<jni::JDouble>("speedAccuracyMetersPerSecond");
|
|
42
|
+
jni::local_ref<jni::JDouble> speedAccuracyMetersPerSecond = this->getFieldValue(fieldSpeedAccuracyMetersPerSecond);
|
|
43
|
+
static const auto fieldVerticalAccuracyMeters = clazz->getField<jni::JDouble>("verticalAccuracyMeters");
|
|
44
|
+
jni::local_ref<jni::JDouble> verticalAccuracyMeters = this->getFieldValue(fieldVerticalAccuracyMeters);
|
|
45
|
+
static const auto fieldMslAltitudeMeters = clazz->getField<jni::JDouble>("mslAltitudeMeters");
|
|
46
|
+
jni::local_ref<jni::JDouble> mslAltitudeMeters = this->getFieldValue(fieldMslAltitudeMeters);
|
|
47
|
+
static const auto fieldMslAltitudeAccuracyMeters = clazz->getField<jni::JDouble>("mslAltitudeAccuracyMeters");
|
|
48
|
+
jni::local_ref<jni::JDouble> mslAltitudeAccuracyMeters = this->getFieldValue(fieldMslAltitudeAccuracyMeters);
|
|
49
|
+
static const auto fieldIsMock = clazz->getField<jni::JBoolean>("isMock");
|
|
50
|
+
jni::local_ref<jni::JBoolean> isMock = this->getFieldValue(fieldIsMock);
|
|
51
|
+
return RNLocationAndroid(
|
|
52
|
+
provider != nullptr ? std::make_optional(provider->toStdString()) : std::nullopt,
|
|
53
|
+
elapsedRealtimeNanos != nullptr ? std::make_optional(elapsedRealtimeNanos->value()) : std::nullopt,
|
|
54
|
+
bearingAccuracyDegrees != nullptr ? std::make_optional(bearingAccuracyDegrees->value()) : std::nullopt,
|
|
55
|
+
speedAccuracyMetersPerSecond != nullptr ? std::make_optional(speedAccuracyMetersPerSecond->value()) : std::nullopt,
|
|
56
|
+
verticalAccuracyMeters != nullptr ? std::make_optional(verticalAccuracyMeters->value()) : std::nullopt,
|
|
57
|
+
mslAltitudeMeters != nullptr ? std::make_optional(mslAltitudeMeters->value()) : std::nullopt,
|
|
58
|
+
mslAltitudeAccuracyMeters != nullptr ? std::make_optional(mslAltitudeAccuracyMeters->value()) : std::nullopt,
|
|
59
|
+
isMock != nullptr ? std::make_optional(static_cast<bool>(isMock->value())) : std::nullopt
|
|
60
|
+
);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
public:
|
|
64
|
+
/**
|
|
65
|
+
* Create a Java/Kotlin-based struct by copying all values from the given C++ struct to Java.
|
|
66
|
+
*/
|
|
67
|
+
[[maybe_unused]]
|
|
68
|
+
static jni::local_ref<JRNLocationAndroid::javaobject> fromCpp(const RNLocationAndroid& value) {
|
|
69
|
+
return newInstance(
|
|
70
|
+
value.provider.has_value() ? jni::make_jstring(value.provider.value()) : nullptr,
|
|
71
|
+
value.elapsedRealtimeNanos.has_value() ? jni::JDouble::valueOf(value.elapsedRealtimeNanos.value()) : nullptr,
|
|
72
|
+
value.bearingAccuracyDegrees.has_value() ? jni::JDouble::valueOf(value.bearingAccuracyDegrees.value()) : nullptr,
|
|
73
|
+
value.speedAccuracyMetersPerSecond.has_value() ? jni::JDouble::valueOf(value.speedAccuracyMetersPerSecond.value()) : nullptr,
|
|
74
|
+
value.verticalAccuracyMeters.has_value() ? jni::JDouble::valueOf(value.verticalAccuracyMeters.value()) : nullptr,
|
|
75
|
+
value.mslAltitudeMeters.has_value() ? jni::JDouble::valueOf(value.mslAltitudeMeters.value()) : nullptr,
|
|
76
|
+
value.mslAltitudeAccuracyMeters.has_value() ? jni::JDouble::valueOf(value.mslAltitudeAccuracyMeters.value()) : nullptr,
|
|
77
|
+
value.isMock.has_value() ? jni::JBoolean::valueOf(value.isMock.value()) : nullptr
|
|
78
|
+
);
|
|
79
|
+
}
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
} // namespace margelo::nitro::rngooglemapsplus
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// JRNLocationIOS.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2025 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#include <fbjni/fbjni.h>
|
|
11
|
+
#include "RNLocationIOS.hpp"
|
|
12
|
+
|
|
13
|
+
#include <optional>
|
|
14
|
+
|
|
15
|
+
namespace margelo::nitro::rngooglemapsplus {
|
|
16
|
+
|
|
17
|
+
using namespace facebook;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* The C++ JNI bridge between the C++ struct "RNLocationIOS" and the the Kotlin data class "RNLocationIOS".
|
|
21
|
+
*/
|
|
22
|
+
struct JRNLocationIOS final: public jni::JavaClass<JRNLocationIOS> {
|
|
23
|
+
public:
|
|
24
|
+
static auto constexpr kJavaDescriptor = "Lcom/rngooglemapsplus/RNLocationIOS;";
|
|
25
|
+
|
|
26
|
+
public:
|
|
27
|
+
/**
|
|
28
|
+
* Convert this Java/Kotlin-based struct to the C++ struct RNLocationIOS by copying all values to C++.
|
|
29
|
+
*/
|
|
30
|
+
[[maybe_unused]]
|
|
31
|
+
[[nodiscard]]
|
|
32
|
+
RNLocationIOS toCpp() const {
|
|
33
|
+
static const auto clazz = javaClassStatic();
|
|
34
|
+
static const auto fieldHorizontalAccuracy = clazz->getField<jni::JDouble>("horizontalAccuracy");
|
|
35
|
+
jni::local_ref<jni::JDouble> horizontalAccuracy = this->getFieldValue(fieldHorizontalAccuracy);
|
|
36
|
+
static const auto fieldVerticalAccuracy = clazz->getField<jni::JDouble>("verticalAccuracy");
|
|
37
|
+
jni::local_ref<jni::JDouble> verticalAccuracy = this->getFieldValue(fieldVerticalAccuracy);
|
|
38
|
+
static const auto fieldSpeedAccuracy = clazz->getField<jni::JDouble>("speedAccuracy");
|
|
39
|
+
jni::local_ref<jni::JDouble> speedAccuracy = this->getFieldValue(fieldSpeedAccuracy);
|
|
40
|
+
static const auto fieldCourseAccuracy = clazz->getField<jni::JDouble>("courseAccuracy");
|
|
41
|
+
jni::local_ref<jni::JDouble> courseAccuracy = this->getFieldValue(fieldCourseAccuracy);
|
|
42
|
+
static const auto fieldFloor = clazz->getField<jni::JDouble>("floor");
|
|
43
|
+
jni::local_ref<jni::JDouble> floor = this->getFieldValue(fieldFloor);
|
|
44
|
+
static const auto fieldIsFromMockProvider = clazz->getField<jni::JBoolean>("isFromMockProvider");
|
|
45
|
+
jni::local_ref<jni::JBoolean> isFromMockProvider = this->getFieldValue(fieldIsFromMockProvider);
|
|
46
|
+
static const auto fieldTimestamp = clazz->getField<jni::JDouble>("timestamp");
|
|
47
|
+
jni::local_ref<jni::JDouble> timestamp = this->getFieldValue(fieldTimestamp);
|
|
48
|
+
return RNLocationIOS(
|
|
49
|
+
horizontalAccuracy != nullptr ? std::make_optional(horizontalAccuracy->value()) : std::nullopt,
|
|
50
|
+
verticalAccuracy != nullptr ? std::make_optional(verticalAccuracy->value()) : std::nullopt,
|
|
51
|
+
speedAccuracy != nullptr ? std::make_optional(speedAccuracy->value()) : std::nullopt,
|
|
52
|
+
courseAccuracy != nullptr ? std::make_optional(courseAccuracy->value()) : std::nullopt,
|
|
53
|
+
floor != nullptr ? std::make_optional(floor->value()) : std::nullopt,
|
|
54
|
+
isFromMockProvider != nullptr ? std::make_optional(static_cast<bool>(isFromMockProvider->value())) : std::nullopt,
|
|
55
|
+
timestamp != nullptr ? std::make_optional(timestamp->value()) : std::nullopt
|
|
56
|
+
);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
public:
|
|
60
|
+
/**
|
|
61
|
+
* Create a Java/Kotlin-based struct by copying all values from the given C++ struct to Java.
|
|
62
|
+
*/
|
|
63
|
+
[[maybe_unused]]
|
|
64
|
+
static jni::local_ref<JRNLocationIOS::javaobject> fromCpp(const RNLocationIOS& value) {
|
|
65
|
+
return newInstance(
|
|
66
|
+
value.horizontalAccuracy.has_value() ? jni::JDouble::valueOf(value.horizontalAccuracy.value()) : nullptr,
|
|
67
|
+
value.verticalAccuracy.has_value() ? jni::JDouble::valueOf(value.verticalAccuracy.value()) : nullptr,
|
|
68
|
+
value.speedAccuracy.has_value() ? jni::JDouble::valueOf(value.speedAccuracy.value()) : nullptr,
|
|
69
|
+
value.courseAccuracy.has_value() ? jni::JDouble::valueOf(value.courseAccuracy.value()) : nullptr,
|
|
70
|
+
value.floor.has_value() ? jni::JDouble::valueOf(value.floor.value()) : nullptr,
|
|
71
|
+
value.isFromMockProvider.has_value() ? jni::JBoolean::valueOf(value.isFromMockProvider.value()) : nullptr,
|
|
72
|
+
value.timestamp.has_value() ? jni::JDouble::valueOf(value.timestamp.value()) : nullptr
|
|
73
|
+
);
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
|
|
77
|
+
} // namespace margelo::nitro::rngooglemapsplus
|
|
@@ -26,7 +26,25 @@ data class RNLocation
|
|
|
26
26
|
val center: RNLatLng,
|
|
27
27
|
@DoNotStrip
|
|
28
28
|
@Keep
|
|
29
|
-
val
|
|
29
|
+
val altitude: Double,
|
|
30
|
+
@DoNotStrip
|
|
31
|
+
@Keep
|
|
32
|
+
val accuracy: Double,
|
|
33
|
+
@DoNotStrip
|
|
34
|
+
@Keep
|
|
35
|
+
val bearing: Double,
|
|
36
|
+
@DoNotStrip
|
|
37
|
+
@Keep
|
|
38
|
+
val speed: Double,
|
|
39
|
+
@DoNotStrip
|
|
40
|
+
@Keep
|
|
41
|
+
val time: Double,
|
|
42
|
+
@DoNotStrip
|
|
43
|
+
@Keep
|
|
44
|
+
val android: RNLocationAndroid?,
|
|
45
|
+
@DoNotStrip
|
|
46
|
+
@Keep
|
|
47
|
+
val ios: RNLocationIOS?
|
|
30
48
|
) {
|
|
31
49
|
/* main constructor */
|
|
32
50
|
}
|
package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNLocationAndroid.kt
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// RNLocationAndroid.kt
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2025 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
package com.rngooglemapsplus
|
|
9
|
+
|
|
10
|
+
import androidx.annotation.Keep
|
|
11
|
+
import com.facebook.proguard.annotations.DoNotStrip
|
|
12
|
+
import com.margelo.nitro.core.*
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Represents the JavaScript object/struct "RNLocationAndroid".
|
|
17
|
+
*/
|
|
18
|
+
@DoNotStrip
|
|
19
|
+
@Keep
|
|
20
|
+
data class RNLocationAndroid
|
|
21
|
+
@DoNotStrip
|
|
22
|
+
@Keep
|
|
23
|
+
constructor(
|
|
24
|
+
@DoNotStrip
|
|
25
|
+
@Keep
|
|
26
|
+
val provider: String?,
|
|
27
|
+
@DoNotStrip
|
|
28
|
+
@Keep
|
|
29
|
+
val elapsedRealtimeNanos: Double?,
|
|
30
|
+
@DoNotStrip
|
|
31
|
+
@Keep
|
|
32
|
+
val bearingAccuracyDegrees: Double?,
|
|
33
|
+
@DoNotStrip
|
|
34
|
+
@Keep
|
|
35
|
+
val speedAccuracyMetersPerSecond: Double?,
|
|
36
|
+
@DoNotStrip
|
|
37
|
+
@Keep
|
|
38
|
+
val verticalAccuracyMeters: Double?,
|
|
39
|
+
@DoNotStrip
|
|
40
|
+
@Keep
|
|
41
|
+
val mslAltitudeMeters: Double?,
|
|
42
|
+
@DoNotStrip
|
|
43
|
+
@Keep
|
|
44
|
+
val mslAltitudeAccuracyMeters: Double?,
|
|
45
|
+
@DoNotStrip
|
|
46
|
+
@Keep
|
|
47
|
+
val isMock: Boolean?
|
|
48
|
+
) {
|
|
49
|
+
/* main constructor */
|
|
50
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// RNLocationIOS.kt
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2025 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
package com.rngooglemapsplus
|
|
9
|
+
|
|
10
|
+
import androidx.annotation.Keep
|
|
11
|
+
import com.facebook.proguard.annotations.DoNotStrip
|
|
12
|
+
import com.margelo.nitro.core.*
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Represents the JavaScript object/struct "RNLocationIOS".
|
|
17
|
+
*/
|
|
18
|
+
@DoNotStrip
|
|
19
|
+
@Keep
|
|
20
|
+
data class RNLocationIOS
|
|
21
|
+
@DoNotStrip
|
|
22
|
+
@Keep
|
|
23
|
+
constructor(
|
|
24
|
+
@DoNotStrip
|
|
25
|
+
@Keep
|
|
26
|
+
val horizontalAccuracy: Double?,
|
|
27
|
+
@DoNotStrip
|
|
28
|
+
@Keep
|
|
29
|
+
val verticalAccuracy: Double?,
|
|
30
|
+
@DoNotStrip
|
|
31
|
+
@Keep
|
|
32
|
+
val speedAccuracy: Double?,
|
|
33
|
+
@DoNotStrip
|
|
34
|
+
@Keep
|
|
35
|
+
val courseAccuracy: Double?,
|
|
36
|
+
@DoNotStrip
|
|
37
|
+
@Keep
|
|
38
|
+
val floor: Double?,
|
|
39
|
+
@DoNotStrip
|
|
40
|
+
@Keep
|
|
41
|
+
val isFromMockProvider: Boolean?,
|
|
42
|
+
@DoNotStrip
|
|
43
|
+
@Keep
|
|
44
|
+
val timestamp: Double?
|
|
45
|
+
) {
|
|
46
|
+
/* main constructor */
|
|
47
|
+
}
|
|
@@ -31,18 +31,23 @@ open class HybridRNGoogleMapsPlusViewManager: SimpleViewManager<View>() {
|
|
|
31
31
|
return view
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
+
|
|
34
35
|
override fun onDropViewInstance(view: View) {
|
|
35
36
|
super.onDropViewInstance(view)
|
|
36
37
|
views.remove(view)
|
|
38
|
+
/// added by nitrogen-patch.js
|
|
39
|
+
if (view is GoogleMapsViewImpl) {
|
|
40
|
+
view.destroyInternal()
|
|
41
|
+
}
|
|
37
42
|
}
|
|
38
43
|
|
|
39
|
-
|
|
40
44
|
/// added by nitrogen-patch.js
|
|
41
45
|
override fun prepareToRecycleView(reactContext: ThemedReactContext, view: View): View? {
|
|
42
46
|
return null
|
|
43
47
|
}
|
|
44
48
|
|
|
45
|
-
|
|
49
|
+
|
|
50
|
+
override fun updateState(view: View, props: ReactStylesDiffMap, stateWrapper: StateWrapper): Any? {
|
|
46
51
|
val hybridView = views[view] ?: throw Error("Couldn't find view $view in local views table!")
|
|
47
52
|
|
|
48
53
|
// 1. Update each prop individually
|
|
@@ -50,10 +50,14 @@ namespace margelo::nitro::rngooglemapsplus { struct RNLatLng; }
|
|
|
50
50
|
namespace margelo::nitro::rngooglemapsplus { enum class RNLineCapType; }
|
|
51
51
|
// Forward declaration of `RNLineJoinType` to properly resolve imports.
|
|
52
52
|
namespace margelo::nitro::rngooglemapsplus { enum class RNLineJoinType; }
|
|
53
|
+
// Forward declaration of `RNLocationAndroid` to properly resolve imports.
|
|
54
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationAndroid; }
|
|
53
55
|
// Forward declaration of `RNLocationConfig` to properly resolve imports.
|
|
54
56
|
namespace margelo::nitro::rngooglemapsplus { struct RNLocationConfig; }
|
|
55
57
|
// Forward declaration of `RNLocationErrorCode` to properly resolve imports.
|
|
56
58
|
namespace margelo::nitro::rngooglemapsplus { enum class RNLocationErrorCode; }
|
|
59
|
+
// Forward declaration of `RNLocationIOS` to properly resolve imports.
|
|
60
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationIOS; }
|
|
57
61
|
// Forward declaration of `RNLocationPermissionResult` to properly resolve imports.
|
|
58
62
|
namespace margelo::nitro::rngooglemapsplus { struct RNLocationPermissionResult; }
|
|
59
63
|
// Forward declaration of `RNLocation` to properly resolve imports.
|
|
@@ -116,8 +120,10 @@ namespace RNGoogleMapsPlus { class HybridRNGoogleMapsPlusViewSpec_cxx; }
|
|
|
116
120
|
#include "RNLineCapType.hpp"
|
|
117
121
|
#include "RNLineJoinType.hpp"
|
|
118
122
|
#include "RNLocation.hpp"
|
|
123
|
+
#include "RNLocationAndroid.hpp"
|
|
119
124
|
#include "RNLocationConfig.hpp"
|
|
120
125
|
#include "RNLocationErrorCode.hpp"
|
|
126
|
+
#include "RNLocationIOS.hpp"
|
|
121
127
|
#include "RNLocationPermissionResult.hpp"
|
|
122
128
|
#include "RNMapErrorCode.hpp"
|
|
123
129
|
#include "RNMapPadding.hpp"
|
|
@@ -891,6 +897,36 @@ namespace margelo::nitro::rngooglemapsplus::bridge::swift {
|
|
|
891
897
|
return *optional;
|
|
892
898
|
}
|
|
893
899
|
|
|
900
|
+
// pragma MARK: std::optional<RNLocationAndroid>
|
|
901
|
+
/**
|
|
902
|
+
* Specialized version of `std::optional<RNLocationAndroid>`.
|
|
903
|
+
*/
|
|
904
|
+
using std__optional_RNLocationAndroid_ = std::optional<RNLocationAndroid>;
|
|
905
|
+
inline std::optional<RNLocationAndroid> create_std__optional_RNLocationAndroid_(const RNLocationAndroid& value) noexcept {
|
|
906
|
+
return std::optional<RNLocationAndroid>(value);
|
|
907
|
+
}
|
|
908
|
+
inline bool has_value_std__optional_RNLocationAndroid_(const std::optional<RNLocationAndroid>& optional) noexcept {
|
|
909
|
+
return optional.has_value();
|
|
910
|
+
}
|
|
911
|
+
inline RNLocationAndroid get_std__optional_RNLocationAndroid_(const std::optional<RNLocationAndroid>& optional) noexcept {
|
|
912
|
+
return *optional;
|
|
913
|
+
}
|
|
914
|
+
|
|
915
|
+
// pragma MARK: std::optional<RNLocationIOS>
|
|
916
|
+
/**
|
|
917
|
+
* Specialized version of `std::optional<RNLocationIOS>`.
|
|
918
|
+
*/
|
|
919
|
+
using std__optional_RNLocationIOS_ = std::optional<RNLocationIOS>;
|
|
920
|
+
inline std::optional<RNLocationIOS> create_std__optional_RNLocationIOS_(const RNLocationIOS& value) noexcept {
|
|
921
|
+
return std::optional<RNLocationIOS>(value);
|
|
922
|
+
}
|
|
923
|
+
inline bool has_value_std__optional_RNLocationIOS_(const std::optional<RNLocationIOS>& optional) noexcept {
|
|
924
|
+
return optional.has_value();
|
|
925
|
+
}
|
|
926
|
+
inline RNLocationIOS get_std__optional_RNLocationIOS_(const std::optional<RNLocationIOS>& optional) noexcept {
|
|
927
|
+
return *optional;
|
|
928
|
+
}
|
|
929
|
+
|
|
894
930
|
// pragma MARK: std::function<void(const RNLocation& /* location */)>
|
|
895
931
|
/**
|
|
896
932
|
* Specialized version of `std::function<void(const RNLocation&)>`.
|
|
@@ -50,10 +50,14 @@ namespace margelo::nitro::rngooglemapsplus { struct RNLatLng; }
|
|
|
50
50
|
namespace margelo::nitro::rngooglemapsplus { enum class RNLineCapType; }
|
|
51
51
|
// Forward declaration of `RNLineJoinType` to properly resolve imports.
|
|
52
52
|
namespace margelo::nitro::rngooglemapsplus { enum class RNLineJoinType; }
|
|
53
|
+
// Forward declaration of `RNLocationAndroid` to properly resolve imports.
|
|
54
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationAndroid; }
|
|
53
55
|
// Forward declaration of `RNLocationConfig` to properly resolve imports.
|
|
54
56
|
namespace margelo::nitro::rngooglemapsplus { struct RNLocationConfig; }
|
|
55
57
|
// Forward declaration of `RNLocationErrorCode` to properly resolve imports.
|
|
56
58
|
namespace margelo::nitro::rngooglemapsplus { enum class RNLocationErrorCode; }
|
|
59
|
+
// Forward declaration of `RNLocationIOS` to properly resolve imports.
|
|
60
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationIOS; }
|
|
57
61
|
// Forward declaration of `RNLocationPermissionResult` to properly resolve imports.
|
|
58
62
|
namespace margelo::nitro::rngooglemapsplus { struct RNLocationPermissionResult; }
|
|
59
63
|
// Forward declaration of `RNLocation` to properly resolve imports.
|
|
@@ -116,8 +120,10 @@ namespace margelo::nitro::rngooglemapsplus { enum class RNUserInterfaceStyle; }
|
|
|
116
120
|
#include "RNLineCapType.hpp"
|
|
117
121
|
#include "RNLineJoinType.hpp"
|
|
118
122
|
#include "RNLocation.hpp"
|
|
123
|
+
#include "RNLocationAndroid.hpp"
|
|
119
124
|
#include "RNLocationConfig.hpp"
|
|
120
125
|
#include "RNLocationErrorCode.hpp"
|
|
126
|
+
#include "RNLocationIOS.hpp"
|
|
121
127
|
#include "RNLocationPermissionResult.hpp"
|
|
122
128
|
#include "RNMapErrorCode.hpp"
|
|
123
129
|
#include "RNMapPadding.hpp"
|
|
@@ -68,6 +68,10 @@ namespace margelo::nitro::rngooglemapsplus { enum class RNIOSLocationAccuracy; }
|
|
|
68
68
|
namespace margelo::nitro::rngooglemapsplus { enum class RNMapErrorCode; }
|
|
69
69
|
// Forward declaration of `RNLocation` to properly resolve imports.
|
|
70
70
|
namespace margelo::nitro::rngooglemapsplus { struct RNLocation; }
|
|
71
|
+
// Forward declaration of `RNLocationAndroid` to properly resolve imports.
|
|
72
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationAndroid; }
|
|
73
|
+
// Forward declaration of `RNLocationIOS` to properly resolve imports.
|
|
74
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationIOS; }
|
|
71
75
|
// Forward declaration of `RNLocationErrorCode` to properly resolve imports.
|
|
72
76
|
namespace margelo::nitro::rngooglemapsplus { enum class RNLocationErrorCode; }
|
|
73
77
|
// Forward declaration of `RNIndoorBuilding` to properly resolve imports.
|
|
@@ -125,6 +129,8 @@ namespace margelo::nitro::rngooglemapsplus { enum class RNIOSPermissionResult; }
|
|
|
125
129
|
#include "RNMapErrorCode.hpp"
|
|
126
130
|
#include <functional>
|
|
127
131
|
#include "RNLocation.hpp"
|
|
132
|
+
#include "RNLocationAndroid.hpp"
|
|
133
|
+
#include "RNLocationIOS.hpp"
|
|
128
134
|
#include "RNLocationErrorCode.hpp"
|
|
129
135
|
#include "RNIndoorBuilding.hpp"
|
|
130
136
|
#include "RNIndoorLevel.hpp"
|
|
@@ -55,6 +55,14 @@ using namespace margelo::nitro::rngooglemapsplus::views;
|
|
|
55
55
|
return NO;
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
+
/// added by nitrogen-patch.js
|
|
59
|
+
- (void)dealloc {
|
|
60
|
+
if (_hybridView) {
|
|
61
|
+
RNGoogleMapsPlus::HybridRNGoogleMapsPlusViewSpec_cxx& swiftPart = _hybridView->getSwiftPart();
|
|
62
|
+
swiftPart.dispose();
|
|
63
|
+
_hybridView.reset();
|
|
64
|
+
}
|
|
65
|
+
}
|
|
58
66
|
|
|
59
67
|
- (void) updateView {
|
|
60
68
|
// 1. Get Swift part
|