Skip to content

Commit

Permalink
Merge pull request #46 from IndoorAtlas/3.3.1
Browse files Browse the repository at this point in the history
3.3.1
  • Loading branch information
Cloudef authored Sep 3, 2020
2 parents 5f37052 + 56679c5 commit 847fb0a
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 9 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cordova-plugin-indooratlas",
"version": "3.3.0",
"version": "3.3.1",
"description": "Cordova plugin using IndoorAtlas SDK.",
"cordova": {
"id": "cordova-plugin-indooratlas",
Expand Down
2 changes: 1 addition & 1 deletion src/android/indooratlas.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ repositories {

dependencies {
implementation 'com.android.support:appcompat-v7:27.0.2'
implementation 'com.indooratlas.android:indooratlas-android-sdk:3.3.3'
implementation 'com.indooratlas.android:indooratlas-android-sdk:3.3.5'
}
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,10 @@ INDOORATLAS_API
* Is this geofence cloud defined (static) or runtime defined (dynamic)
*/
@property (nonatomic, readonly) BOOL isCloudGeofence;
/**
* Unique [lat, lon] points of the geofence, if any.
*/
@property (nonatomic, readonly, strong) NSArray<NSNumber*> * _Nonnull points;

/**
* Does the geofence contain the coordinate?
Expand All @@ -190,10 +194,6 @@ INDOORATLAS_API
*/
INDOORATLAS_API
@interface IAPolygonGeofence : IAGeofence
/**
* The unique points of the polygon.
*/
@property (nonatomic, readonly, strong) NSArray<NSNumber*> * _Nonnull points;
/**
* Creates a new polygonal region from unique edges.
* @param identifier Identifier for the geofence.
Expand Down
Binary file modified src/ios/IndoorAtlas/IndoorAtlas.framework/IndoorAtlas
Binary file not shown.
Binary file modified src/ios/IndoorAtlas/IndoorAtlas.framework/Info.plist
Binary file not shown.
5 changes: 2 additions & 3 deletions src/ios/IndoorLocation.m
Original file line number Diff line number Diff line change
Expand Up @@ -628,7 +628,7 @@ - (IAPolygonGeofence *)geofenceFromDictionary:(NSDictionary *)geofence {
return iaGeofence;
}

- (NSDictionary *)dictionaryFromGeofence:(IAPolygonGeofence *)iaGeofence
- (NSDictionary *)dictionaryFromGeofence:(IAGeofence *)iaGeofence
{
NSMutableDictionary *geoJson = [NSMutableDictionary dictionaryWithCapacity:4];
[geoJson setObject:@"Feature" forKey:@"type"];
Expand Down Expand Up @@ -823,8 +823,7 @@ - (void)location:(IndoorAtlasLocationService *)manager didRegionChange:(IARegion
if (region == nil) {
return;
}
// Is the `isKindOfClass` check required? Are all geofences IAPolygonGeofences?
if (region.type == kIARegionTypeGeofence && [region isKindOfClass:[IAPolygonGeofence class]]) {
if (region.type == kIARegionTypeGeofence) {
NSMutableDictionary *geofenceDict = [self dictionaryFromGeofence:region];
NSMutableDictionary *result = [NSMutableDictionary dictionaryWithCapacity:2];
[result setObject:geofenceDict forKey:@"geoJson"];
Expand Down

0 comments on commit 847fb0a

Please sign in to comment.