-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathplugin.xml
executable file
·105 lines (89 loc) · 4.87 KB
/
plugin.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
<?xml version="1.0" encoding="UTF-8"?>
<plugin xmlns="http://apache.org/cordova/ns/plugins/1.0"
xmlns:android="http://schemas.android.com/apk/res/android"
id="com.roadshr.cordova.amap"
version="0.0.1">
<name>Amap Plugin</name>
<description>Cordova plugin for Amap</description>
<author>roadshr</author>
<keywords>Amap,Geolocation,Roadshr</keywords>
<license>Apache 2.0 License</license>
<!--<preference name="API_KEY" />-->
<engines>
<engine name="cordova" version=">=3.0"/>
</engines>
<js-module src="www/AMapPlugin.js" name="AMapPlugin">
<clobbers target="AMapPlugin"/>
</js-module>
<platform name="ios">
<config-file target="*-Info.plist" parent="NSLocationAlwaysUsageDescription">
<string>This app requires background location tracking</string>
</config-file>
<config-file target="*-Info.plist" parent="UIBackgroundModes">
<array>
<string>location</string>
</array>
</config-file>
<config-file target="*-Info.plist" parent="NSAppTransportSecurity">
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
</config-file>
<config-file target="*-Info.plist" parent="LSApplicationQueriesSchemes">
<array>
<string>iosamap</string>
</array>
</config-file>
<config-file target="config.xml" parent="/*">
<feature name="AMapPlugin">
<param name="ios-package" value="AMapPlugin"/>
</feature>
</config-file>
<header-file src="src/ios/AMapPlugin.h"/>
<source-file src="src/ios/AMapPlugin.m"/>
<framework src="libs/ios/AMapLocationKit.framework" custom="true" />
<framework src="libs/ios/AMapSearchKit.framework" custom="true" />
<!--<resource-file src="src/ios/AmapConfig.plist" />-->
<framework src="CoreTelephony.framework" weak="true" />
<framework src="SystemConfiguration.framework" weak="true" />
<framework src="CoreLocation.framework" weak="true" />
<framework src="libz.tbd" weak="true" />
</platform>
<!-- android -->
<platform name="android">
<hook type="after_plugin_add" src="scripts/android-install.js" />
<hook type="after_plugin_install" src="scripts/android-install.js" />
<hook type="before_plugin_rm" src="scripts/android-install.js" />
<hook type="before_plugin_uninstall" src="scripts/android-install.js" />
<config-file target="res/xml/config.xml" parent="/*">
<feature name="AMapPlugin">
<param name="android-package" value="com.roadshr.cordova.amap.AMapPlugin"/>
</feature>
</config-file>
<config-file target="AndroidManifest.xml" parent="/manifest">
<!-- Required 一些系统要求的权限,如访问网络等-->
<!--用于进行网络定位-->
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"></uses-permission>
<!--用于访问GPS定位-->
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"></uses-permission>
<!--获取运营商信息,用于支持提供运营商信息相关的接口-->
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"></uses-permission>
<!--用于访问wifi网络信息,wifi信息会用于进行网络定位-->
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"></uses-permission>
<!--这个权限用于获取wifi的获取权限,wifi信息会用来进行网络定位-->
<uses-permission android:name="android.permission.CHANGE_WIFI_STATE"></uses-permission>
<!--用于访问网络,网络定位需要上网-->
<uses-permission android:name="android.permission.INTERNET"></uses-permission>
<!--用于读取手机当前的状态-->
<uses-permission android:name="android.permission.READ_PHONE_STATE"></uses-permission>
<!--写入扩展存储,向扩展卡写入数据,用于写入缓存定位数据-->
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"></uses-permission>
</config-file>
<config-file target="AndroidManifest.xml" parent="/manifest/application">
<service android:name="com.amap.api.location.APSService"></service>
</config-file>
<framework src="com.android.support:support-v4:+" />
<source-file src="libs/android/AMap_Location_v2.3.0_20160112.jar" target-dir="libs"/>
</platform>
</plugin>