Commit c7f26015 authored by lmj_521aiau@163.com's avatar lmj_521aiau@163.com

track gmsmap mamap

parent c4c6f713
No preview for this file type
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
ignoresPersistentStateOnLaunch = "NO" ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES" debugDocumentVersioning = "YES"
debugServiceExtension = "internal" debugServiceExtension = "internal"
allowLocationSimulation = "YES"> allowLocationSimulation = "NO">
<BuildableProductRunnable <BuildableProductRunnable
runnableDebuggingMode = "0"> runnableDebuggingMode = "0">
<BuildableReference <BuildableReference
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
</BuildableReference> </BuildableReference>
</BuildableProductRunnable> </BuildableProductRunnable>
<LocationScenarioReference <LocationScenarioReference
identifier = "Hong Kong, China" identifier = "London, England"
referenceType = "1"> referenceType = "1">
</LocationScenarioReference> </LocationScenarioReference>
</LaunchAction> </LaunchAction>
......
...@@ -6,11 +6,11 @@ ...@@ -6,11 +6,11 @@
// Copyright © 2020 Company. All rights reserved. // Copyright © 2020 Company. All rights reserved.
// //
#import <UIKit/UIKit.h> #import "BaseViewController.h"
#import "ZJFriendModel.h" #import "ZJFriendModel.h"
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
@interface ZJFriendTrackMapViewController : UIViewController @interface ZJFriendTrackMapViewController : BaseViewController
@property (nonatomic, strong) ZJFriendModel * model; @property (nonatomic, strong) ZJFriendModel * model;
@property (nonatomic, assign) BOOL autoTrack; @property (nonatomic, assign) BOOL autoTrack;
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_BEGIN
typedef enum : NSUInteger { typedef enum : NSUInteger {
ZJ_GMSMapType, ZJ_GMSMapType = 1,
ZJ_MAMapType ZJ_MAMapType
} ZJMapType; } ZJMapType;
......
...@@ -134,11 +134,13 @@ static ZJLocationManager * manager; ...@@ -134,11 +134,13 @@ static ZJLocationManager * manager;
}else if (error == nil && [placemarks count] == 0) { }else if (error == nil && [placemarks count] == 0) {
NSLog(@"No results were returned."); NSLog(@"No results were returned.");
[self.data WirteDic:@(ZJ_GMSMapType) Key:@"mapType"];
if (self.callBack) { if (self.callBack) {
self.callBack(nil, nil, ZJ_GMSMapType); self.callBack(nil, nil, ZJ_GMSMapType);
} }
} else if (error != nil){ } else if (error != nil){
NSLog(@"An error occurred = %@", error); NSLog(@"An error occurred = %@", error);
[self.data WirteDic:@(ZJ_GMSMapType) Key:@"mapType"];
if (self.callBack) { if (self.callBack) {
self.callBack(nil, nil, ZJ_GMSMapType); self.callBack(nil, nil, ZJ_GMSMapType);
} }
...@@ -169,6 +171,10 @@ static ZJLocationManager * manager; ...@@ -169,6 +171,10 @@ static ZJLocationManager * manager;
isChina = [placemark.ISOcountryCode isEqualToString:@"CN"]; isChina = [placemark.ISOcountryCode isEqualToString:@"CN"];
_mapType = isChina ? ZJ_MAMapType : ZJ_GMSMapType; _mapType = isChina ? ZJ_MAMapType : ZJ_GMSMapType;
[self.data WirteDic:@(_mapType) Key:@"mapType"];
[self.data WirteDic:@(coord.latitude) Key:@"latitude"];
[self.data WirteDic:@(coord.longitude) Key:@"longitude"];
if (_callBack) { if (_callBack) {
_callBack(model, location, _mapType); _callBack(model, location, _mapType);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment