amap_search_fluttify
|
@ -0,0 +1,43 @@
|
|||
# Miscellaneous
|
||||
*.class
|
||||
*.log
|
||||
*.pyc
|
||||
*.swp
|
||||
.DS_Store
|
||||
.atom/
|
||||
.buildlog/
|
||||
.history
|
||||
.svn/
|
||||
migrate_working_dir/
|
||||
|
||||
# IntelliJ related
|
||||
*.iml
|
||||
*.ipr
|
||||
*.iws
|
||||
.idea/
|
||||
|
||||
# The .vscode folder contains launch configuration and tasks you configure in
|
||||
# VS Code which you may wish to be included in version control, so this line
|
||||
# is commented out by default.
|
||||
#.vscode/
|
||||
|
||||
# Flutter/Dart/Pub related
|
||||
**/doc/api/
|
||||
**/ios/Flutter/.last_build_id
|
||||
.dart_tool/
|
||||
.flutter-plugins
|
||||
.flutter-plugins-dependencies
|
||||
.pub-cache/
|
||||
.pub/
|
||||
/build/
|
||||
|
||||
# Symbolication related
|
||||
app.*.symbols
|
||||
|
||||
# Obfuscation related
|
||||
app.*.map.json
|
||||
|
||||
# Android Studio will place build artifacts here
|
||||
/android/app/debug
|
||||
/android/app/profile
|
||||
/android/app/release
|
|
@ -0,0 +1,143 @@
|
|||
## 0.10.3
|
||||
- enhance: 增加adCode
|
||||
|
||||
## 0.10.1
|
||||
- enhance: 缺失的城市信息
|
||||
|
||||
## 0.9.0
|
||||
- fix: 公交路线空判断
|
||||
- enhance: [breaking change] Poi使用同步返回
|
||||
- fix: 地图边界可能存在多个多边形
|
||||
- enhance: 关键字搜索和附近搜索 增加分页参数
|
||||
|
||||
## 0.8.2
|
||||
- enhance: 增加搜索错误处理
|
||||
|
||||
## 0.8.1
|
||||
- roll engine #37387b7e
|
||||
|
||||
## 0.8.0
|
||||
- enhance: 更新底层依赖
|
||||
|
||||
## 0.7.9
|
||||
- roll engine #481e45c1
|
||||
|
||||
## 0.7.8
|
||||
- roll engine #dbad1c35
|
||||
|
||||
## 0.7.7
|
||||
- roll engine #0a5ab5f1
|
||||
- feat: ReGeocode增加roads字段 (#20)
|
||||
|
||||
## 0.7.6
|
||||
- roll engine #b356b08
|
||||
|
||||
## 0.7.5
|
||||
- roll engine #1053dca
|
||||
- feat: 增加搜索云图方法 searchCloudAround
|
||||
|
||||
## 0.7.4
|
||||
- enhance: 提升依赖
|
||||
- roll engine #356f11c
|
||||
|
||||
## 0.7.3
|
||||
- roll engine #107df19
|
||||
- docs: 加入apk下载二维码
|
||||
- enhance: 加入打包的key
|
||||
|
||||
## 0.7.2
|
||||
- roll engine #4d92ce0. 主要解决type_op的冲突.
|
||||
|
||||
## 0.7.1
|
||||
- roll engine #5c1b957
|
||||
|
||||
## 0.7.0
|
||||
- roll engine #ea37ae9
|
||||
|
||||
## 0.6.0
|
||||
- 提升依赖
|
||||
|
||||
## 0.5.0
|
||||
- 提升依赖
|
||||
|
||||
## 0.4.0
|
||||
- enhance: 适配1.12.13
|
||||
- feat: ReGeocode增加poiList
|
||||
- refactor: [breaking change] AoiIten -> Aoi
|
||||
|
||||
## 0.3.4
|
||||
- 解决依赖冲突
|
||||
|
||||
## 0.3.3
|
||||
- 更新依赖
|
||||
|
||||
## 0.3.2
|
||||
- enhance: podfile调整
|
||||
- feat: 获取行政区划数据 新增边界经纬度列表
|
||||
|
||||
## 0.3.1
|
||||
- fix: 路径搜索经纬度取反
|
||||
|
||||
## 0.3.0
|
||||
- 更新底层
|
||||
|
||||
## 0.2.13
|
||||
- enhance: InputTip增加经纬度信息
|
||||
|
||||
## 0.2.12
|
||||
- enhance: poi增加行政区划名称和编号
|
||||
|
||||
## 0.2.11
|
||||
- fix: 处理当构造器参数为null的情况
|
||||
- fix: 加入混淆规则
|
||||
|
||||
## 0.2.10
|
||||
- feat: 逆地理编码增加aoi信息
|
||||
- fix: #4 add新值时,先判断stream是否已经关闭
|
||||
|
||||
## 0.2.8
|
||||
- enhancement: poi增加商圈信息字段
|
||||
|
||||
## 0.2.7
|
||||
- fix: 释放原生对象时, 只释放当前插件创建的对象
|
||||
|
||||
## 0.2.6
|
||||
- enhancement: poi加入地址信息
|
||||
|
||||
## 0.2.5
|
||||
- enhancement: searchAround增加radius参数
|
||||
|
||||
## 0.2.4
|
||||
- enhancement: searchAround增加type参数
|
||||
|
||||
## 0.2.2
|
||||
- Poi加入经纬度信息
|
||||
|
||||
## 0.2.1
|
||||
- bugfix: 释放对象时, 清空对象集合
|
||||
|
||||
## 0.2.0
|
||||
- 加强对多fluttify模块的支持
|
||||
|
||||
## 0.1.1
|
||||
- 原生对象释放
|
||||
|
||||
## 0.1.0
|
||||
- 骑行路径规划
|
||||
|
||||
## 0.0.5
|
||||
- 公交站点搜索
|
||||
- 获取行政区域数据
|
||||
|
||||
## 0.0.4
|
||||
- 驾车出行规划
|
||||
- 步行出行规划
|
||||
- 公交出行规划
|
||||
|
||||
## 0.0.3
|
||||
- 地理编码/逆地理编码
|
||||
|
||||
## 0.0.2
|
||||
- poi关键字搜索
|
||||
- poi附近搜索
|
||||
- 输入提示
|
|
@ -0,0 +1,13 @@
|
|||
Copyright 2019 yohom
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
|
@ -0,0 +1,141 @@
|
|||
# 高德地图 `搜索`组件
|
||||
|
||||
[![pub package](https://img.shields.io/pub/v/amap_search_fluttify.svg)](https://pub.Flutter-io.cn/packages/amap_search_fluttify)
|
||||
![CI](https://github.com/fluttify-project/amap_search_fluttify/workflows/CI/badge.svg)
|
||||
|
||||
高德地图`搜索`组件. Dart接口基于[Fluttify](https://github.com/yohom/fluttify-core-example)引擎生成. [接口文档](https://pub.flutter-io.cn/documentation/amap_search_fluttify/latest/).
|
||||
|
||||
## DEMO 与 社区
|
||||
|
||||
| Demo | QQ群 |
|
||||
|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------:|:--------------------------------------------------------------------------------------------------------------------------------------------:|
|
||||
| 扫描二维码 <br> 或者 <br> [点击下载](https://github.com/fluttify-project/amap_search_fluttify/blob/master/example/build/app/outputs/apk/release/app-release.apk?raw=true) </br> <img src="assets/amap_map_fluttify_apk.png" height="300"> | 加入QQ群讨论 <br/> <img src="https://github.com/fluttify-project/fluttify-core-example/blob/develop/other/QQ%E7%BE%A4.png?raw=true" height="300"> |
|
||||
|
||||
安装:
|
||||
```yaml
|
||||
dependencies:
|
||||
flutter:
|
||||
sdk: flutter
|
||||
amap_search_fluttify: ^x.x.x
|
||||
```
|
||||
|
||||
导入:
|
||||
```dart
|
||||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
```
|
||||
|
||||
使用:
|
||||
```dart
|
||||
/// !注意: 只要是返回Future的方法, 一律使用`await`修饰, 确保当前方法执行完成后再执行下一行, 在不能使用`await`修饰的环境下, 在`then`方法中执行下一步.
|
||||
/// 初始化 iOS在init方法中设置, android需要去AndroidManifest.xml里去设置, 详见https://lbs.amap.com/api/android-sdk/gettingstarted
|
||||
await AmapCore.init('ios key');
|
||||
|
||||
/// !重要: 通过AmapSearchDisposeMixin释放native端的对象, 否则native端会内存泄漏!
|
||||
class _KeywordPoiScreenState extends State<KeywordPoiScreen> with AmapSearchDisposeMixin {}
|
||||
|
||||
/// 搜索关键字poi
|
||||
final poiList = await AmapSearch.instance.searchKeyword(
|
||||
_keywordController.text,
|
||||
city: _cityController.text,
|
||||
);
|
||||
|
||||
/// 搜索周边poi
|
||||
final poiList = await AmapSearch.instance.searchAround(
|
||||
LatLng(
|
||||
double.tryParse(_latController.text) ?? 29.08,
|
||||
double.tryParse(_lngController.text) ?? 119.65,
|
||||
),
|
||||
keyword: _keywordController.text,
|
||||
);
|
||||
|
||||
/// 输入提示
|
||||
final inputTipList = await AmapSearch.instance.fetchInputTips(
|
||||
_keywordController.text,
|
||||
city: _cityController.text,
|
||||
);
|
||||
|
||||
/// 地理编码(地址转坐标)
|
||||
final geocodeList = await AmapSearch.instance.searchGeocode(
|
||||
_keywordController.text,
|
||||
city: _cityController.text,
|
||||
);
|
||||
|
||||
/// 逆地理编码(坐标转地址)
|
||||
final reGeocodeList = await AmapSearch.instance.searchReGeocode(
|
||||
LatLng(
|
||||
double.parse(_latController.text),
|
||||
double.parse(_lngController.text),
|
||||
),
|
||||
radius: 200.0,
|
||||
);
|
||||
|
||||
/// 获取行政区划数据
|
||||
final district = await AmapSearch.instance.searchDistrict(_keywordController.text);
|
||||
|
||||
/// 获取天气数据
|
||||
final district = await AmapSearch.instance.searchDistrict(_keywordController.text);
|
||||
|
||||
/// 公交路径规划(未完成)
|
||||
final routeResult = await AmapSearch.instance.searchBusRoute(
|
||||
from: LatLng(
|
||||
double.parse(_fromLatController.text),
|
||||
double.parse(_fromLngController.text),
|
||||
),
|
||||
to: LatLng(
|
||||
double.parse(_toLatController.text),
|
||||
double.parse(_toLngController.text),
|
||||
),
|
||||
city: '杭州',
|
||||
);
|
||||
|
||||
/// 驾车路径规划
|
||||
final routeResult = await AmapSearch.instance.searchDriveRoute(
|
||||
from: LatLng(
|
||||
double.parse(_fromLatController.text),
|
||||
double.parse(_fromLngController.text),
|
||||
),
|
||||
to: LatLng(
|
||||
double.parse(_toLatController.text),
|
||||
double.parse(_toLngController.text),
|
||||
),
|
||||
);
|
||||
|
||||
/// 骑行路径规划
|
||||
final routeResult = await AmapSearch.instance.searchRideRoute(
|
||||
from: LatLng(
|
||||
double.parse(_fromLatController.text),
|
||||
double.parse(_fromLngController.text),
|
||||
),
|
||||
to: LatLng(
|
||||
double.parse(_toLatController.text),
|
||||
double.parse(_toLngController.text),
|
||||
),
|
||||
);
|
||||
|
||||
/// 步行路径规划
|
||||
final routeResult = await AmapSearch.instance.searchWalkRoute(
|
||||
from: LatLng(
|
||||
double.parse(_fromLatController.text),
|
||||
double.parse(_fromLngController.text),
|
||||
),
|
||||
to: LatLng(
|
||||
double.parse(_toLatController.text),
|
||||
double.parse(_toLngController.text),
|
||||
),
|
||||
);
|
||||
```
|
||||
|
||||
## LICENSE
|
||||
> Copyright 2020 yohom
|
||||
>
|
||||
> Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
>
|
||||
> http://www.apache.org/licenses/LICENSE-2.0
|
||||
>
|
||||
> Unless required by applicable law or agreed to in writing, software
|
||||
> distributed under the License is distributed on an "AS IS" BASIS,
|
||||
> WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
> See the License for the specific language governing permissions and
|
||||
> limitations under the License.
|
|
@ -0,0 +1,9 @@
|
|||
include: package:pedantic/analysis_options.yaml
|
||||
|
||||
linter:
|
||||
rules:
|
||||
camel_case_types: false
|
||||
camel_case_extensions: false
|
||||
omit_local_variable_types: false
|
||||
prefer_single_quotes: false
|
||||
unnecessary_this: false
|
|
@ -0,0 +1,70 @@
|
|||
group 'me.yohom.amap_search_fluttify'
|
||||
version '1.0-SNAPSHOT'
|
||||
|
||||
buildscript {
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
|
||||
}
|
||||
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:7.1.2'
|
||||
}
|
||||
}
|
||||
|
||||
rootProject.allprojects {
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
apply plugin: 'com.android.library'
|
||||
|
||||
android {
|
||||
if (project.android.hasProperty("namespace")) {
|
||||
namespace = "me.yohom.amap_search_fluttify"
|
||||
}
|
||||
compileSdkVersion 31
|
||||
|
||||
sourceSets {
|
||||
main.java.srcDirs += 'src/main/kotlin'
|
||||
main.jniLibs.srcDir 'libs'
|
||||
}
|
||||
defaultConfig {
|
||||
minSdkVersion 16
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
lintOptions {
|
||||
disable 'InvalidPackage'
|
||||
}
|
||||
compileOptions {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
sourceCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
packagingOptions {
|
||||
merge 'res/values/values.xml'
|
||||
merge 'AndroidManifest.xml'
|
||||
merge 'R.txt'
|
||||
merge 'classes.jar'
|
||||
merge 'proguard.txt'
|
||||
}
|
||||
buildTypes {
|
||||
release {
|
||||
consumerProguardFiles "proguard-rules.pro"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation fileTree(dir: 'libs', include: ['*.jar', '*.aar'])
|
||||
implementation 'androidx.annotation:annotation:1.1.0'
|
||||
implementation 'androidx.appcompat:appcompat:1.1.0'
|
||||
compileOnly rootProject.findProject(":foundation_fluttify")
|
||||
// flutter plugin dependency
|
||||
|
||||
// sdk dependency
|
||||
api 'com.amap.api:search:9.2.0'
|
||||
}
|
|
@ -0,0 +1,24 @@
|
|||
# Add project specific ProGuard rules here.
|
||||
# You can control the set of applied configuration files using the
|
||||
# proguardFiles setting in build.gradle.
|
||||
#
|
||||
# For more details, see
|
||||
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||
|
||||
# If your project uses WebView with JS, uncomment the following
|
||||
# and specify the fully qualified class name to the JavaScript interface
|
||||
# class:
|
||||
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||
# public *;
|
||||
#}
|
||||
|
||||
# Uncomment this to preserve the line number information for
|
||||
# debugging stack traces.
|
||||
#-keepattributes SourceFile,LineNumberTable
|
||||
|
||||
# If you keep the line number information, uncomment this to
|
||||
# hide the original source file name.
|
||||
#-renamesourcefileattribute SourceFile
|
||||
|
||||
# 高德地图混淆规则
|
||||
-keep class com.amap.api.services.**{*;}
|
|
@ -0,0 +1 @@
|
|||
rootProject.name = 'amap_search_fluttify'
|
|
@ -0,0 +1,3 @@
|
|||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="me.yohom.amap_search_fluttify">
|
||||
</manifest>
|
|
@ -0,0 +1,180 @@
|
|||
//////////////////////////////////////////////////////////
|
||||
// GENERATED BY FLUTTIFY. DO NOT EDIT IT.
|
||||
//////////////////////////////////////////////////////////
|
||||
|
||||
package me.yohom.amap_search_fluttify;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import android.app.Activity;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import io.flutter.embedding.engine.plugins.FlutterPlugin;
|
||||
import io.flutter.embedding.engine.plugins.activity.ActivityAware;
|
||||
import io.flutter.embedding.engine.plugins.activity.ActivityPluginBinding;
|
||||
import io.flutter.plugin.common.BinaryMessenger;
|
||||
import io.flutter.plugin.common.MethodCall;
|
||||
import io.flutter.plugin.common.MethodChannel;
|
||||
import io.flutter.plugin.common.PluginRegistry.Registrar;
|
||||
import io.flutter.plugin.common.StandardMethodCodec;
|
||||
import io.flutter.plugin.platform.PlatformViewRegistry;
|
||||
|
||||
import me.yohom.amap_search_fluttify.sub_handler.*;
|
||||
import me.yohom.amap_search_fluttify.sub_handler.custom.SubHandlerCustom;
|
||||
import me.yohom.foundation_fluttify.core.FluttifyMessageCodec;
|
||||
|
||||
import static me.yohom.foundation_fluttify.FoundationFluttifyPluginKt.getEnableLog;
|
||||
import static me.yohom.foundation_fluttify.FoundationFluttifyPluginKt.getHEAP;
|
||||
|
||||
@SuppressWarnings("ALL")
|
||||
public class AmapSearchFluttifyPlugin implements FlutterPlugin, MethodChannel.MethodCallHandler, ActivityAware {
|
||||
|
||||
private static List<Map<String, Handler>> handlerMapList;
|
||||
|
||||
// v1 android embedding for compatible
|
||||
public static void registerWith(Registrar registrar) {
|
||||
final MethodChannel channel = new MethodChannel(registrar.messenger(), "me.yohom/amap_search_fluttify", new StandardMethodCodec(new FluttifyMessageCodec()));
|
||||
|
||||
AmapSearchFluttifyPlugin plugin = new AmapSearchFluttifyPlugin();
|
||||
|
||||
BinaryMessenger messenger = registrar.messenger();
|
||||
PlatformViewRegistry platformViewRegistry = registrar.platformViewRegistry();
|
||||
Activity activity = registrar.activity();
|
||||
|
||||
plugin.messenger = messenger;
|
||||
plugin.platformViewRegistry = platformViewRegistry;
|
||||
|
||||
handlerMapList = new ArrayList<>();
|
||||
handlerMapList.add(SubHandler0.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler1.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler2.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler3.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler4.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler5.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler6.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler7.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler8.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler9.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler10.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler11.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler12.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler13.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler14.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler15.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandlerCustom.instance.getSubHandler(messenger, registrar.activity()));
|
||||
|
||||
channel.setMethodCallHandler(plugin);
|
||||
|
||||
// register platform view
|
||||
|
||||
}
|
||||
|
||||
private BinaryMessenger messenger;
|
||||
private PlatformViewRegistry platformViewRegistry;
|
||||
|
||||
// v2 android embedding
|
||||
@Override
|
||||
public void onAttachedToEngine(FlutterPluginBinding binding) {
|
||||
if (getEnableLog()) {
|
||||
Log.d("fluttify-java", "AmapSearchFluttifyPlugin::onAttachedToEngine@" + binding);
|
||||
}
|
||||
|
||||
final MethodChannel channel = new MethodChannel(binding.getBinaryMessenger(), "me.yohom/amap_search_fluttify", new StandardMethodCodec(new FluttifyMessageCodec()));
|
||||
|
||||
messenger = binding.getBinaryMessenger();
|
||||
platformViewRegistry = binding.getPlatformViewRegistry();
|
||||
|
||||
handlerMapList = new ArrayList<>();
|
||||
handlerMapList.add(SubHandler0.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler1.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler2.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler3.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler4.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler5.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler6.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler7.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler8.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler9.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler10.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler11.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler12.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler13.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler14.getSubHandler(messenger));
|
||||
handlerMapList.add(SubHandler15.getSubHandler(messenger));
|
||||
|
||||
channel.setMethodCallHandler(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDetachedFromEngine(FlutterPluginBinding binding) {
|
||||
if (getEnableLog()) {
|
||||
Log.d("fluttify-java", "AmapSearchFluttifyPlugin::onDetachedFromEngine@" + binding);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onAttachedToActivity(ActivityPluginBinding binding) {
|
||||
if (getEnableLog()) {
|
||||
Log.d("fluttify-java", "AmapSearchFluttifyPlugin::onAttachedToActivity@" + binding);
|
||||
}
|
||||
Activity activity = binding.getActivity();
|
||||
|
||||
handlerMapList.add(SubHandlerCustom.instance.getSubHandler(messenger, activity));
|
||||
|
||||
// register platform view
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDetachedFromActivity() {
|
||||
if (getEnableLog()) {
|
||||
Log.d("fluttify-java", "AmapSearchFluttifyPlugin::onDetachedFromActivity");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onReattachedToActivityForConfigChanges(ActivityPluginBinding binding) {
|
||||
if (getEnableLog()) {
|
||||
Log.d("fluttify-java", "AmapSearchFluttifyPlugin::onReattachedToActivityForConfigChanges@" + binding);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDetachedFromActivityForConfigChanges() {
|
||||
if (getEnableLog()) {
|
||||
Log.d("fluttify-java", "AmapSearchFluttifyPlugin::onDetachedFromActivityForConfigChanges");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMethodCall(@NonNull MethodCall methodCall, @NonNull MethodChannel.Result methodResult) {
|
||||
Handler handler = null;
|
||||
for (Map<String, Handler> handlerMap : handlerMapList) {
|
||||
if (handlerMap.containsKey(methodCall.method)) {
|
||||
handler = handlerMap.get(methodCall.method);
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (handler != null) {
|
||||
try {
|
||||
handler.call(methodCall.arguments, methodResult);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
methodResult.error(e.getMessage(), null, null);
|
||||
}
|
||||
} else {
|
||||
methodResult.notImplemented();
|
||||
}
|
||||
}
|
||||
|
||||
@FunctionalInterface
|
||||
public static interface Handler {
|
||||
void call(Object args, MethodChannel.Result methodResult) throws Exception;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,62 @@
|
|||
//////////////////////////////////////////////////////////
|
||||
// GENERATED BY FLUTTIFY. DO NOT EDIT IT.
|
||||
//////////////////////////////////////////////////////////
|
||||
|
||||
package me.yohom.amap_search_fluttify.sub_handler.custom;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import io.flutter.embedding.engine.plugins.FlutterPlugin;
|
||||
import io.flutter.plugin.common.BinaryMessenger;
|
||||
import io.flutter.plugin.common.MethodCall;
|
||||
import io.flutter.plugin.common.MethodChannel;
|
||||
import io.flutter.plugin.common.PluginRegistry.Registrar;
|
||||
import io.flutter.plugin.platform.PlatformViewRegistry;
|
||||
|
||||
import me.yohom.amap_search_fluttify.AmapSearchFluttifyPlugin.Handler;
|
||||
|
||||
import static me.yohom.foundation_fluttify.FoundationFluttifyPluginKt.getEnableLog;
|
||||
import static me.yohom.foundation_fluttify.FoundationFluttifyPluginKt.getHEAP;
|
||||
|
||||
@SuppressWarnings("ALL")
|
||||
public class SubHandlerCustom {
|
||||
|
||||
public static final SubHandlerCustom instance = new SubHandlerCustom();
|
||||
|
||||
private SubHandlerCustom() { }
|
||||
|
||||
public Map<String, Handler> getSubHandler(BinaryMessenger messenger, android.app.Activity activity) {
|
||||
return new HashMap<String, Handler>() {{
|
||||
put("", (args, methodResult) -> {
|
||||
// args
|
||||
|
||||
// ref
|
||||
|
||||
// invoke native method
|
||||
try {
|
||||
|
||||
} catch (Throwable throwable) {
|
||||
throwable.printStackTrace();
|
||||
if (getEnableLog()) {
|
||||
Log.d("Current HEAP: ", getHEAP().toString());
|
||||
}
|
||||
methodResult.error(throwable.getMessage(), null, null);
|
||||
return;
|
||||
}
|
||||
|
||||
// convert result to jsonable result
|
||||
String jsonableResult = "success";
|
||||
|
||||
methodResult.success(jsonableResult);
|
||||
});
|
||||
}};
|
||||
}
|
||||
}
|
|
@ -0,0 +1,43 @@
|
|||
# Miscellaneous
|
||||
*.class
|
||||
*.log
|
||||
*.pyc
|
||||
*.swp
|
||||
.DS_Store
|
||||
.atom/
|
||||
.buildlog/
|
||||
.history
|
||||
.svn/
|
||||
migrate_working_dir/
|
||||
|
||||
# IntelliJ related
|
||||
*.iml
|
||||
*.ipr
|
||||
*.iws
|
||||
.idea/
|
||||
|
||||
# The .vscode folder contains launch configuration and tasks you configure in
|
||||
# VS Code which you may wish to be included in version control, so this line
|
||||
# is commented out by default.
|
||||
#.vscode/
|
||||
|
||||
# Flutter/Dart/Pub related
|
||||
**/doc/api/
|
||||
**/ios/Flutter/.last_build_id
|
||||
.dart_tool/
|
||||
.flutter-plugins
|
||||
.flutter-plugins-dependencies
|
||||
.pub-cache/
|
||||
.pub/
|
||||
/build/
|
||||
|
||||
# Symbolication related
|
||||
app.*.symbols
|
||||
|
||||
# Obfuscation related
|
||||
app.*.map.json
|
||||
|
||||
# Android Studio will place build artifacts here
|
||||
/android/app/debug
|
||||
/android/app/profile
|
||||
/android/app/release
|
|
@ -0,0 +1,16 @@
|
|||
# amap_search_fluttify_example
|
||||
|
||||
Demonstrates how to use the amap_search_fluttify plugin.
|
||||
|
||||
## Getting Started
|
||||
|
||||
This project is a starting point for a Flutter application.
|
||||
|
||||
A few resources to get you started if this is your first Flutter project:
|
||||
|
||||
- [Lab: Write your first Flutter app](https://docs.flutter.dev/get-started/codelab)
|
||||
- [Cookbook: Useful Flutter samples](https://docs.flutter.dev/cookbook)
|
||||
|
||||
For help getting started with Flutter development, view the
|
||||
[online documentation](https://docs.flutter.dev/), which offers tutorials,
|
||||
samples, guidance on mobile development, and a full API reference.
|
|
@ -0,0 +1,29 @@
|
|||
# This file configures the analyzer, which statically analyzes Dart code to
|
||||
# check for errors, warnings, and lints.
|
||||
#
|
||||
# The issues identified by the analyzer are surfaced in the UI of Dart-enabled
|
||||
# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
|
||||
# invoked from the command line by running `flutter analyze`.
|
||||
|
||||
# The following line activates a set of recommended lints for Flutter apps,
|
||||
# packages, and plugins designed to encourage good coding practices.
|
||||
include: package:flutter_lints/flutter.yaml
|
||||
|
||||
linter:
|
||||
# The lint rules applied to this project can be customized in the
|
||||
# section below to disable rules from the `package:flutter_lints/flutter.yaml`
|
||||
# included above or to enable additional rules. A list of all available lints
|
||||
# and their documentation is published at
|
||||
# https://dart-lang.github.io/linter/lints/index.html.
|
||||
#
|
||||
# Instead of disabling a lint rule for the entire project in the
|
||||
# section below, it can also be suppressed for a single line of code
|
||||
# or a specific dart file by using the `// ignore: name_of_lint` and
|
||||
# `// ignore_for_file: name_of_lint` syntax on the line or in the file
|
||||
# producing the lint.
|
||||
rules:
|
||||
# avoid_print: false # Uncomment to disable the `avoid_print` rule
|
||||
# prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule
|
||||
|
||||
# Additional information about this file can be found at
|
||||
# https://dart.dev/guides/language/analysis-options
|
|
@ -0,0 +1,69 @@
|
|||
def localProperties = new Properties()
|
||||
def localPropertiesFile = rootProject.file('local.properties')
|
||||
if (localPropertiesFile.exists()) {
|
||||
localPropertiesFile.withReader('UTF-8') { reader ->
|
||||
localProperties.load(reader)
|
||||
}
|
||||
}
|
||||
|
||||
def flutterRoot = localProperties.getProperty('flutter.sdk')
|
||||
if (flutterRoot == null) {
|
||||
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
|
||||
}
|
||||
|
||||
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
|
||||
if (flutterVersionCode == null) {
|
||||
flutterVersionCode = '1'
|
||||
}
|
||||
|
||||
def flutterVersionName = localProperties.getProperty('flutter.versionName')
|
||||
if (flutterVersionName == null) {
|
||||
flutterVersionName = '1.0'
|
||||
}
|
||||
|
||||
apply plugin: 'com.android.application'
|
||||
apply plugin: 'kotlin-android'
|
||||
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
|
||||
|
||||
android {
|
||||
compileSdkVersion flutter.compileSdkVersion
|
||||
ndkVersion flutter.ndkVersion
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility JavaVersion.VERSION_1_8
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
defaultConfig {
|
||||
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
|
||||
applicationId "me.yohom.amap_search_fluttify_example"
|
||||
// You can update the following values to match your application needs.
|
||||
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-build-configuration.
|
||||
minSdkVersion 21
|
||||
targetSdkVersion flutter.targetSdkVersion
|
||||
versionCode flutterVersionCode.toInteger()
|
||||
versionName flutterVersionName
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
keyAlias 'amap_search_test'
|
||||
keyPassword 'amap_search_test'
|
||||
storeFile file('../amap_search_test.jks')
|
||||
storePassword 'amap_search_test'
|
||||
}
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
debug {
|
||||
signingConfig signingConfigs.release
|
||||
}
|
||||
release {
|
||||
signingConfig signingConfigs.release
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
flutter {
|
||||
source '../..'
|
||||
}
|
|
@ -0,0 +1,8 @@
|
|||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="me.yohom.amap_search_fluttify_example">
|
||||
<!-- The INTERNET permission is required for development. Specifically,
|
||||
the Flutter tool needs it to communicate with the running application
|
||||
to allow setting breakpoints, to provide hot reload, etc.
|
||||
-->
|
||||
<uses-permission android:name="android.permission.INTERNET"/>
|
||||
</manifest>
|
|
@ -0,0 +1,52 @@
|
|||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="me.yohom.amap_search_fluttify_example">
|
||||
|
||||
<!--允许程序打开网络套接字-->
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
<!--允许程序设置内置sd卡的写权限-->
|
||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
||||
<!--允许程序获取网络状态-->
|
||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
||||
<!--允许程序访问WiFi网络信息-->
|
||||
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
|
||||
<!--允许程序读写手机状态和身份-->
|
||||
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
|
||||
<!--允许程序访问CellID或WiFi热点来获取粗略的位置-->
|
||||
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
|
||||
|
||||
<application
|
||||
android:label="amap_search_fluttify_example"
|
||||
android:name="${applicationName}"
|
||||
android:icon="@mipmap/ic_launcher">
|
||||
|
||||
<meta-data android:name="com.amap.api.v2.apikey"
|
||||
android:value="c50f89a05a0a5c8e11ab5383f4d13952"/>
|
||||
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:exported="true"
|
||||
android:launchMode="singleTop"
|
||||
android:theme="@style/LaunchTheme"
|
||||
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
|
||||
android:hardwareAccelerated="true"
|
||||
android:windowSoftInputMode="adjustResize">
|
||||
<!-- Specifies an Android theme to apply to this Activity as soon as
|
||||
the Android process has started. This theme is visible to the user
|
||||
while the Flutter UI initializes. After that, this theme continues
|
||||
to determine the Window background behind the Flutter UI. -->
|
||||
<meta-data
|
||||
android:name="io.flutter.embedding.android.NormalTheme"
|
||||
android:resource="@style/NormalTheme"
|
||||
/>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN"/>
|
||||
<category android:name="android.intent.category.LAUNCHER"/>
|
||||
</intent-filter>
|
||||
</activity>
|
||||
<!-- Don't delete the meta-data below.
|
||||
This is used by the Flutter tool to generate GeneratedPluginRegistrant.java -->
|
||||
<meta-data
|
||||
android:name="flutterEmbedding"
|
||||
android:value="2" />
|
||||
</application>
|
||||
</manifest>
|
|
@ -0,0 +1,6 @@
|
|||
package me.yohom.amap_search_fluttify_example;
|
||||
|
||||
import io.flutter.embedding.android.FlutterActivity;
|
||||
|
||||
public class MainActivity extends FlutterActivity {
|
||||
}
|
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Modify this file to customize your launch splash screen -->
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="?android:colorBackground" />
|
||||
|
||||
<!-- You can insert your own image assets here -->
|
||||
<!-- <item>
|
||||
<bitmap
|
||||
android:gravity="center"
|
||||
android:src="@mipmap/launch_image" />
|
||||
</item> -->
|
||||
</layer-list>
|
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Modify this file to customize your launch splash screen -->
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@android:color/white" />
|
||||
|
||||
<!-- You can insert your own image assets here -->
|
||||
<!-- <item>
|
||||
<bitmap
|
||||
android:gravity="center"
|
||||
android:src="@mipmap/launch_image" />
|
||||
</item> -->
|
||||
</layer-list>
|
After Width: | Height: | Size: 544 B |
After Width: | Height: | Size: 442 B |
After Width: | Height: | Size: 721 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 1.4 KiB |
|
@ -0,0 +1,18 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- Theme applied to the Android Window while the process is starting when the OS's Dark Mode setting is on -->
|
||||
<style name="LaunchTheme" parent="@android:style/Theme.Black.NoTitleBar">
|
||||
<!-- Show a splash screen on the activity. Automatically removed when
|
||||
the Flutter engine draws its first frame -->
|
||||
<item name="android:windowBackground">@drawable/launch_background</item>
|
||||
</style>
|
||||
<!-- Theme applied to the Android Window as soon as the process has started.
|
||||
This theme determines the color of the Android Window while your
|
||||
Flutter UI initializes, as well as behind your Flutter UI while its
|
||||
running.
|
||||
|
||||
This Theme is only used starting with V2 of Flutter's Android embedding. -->
|
||||
<style name="NormalTheme" parent="@android:style/Theme.Black.NoTitleBar">
|
||||
<item name="android:windowBackground">?android:colorBackground</item>
|
||||
</style>
|
||||
</resources>
|
|
@ -0,0 +1,18 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- Theme applied to the Android Window while the process is starting when the OS's Dark Mode setting is off -->
|
||||
<style name="LaunchTheme" parent="@android:style/Theme.Light.NoTitleBar">
|
||||
<!-- Show a splash screen on the activity. Automatically removed when
|
||||
the Flutter engine draws its first frame -->
|
||||
<item name="android:windowBackground">@drawable/launch_background</item>
|
||||
</style>
|
||||
<!-- Theme applied to the Android Window as soon as the process has started.
|
||||
This theme determines the color of the Android Window while your
|
||||
Flutter UI initializes, as well as behind your Flutter UI while its
|
||||
running.
|
||||
|
||||
This Theme is only used starting with V2 of Flutter's Android embedding. -->
|
||||
<style name="NormalTheme" parent="@android:style/Theme.Light.NoTitleBar">
|
||||
<item name="android:windowBackground">?android:colorBackground</item>
|
||||
</style>
|
||||
</resources>
|
|
@ -0,0 +1,8 @@
|
|||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="me.yohom.amap_search_fluttify_example">
|
||||
<!-- The INTERNET permission is required for development. Specifically,
|
||||
the Flutter tool needs it to communicate with the running application
|
||||
to allow setting breakpoints, to provide hot reload, etc.
|
||||
-->
|
||||
<uses-permission android:name="android.permission.INTERNET"/>
|
||||
</manifest>
|
|
@ -0,0 +1,31 @@
|
|||
buildscript {
|
||||
ext.kotlin_version = '1.6.10'
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:7.1.2'
|
||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||
}
|
||||
}
|
||||
|
||||
allprojects {
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
}
|
||||
}
|
||||
|
||||
rootProject.buildDir = '../build'
|
||||
subprojects {
|
||||
project.buildDir = "${rootProject.buildDir}/${project.name}"
|
||||
}
|
||||
subprojects {
|
||||
project.evaluationDependsOn(':app')
|
||||
}
|
||||
|
||||
task clean(type: Delete) {
|
||||
delete rootProject.buildDir
|
||||
}
|
|
@ -0,0 +1,3 @@
|
|||
org.gradle.jvmargs=-Xmx1536M
|
||||
android.useAndroidX=true
|
||||
android.enableJetifier=true
|
|
@ -0,0 +1,6 @@
|
|||
#Fri Jun 23 08:50:38 CEST 2017
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-all.zip
|
|
@ -0,0 +1,11 @@
|
|||
include ':app'
|
||||
|
||||
def localPropertiesFile = new File(rootProject.projectDir, "local.properties")
|
||||
def properties = new Properties()
|
||||
|
||||
assert localPropertiesFile.exists()
|
||||
localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) }
|
||||
|
||||
def flutterSdkPath = properties.getProperty("flutter.sdk")
|
||||
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
|
||||
apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle"
|
|
@ -0,0 +1,26 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>en</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>App</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>io.flutter.flutter.app</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>App</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>FMWK</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>1.0</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1.0</string>
|
||||
<key>MinimumOSVersion</key>
|
||||
<string>9.0</string>
|
||||
</dict>
|
||||
</plist>
|
|
@ -0,0 +1,2 @@
|
|||
#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
|
||||
#include "Generated.xcconfig"
|
|
@ -0,0 +1,2 @@
|
|||
#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
|
||||
#include "Generated.xcconfig"
|
|
@ -0,0 +1,40 @@
|
|||
source 'https://gitee.com/mirrors/CocoaPods-Specs.git' # 指定源
|
||||
|
||||
# Uncomment this line to define a global platform for your project
|
||||
# platform :ios, '9.0'
|
||||
|
||||
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
|
||||
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
|
||||
|
||||
project 'Runner', {
|
||||
'Debug' => :debug,
|
||||
'Profile' => :release,
|
||||
'Release' => :release,
|
||||
}
|
||||
|
||||
def flutter_root
|
||||
generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__)
|
||||
unless File.exist?(generated_xcode_build_settings_path)
|
||||
raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first"
|
||||
end
|
||||
|
||||
File.foreach(generated_xcode_build_settings_path) do |line|
|
||||
matches = line.match(/FLUTTER_ROOT\=(.*)/)
|
||||
return matches[1].strip if matches
|
||||
end
|
||||
raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get"
|
||||
end
|
||||
|
||||
require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)
|
||||
|
||||
flutter_ios_podfile_setup
|
||||
|
||||
target 'Runner' do
|
||||
flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
|
||||
end
|
||||
|
||||
post_install do |installer|
|
||||
installer.pods_project.targets.each do |target|
|
||||
flutter_additional_ios_build_settings(target)
|
||||
end
|
||||
end
|
|
@ -0,0 +1,79 @@
|
|||
PODS:
|
||||
- amap_core_fluttify (0.0.1):
|
||||
- AMapFoundation-NO-IDFA (~> 1.6.9)
|
||||
- Flutter
|
||||
- foundation_fluttify
|
||||
- amap_search_fluttify (0.0.1):
|
||||
- AMapSearch-NO-IDFA (= 9.2.0)
|
||||
- Flutter
|
||||
- foundation_fluttify
|
||||
- AMapFoundation-NO-IDFA (1.6.9)
|
||||
- AMapSearch-NO-IDFA (9.2.0):
|
||||
- AMapFoundation-NO-IDFA (~> 1.6.9)
|
||||
- core_location_fluttify (0.0.1):
|
||||
- Flutter
|
||||
- foundation_fluttify
|
||||
- Flutter (1.0.0)
|
||||
- FMDB (2.7.5):
|
||||
- FMDB/standard (= 2.7.5)
|
||||
- FMDB/standard (2.7.5)
|
||||
- foundation_fluttify (0.0.1):
|
||||
- Flutter
|
||||
- path_provider_ios (0.0.1):
|
||||
- Flutter
|
||||
- permission_handler_apple (9.0.4):
|
||||
- Flutter
|
||||
- sqflite (0.0.2):
|
||||
- Flutter
|
||||
- FMDB (>= 2.7.5)
|
||||
|
||||
DEPENDENCIES:
|
||||
- amap_core_fluttify (from `.symlinks/plugins/amap_core_fluttify/ios`)
|
||||
- amap_search_fluttify (from `.symlinks/plugins/amap_search_fluttify/ios`)
|
||||
- core_location_fluttify (from `.symlinks/plugins/core_location_fluttify/ios`)
|
||||
- Flutter (from `Flutter`)
|
||||
- foundation_fluttify (from `.symlinks/plugins/foundation_fluttify/ios`)
|
||||
- path_provider_ios (from `.symlinks/plugins/path_provider_ios/ios`)
|
||||
- permission_handler_apple (from `.symlinks/plugins/permission_handler_apple/ios`)
|
||||
- sqflite (from `.symlinks/plugins/sqflite/ios`)
|
||||
|
||||
SPEC REPOS:
|
||||
https://gitee.com/mirrors/CocoaPods-Specs.git:
|
||||
- AMapFoundation-NO-IDFA
|
||||
- AMapSearch-NO-IDFA
|
||||
- FMDB
|
||||
|
||||
EXTERNAL SOURCES:
|
||||
amap_core_fluttify:
|
||||
:path: ".symlinks/plugins/amap_core_fluttify/ios"
|
||||
amap_search_fluttify:
|
||||
:path: ".symlinks/plugins/amap_search_fluttify/ios"
|
||||
core_location_fluttify:
|
||||
:path: ".symlinks/plugins/core_location_fluttify/ios"
|
||||
Flutter:
|
||||
:path: Flutter
|
||||
foundation_fluttify:
|
||||
:path: ".symlinks/plugins/foundation_fluttify/ios"
|
||||
path_provider_ios:
|
||||
:path: ".symlinks/plugins/path_provider_ios/ios"
|
||||
permission_handler_apple:
|
||||
:path: ".symlinks/plugins/permission_handler_apple/ios"
|
||||
sqflite:
|
||||
:path: ".symlinks/plugins/sqflite/ios"
|
||||
|
||||
SPEC CHECKSUMS:
|
||||
amap_core_fluttify: b84657ba39ee287a4b96bbcc0a6e67612cc3808f
|
||||
amap_search_fluttify: cfab91aa65730337fff54705aae0423ea752fc91
|
||||
AMapFoundation-NO-IDFA: cc2ec7a2828ef292358ad594b7ee0ae21a7f097b
|
||||
AMapSearch-NO-IDFA: 9df378c88d50083346412ee3e0a10e2c451c7139
|
||||
core_location_fluttify: 9466a411ea7d22c6349c7e6a767ae4623f01eb1d
|
||||
Flutter: 50d75fe2f02b26cc09d224853bb45737f8b3214a
|
||||
FMDB: 2ce00b547f966261cd18927a3ddb07cb6f3db82a
|
||||
foundation_fluttify: 0c45145e3fad1fb99188e4979daed5b24cd9b278
|
||||
path_provider_ios: 14f3d2fd28c4fdb42f44e0f751d12861c43cee02
|
||||
permission_handler_apple: 44366e37eaf29454a1e7b1b7d736c2cceaeb17ce
|
||||
sqflite: 6d358c025f5b867b29ed92fc697fd34924e11904
|
||||
|
||||
PODFILE CHECKSUM: febb83c8a930141d95caab555982aeda42924994
|
||||
|
||||
COCOAPODS: 1.11.3
|
|
@ -0,0 +1,533 @@
|
|||
// !$*UTF8*$!
|
||||
{
|
||||
archiveVersion = 1;
|
||||
classes = {
|
||||
};
|
||||
objectVersion = 50;
|
||||
objects = {
|
||||
|
||||
/* Begin PBXBuildFile section */
|
||||
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
|
||||
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
|
||||
978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */; };
|
||||
97C146F31CF9000F007C117D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 97C146F21CF9000F007C117D /* main.m */; };
|
||||
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
|
||||
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
|
||||
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
|
||||
C0B36C54DB5DBC10D79240BB /* libPods-Runner.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 180D186A924BD5A7CCAAEA21 /* libPods-Runner.a */; };
|
||||
/* End PBXBuildFile section */
|
||||
|
||||
/* Begin PBXCopyFilesBuildPhase section */
|
||||
9705A1C41CF9048500538489 /* Embed Frameworks */ = {
|
||||
isa = PBXCopyFilesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
dstPath = "";
|
||||
dstSubfolderSpec = 10;
|
||||
files = (
|
||||
);
|
||||
name = "Embed Frameworks";
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXCopyFilesBuildPhase section */
|
||||
|
||||
/* Begin PBXFileReference section */
|
||||
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; };
|
||||
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; };
|
||||
180D186A924BD5A7CCAAEA21 /* libPods-Runner.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Runner.a"; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
28AD679E3FA43023F7CCD9D8 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = "<group>"; };
|
||||
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; };
|
||||
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; };
|
||||
7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
|
||||
7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
|
||||
9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = "<group>"; };
|
||||
9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = "<group>"; };
|
||||
97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
97C146F21CF9000F007C117D /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
|
||||
97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
|
||||
97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
|
||||
97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
|
||||
97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
|
||||
E1197FAC12FF2CEA10980272 /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = "<group>"; };
|
||||
F82654A1512C05C7ABC37DB9 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; };
|
||||
/* End PBXFileReference section */
|
||||
|
||||
/* Begin PBXFrameworksBuildPhase section */
|
||||
97C146EB1CF9000F007C117D /* Frameworks */ = {
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
C0B36C54DB5DBC10D79240BB /* libPods-Runner.a in Frameworks */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXFrameworksBuildPhase section */
|
||||
|
||||
/* Begin PBXGroup section */
|
||||
13127E28C69117CB1D457D3D /* Pods */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
28AD679E3FA43023F7CCD9D8 /* Pods-Runner.debug.xcconfig */,
|
||||
F82654A1512C05C7ABC37DB9 /* Pods-Runner.release.xcconfig */,
|
||||
E1197FAC12FF2CEA10980272 /* Pods-Runner.profile.xcconfig */,
|
||||
);
|
||||
name = Pods;
|
||||
path = Pods;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
7F0C698E17349BD2A011B0D9 /* Frameworks */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
180D186A924BD5A7CCAAEA21 /* libPods-Runner.a */,
|
||||
);
|
||||
name = Frameworks;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
9740EEB11CF90186004384FC /* Flutter */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */,
|
||||
9740EEB21CF90195004384FC /* Debug.xcconfig */,
|
||||
7AFA3C8E1D35360C0083082E /* Release.xcconfig */,
|
||||
9740EEB31CF90195004384FC /* Generated.xcconfig */,
|
||||
);
|
||||
name = Flutter;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
97C146E51CF9000F007C117D = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
9740EEB11CF90186004384FC /* Flutter */,
|
||||
97C146F01CF9000F007C117D /* Runner */,
|
||||
97C146EF1CF9000F007C117D /* Products */,
|
||||
13127E28C69117CB1D457D3D /* Pods */,
|
||||
7F0C698E17349BD2A011B0D9 /* Frameworks */,
|
||||
);
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
97C146EF1CF9000F007C117D /* Products */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
97C146EE1CF9000F007C117D /* Runner.app */,
|
||||
);
|
||||
name = Products;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
97C146F01CF9000F007C117D /* Runner */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */,
|
||||
7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */,
|
||||
97C146FA1CF9000F007C117D /* Main.storyboard */,
|
||||
97C146FD1CF9000F007C117D /* Assets.xcassets */,
|
||||
97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */,
|
||||
97C147021CF9000F007C117D /* Info.plist */,
|
||||
97C146F11CF9000F007C117D /* Supporting Files */,
|
||||
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */,
|
||||
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */,
|
||||
);
|
||||
path = Runner;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
97C146F11CF9000F007C117D /* Supporting Files */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
97C146F21CF9000F007C117D /* main.m */,
|
||||
);
|
||||
name = "Supporting Files";
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
/* End PBXGroup section */
|
||||
|
||||
/* Begin PBXNativeTarget section */
|
||||
97C146ED1CF9000F007C117D /* Runner */ = {
|
||||
isa = PBXNativeTarget;
|
||||
buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
|
||||
buildPhases = (
|
||||
63C43029C85D2994500C7A9F /* [CP] Check Pods Manifest.lock */,
|
||||
9740EEB61CF901F6004384FC /* Run Script */,
|
||||
97C146EA1CF9000F007C117D /* Sources */,
|
||||
97C146EB1CF9000F007C117D /* Frameworks */,
|
||||
97C146EC1CF9000F007C117D /* Resources */,
|
||||
9705A1C41CF9048500538489 /* Embed Frameworks */,
|
||||
3B06AD1E1E4923F5004D2608 /* Thin Binary */,
|
||||
);
|
||||
buildRules = (
|
||||
);
|
||||
dependencies = (
|
||||
);
|
||||
name = Runner;
|
||||
productName = Runner;
|
||||
productReference = 97C146EE1CF9000F007C117D /* Runner.app */;
|
||||
productType = "com.apple.product-type.application";
|
||||
};
|
||||
/* End PBXNativeTarget section */
|
||||
|
||||
/* Begin PBXProject section */
|
||||
97C146E61CF9000F007C117D /* Project object */ = {
|
||||
isa = PBXProject;
|
||||
attributes = {
|
||||
LastUpgradeCheck = 1300;
|
||||
ORGANIZATIONNAME = "";
|
||||
TargetAttributes = {
|
||||
97C146ED1CF9000F007C117D = {
|
||||
CreatedOnToolsVersion = 7.3.1;
|
||||
};
|
||||
};
|
||||
};
|
||||
buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */;
|
||||
compatibilityVersion = "Xcode 9.3";
|
||||
developmentRegion = en;
|
||||
hasScannedForEncodings = 0;
|
||||
knownRegions = (
|
||||
en,
|
||||
Base,
|
||||
);
|
||||
mainGroup = 97C146E51CF9000F007C117D;
|
||||
productRefGroup = 97C146EF1CF9000F007C117D /* Products */;
|
||||
projectDirPath = "";
|
||||
projectRoot = "";
|
||||
targets = (
|
||||
97C146ED1CF9000F007C117D /* Runner */,
|
||||
);
|
||||
};
|
||||
/* End PBXProject section */
|
||||
|
||||
/* Begin PBXResourcesBuildPhase section */
|
||||
97C146EC1CF9000F007C117D /* Resources */ = {
|
||||
isa = PBXResourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */,
|
||||
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
|
||||
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
|
||||
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXResourcesBuildPhase section */
|
||||
|
||||
/* Begin PBXShellScriptBuildPhase section */
|
||||
3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
|
||||
isa = PBXShellScriptBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
inputPaths = (
|
||||
);
|
||||
name = "Thin Binary";
|
||||
outputPaths = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
shellPath = /bin/sh;
|
||||
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
|
||||
};
|
||||
63C43029C85D2994500C7A9F /* [CP] Check Pods Manifest.lock */ = {
|
||||
isa = PBXShellScriptBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
inputFileListPaths = (
|
||||
);
|
||||
inputPaths = (
|
||||
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
|
||||
"${PODS_ROOT}/Manifest.lock",
|
||||
);
|
||||
name = "[CP] Check Pods Manifest.lock";
|
||||
outputFileListPaths = (
|
||||
);
|
||||
outputPaths = (
|
||||
"$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt",
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
shellPath = /bin/sh;
|
||||
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;
|
||||
};
|
||||
9740EEB61CF901F6004384FC /* Run Script */ = {
|
||||
isa = PBXShellScriptBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
);
|
||||
inputPaths = (
|
||||
);
|
||||
name = "Run Script";
|
||||
outputPaths = (
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
shellPath = /bin/sh;
|
||||
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
|
||||
};
|
||||
/* End PBXShellScriptBuildPhase section */
|
||||
|
||||
/* Begin PBXSourcesBuildPhase section */
|
||||
97C146EA1CF9000F007C117D /* Sources */ = {
|
||||
isa = PBXSourcesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */,
|
||||
97C146F31CF9000F007C117D /* main.m in Sources */,
|
||||
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXSourcesBuildPhase section */
|
||||
|
||||
/* Begin PBXVariantGroup section */
|
||||
97C146FA1CF9000F007C117D /* Main.storyboard */ = {
|
||||
isa = PBXVariantGroup;
|
||||
children = (
|
||||
97C146FB1CF9000F007C117D /* Base */,
|
||||
);
|
||||
name = Main.storyboard;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = {
|
||||
isa = PBXVariantGroup;
|
||||
children = (
|
||||
97C147001CF9000F007C117D /* Base */,
|
||||
);
|
||||
name = LaunchScreen.storyboard;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
/* End PBXVariantGroup section */
|
||||
|
||||
/* Begin XCBuildConfiguration section */
|
||||
249021D3217E4FDB00AE95B9 /* Profile */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
CLANG_ANALYZER_NONNULL = YES;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_CXX_LIBRARY = "libc++";
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CLANG_ENABLE_OBJC_ARC = YES;
|
||||
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
|
||||
CLANG_WARN_BOOL_CONVERSION = YES;
|
||||
CLANG_WARN_COMMA = YES;
|
||||
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
||||
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
|
||||
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
||||
CLANG_WARN_EMPTY_BODY = YES;
|
||||
CLANG_WARN_ENUM_CONVERSION = YES;
|
||||
CLANG_WARN_INFINITE_RECURSION = YES;
|
||||
CLANG_WARN_INT_CONVERSION = YES;
|
||||
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
||||
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
||||
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
||||
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
||||
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
||||
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
||||
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;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
||||
MTL_ENABLE_DEBUG_INFO = NO;
|
||||
SDKROOT = iphoneos;
|
||||
SUPPORTED_PLATFORMS = iphoneos;
|
||||
TARGETED_DEVICE_FAMILY = "1,2";
|
||||
VALIDATE_PRODUCT = YES;
|
||||
};
|
||||
name = Profile;
|
||||
};
|
||||
249021D4217E4FDB00AE95B9 /* Profile */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
|
||||
DEVELOPMENT_TEAM = X5P24RK5QW;
|
||||
ENABLE_BITCODE = NO;
|
||||
INFOPLIST_FILE = Runner/Info.plist;
|
||||
LD_RUNPATH_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
);
|
||||
PRODUCT_BUNDLE_IDENTIFIER = me.yohom.amapSearchFluttifyExample;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
VERSIONING_SYSTEM = "apple-generic";
|
||||
};
|
||||
name = Profile;
|
||||
};
|
||||
97C147031CF9000F007C117D /* Debug */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
CLANG_ANALYZER_NONNULL = YES;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_CXX_LIBRARY = "libc++";
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CLANG_ENABLE_OBJC_ARC = YES;
|
||||
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
|
||||
CLANG_WARN_BOOL_CONVERSION = YES;
|
||||
CLANG_WARN_COMMA = YES;
|
||||
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
||||
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
|
||||
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
||||
CLANG_WARN_EMPTY_BODY = YES;
|
||||
CLANG_WARN_ENUM_CONVERSION = YES;
|
||||
CLANG_WARN_INFINITE_RECURSION = YES;
|
||||
CLANG_WARN_INT_CONVERSION = YES;
|
||||
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
||||
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
||||
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
||||
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
||||
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
||||
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
||||
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;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
||||
MTL_ENABLE_DEBUG_INFO = YES;
|
||||
ONLY_ACTIVE_ARCH = YES;
|
||||
SDKROOT = iphoneos;
|
||||
TARGETED_DEVICE_FAMILY = "1,2";
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
97C147041CF9000F007C117D /* Release */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
CLANG_ANALYZER_NONNULL = YES;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_CXX_LIBRARY = "libc++";
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CLANG_ENABLE_OBJC_ARC = YES;
|
||||
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
|
||||
CLANG_WARN_BOOL_CONVERSION = YES;
|
||||
CLANG_WARN_COMMA = YES;
|
||||
CLANG_WARN_CONSTANT_CONVERSION = YES;
|
||||
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
|
||||
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
|
||||
CLANG_WARN_EMPTY_BODY = YES;
|
||||
CLANG_WARN_ENUM_CONVERSION = YES;
|
||||
CLANG_WARN_INFINITE_RECURSION = YES;
|
||||
CLANG_WARN_INT_CONVERSION = YES;
|
||||
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
|
||||
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
|
||||
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
|
||||
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
|
||||
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
|
||||
CLANG_WARN_STRICT_PROTOTYPES = YES;
|
||||
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;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
|
||||
MTL_ENABLE_DEBUG_INFO = NO;
|
||||
SDKROOT = iphoneos;
|
||||
SUPPORTED_PLATFORMS = iphoneos;
|
||||
TARGETED_DEVICE_FAMILY = "1,2";
|
||||
VALIDATE_PRODUCT = YES;
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
97C147061CF9000F007C117D /* Debug */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
|
||||
DEVELOPMENT_TEAM = X5P24RK5QW;
|
||||
ENABLE_BITCODE = NO;
|
||||
INFOPLIST_FILE = Runner/Info.plist;
|
||||
LD_RUNPATH_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
);
|
||||
PRODUCT_BUNDLE_IDENTIFIER = me.yohom.amapSearchFluttifyExample;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
VERSIONING_SYSTEM = "apple-generic";
|
||||
};
|
||||
name = Debug;
|
||||
};
|
||||
97C147071CF9000F007C117D /* Release */ = {
|
||||
isa = XCBuildConfiguration;
|
||||
baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
|
||||
DEVELOPMENT_TEAM = X5P24RK5QW;
|
||||
ENABLE_BITCODE = NO;
|
||||
INFOPLIST_FILE = Runner/Info.plist;
|
||||
LD_RUNPATH_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
);
|
||||
PRODUCT_BUNDLE_IDENTIFIER = me.yohom.amapSearchFluttifyExample;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
VERSIONING_SYSTEM = "apple-generic";
|
||||
};
|
||||
name = Release;
|
||||
};
|
||||
/* End XCBuildConfiguration section */
|
||||
|
||||
/* Begin XCConfigurationList section */
|
||||
97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
97C147031CF9000F007C117D /* Debug */,
|
||||
97C147041CF9000F007C117D /* Release */,
|
||||
249021D3217E4FDB00AE95B9 /* Profile */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Release;
|
||||
};
|
||||
97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = {
|
||||
isa = XCConfigurationList;
|
||||
buildConfigurations = (
|
||||
97C147061CF9000F007C117D /* Debug */,
|
||||
97C147071CF9000F007C117D /* Release */,
|
||||
249021D4217E4FDB00AE95B9 /* Profile */,
|
||||
);
|
||||
defaultConfigurationIsVisible = 0;
|
||||
defaultConfigurationName = Release;
|
||||
};
|
||||
/* End XCConfigurationList section */
|
||||
};
|
||||
rootObject = 97C146E61CF9000F007C117D /* Project object */;
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Workspace
|
||||
version = "1.0">
|
||||
<FileRef
|
||||
location = "self:">
|
||||
</FileRef>
|
||||
</Workspace>
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>IDEDidComputeMac32BitWarning</key>
|
||||
<true/>
|
||||
</dict>
|
||||
</plist>
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>PreviewsEnabled</key>
|
||||
<false/>
|
||||
</dict>
|
||||
</plist>
|
|
@ -0,0 +1,87 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Scheme
|
||||
LastUpgradeVersion = "1300"
|
||||
version = "1.3">
|
||||
<BuildAction
|
||||
parallelizeBuildables = "YES"
|
||||
buildImplicitDependencies = "YES">
|
||||
<BuildActionEntries>
|
||||
<BuildActionEntry
|
||||
buildForTesting = "YES"
|
||||
buildForRunning = "YES"
|
||||
buildForProfiling = "YES"
|
||||
buildForArchiving = "YES"
|
||||
buildForAnalyzing = "YES">
|
||||
<BuildableReference
|
||||
BuildableIdentifier = "primary"
|
||||
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
|
||||
BuildableName = "Runner.app"
|
||||
BlueprintName = "Runner"
|
||||
ReferencedContainer = "container:Runner.xcodeproj">
|
||||
</BuildableReference>
|
||||
</BuildActionEntry>
|
||||
</BuildActionEntries>
|
||||
</BuildAction>
|
||||
<TestAction
|
||||
buildConfiguration = "Debug"
|
||||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
|
||||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
|
||||
shouldUseLaunchSchemeArgsEnv = "YES">
|
||||
<MacroExpansion>
|
||||
<BuildableReference
|
||||
BuildableIdentifier = "primary"
|
||||
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
|
||||
BuildableName = "Runner.app"
|
||||
BlueprintName = "Runner"
|
||||
ReferencedContainer = "container:Runner.xcodeproj">
|
||||
</BuildableReference>
|
||||
</MacroExpansion>
|
||||
<Testables>
|
||||
</Testables>
|
||||
</TestAction>
|
||||
<LaunchAction
|
||||
buildConfiguration = "Debug"
|
||||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
|
||||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
|
||||
launchStyle = "0"
|
||||
useCustomWorkingDirectory = "NO"
|
||||
ignoresPersistentStateOnLaunch = "NO"
|
||||
debugDocumentVersioning = "YES"
|
||||
debugServiceExtension = "internal"
|
||||
allowLocationSimulation = "YES">
|
||||
<BuildableProductRunnable
|
||||
runnableDebuggingMode = "0">
|
||||
<BuildableReference
|
||||
BuildableIdentifier = "primary"
|
||||
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
|
||||
BuildableName = "Runner.app"
|
||||
BlueprintName = "Runner"
|
||||
ReferencedContainer = "container:Runner.xcodeproj">
|
||||
</BuildableReference>
|
||||
</BuildableProductRunnable>
|
||||
</LaunchAction>
|
||||
<ProfileAction
|
||||
buildConfiguration = "Profile"
|
||||
shouldUseLaunchSchemeArgsEnv = "YES"
|
||||
savedToolIdentifier = ""
|
||||
useCustomWorkingDirectory = "NO"
|
||||
debugDocumentVersioning = "YES">
|
||||
<BuildableProductRunnable
|
||||
runnableDebuggingMode = "0">
|
||||
<BuildableReference
|
||||
BuildableIdentifier = "primary"
|
||||
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
|
||||
BuildableName = "Runner.app"
|
||||
BlueprintName = "Runner"
|
||||
ReferencedContainer = "container:Runner.xcodeproj">
|
||||
</BuildableReference>
|
||||
</BuildableProductRunnable>
|
||||
</ProfileAction>
|
||||
<AnalyzeAction
|
||||
buildConfiguration = "Debug">
|
||||
</AnalyzeAction>
|
||||
<ArchiveAction
|
||||
buildConfiguration = "Release"
|
||||
revealArchiveInOrganizer = "YES">
|
||||
</ArchiveAction>
|
||||
</Scheme>
|
|
@ -0,0 +1,10 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Workspace
|
||||
version = "1.0">
|
||||
<FileRef
|
||||
location = "group:Runner.xcodeproj">
|
||||
</FileRef>
|
||||
<FileRef
|
||||
location = "group:Pods/Pods.xcodeproj">
|
||||
</FileRef>
|
||||
</Workspace>
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>IDEDidComputeMac32BitWarning</key>
|
||||
<true/>
|
||||
</dict>
|
||||
</plist>
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>PreviewsEnabled</key>
|
||||
<false/>
|
||||
</dict>
|
||||
</plist>
|
|
@ -0,0 +1,6 @@
|
|||
#import <Flutter/Flutter.h>
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
@interface AppDelegate : FlutterAppDelegate
|
||||
|
||||
@end
|
|
@ -0,0 +1,13 @@
|
|||
#import "AppDelegate.h"
|
||||
#import "GeneratedPluginRegistrant.h"
|
||||
|
||||
@implementation AppDelegate
|
||||
|
||||
- (BOOL)application:(UIApplication *)application
|
||||
didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
|
||||
[GeneratedPluginRegistrant registerWithRegistry:self];
|
||||
// Override point for customization after application launch.
|
||||
return [super application:application didFinishLaunchingWithOptions:launchOptions];
|
||||
}
|
||||
|
||||
@end
|
|
@ -0,0 +1,122 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"size" : "20x20",
|
||||
"idiom" : "iphone",
|
||||
"filename" : "Icon-App-20x20@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"size" : "20x20",
|
||||
"idiom" : "iphone",
|
||||
"filename" : "Icon-App-20x20@3x.png",
|
||||
"scale" : "3x"
|
||||
},
|
||||
{
|
||||
"size" : "29x29",
|
||||
"idiom" : "iphone",
|
||||
"filename" : "Icon-App-29x29@1x.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"size" : "29x29",
|
||||
"idiom" : "iphone",
|
||||
"filename" : "Icon-App-29x29@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"size" : "29x29",
|
||||
"idiom" : "iphone",
|
||||
"filename" : "Icon-App-29x29@3x.png",
|
||||
"scale" : "3x"
|
||||
},
|
||||
{
|
||||
"size" : "40x40",
|
||||
"idiom" : "iphone",
|
||||
"filename" : "Icon-App-40x40@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"size" : "40x40",
|
||||
"idiom" : "iphone",
|
||||
"filename" : "Icon-App-40x40@3x.png",
|
||||
"scale" : "3x"
|
||||
},
|
||||
{
|
||||
"size" : "60x60",
|
||||
"idiom" : "iphone",
|
||||
"filename" : "Icon-App-60x60@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"size" : "60x60",
|
||||
"idiom" : "iphone",
|
||||
"filename" : "Icon-App-60x60@3x.png",
|
||||
"scale" : "3x"
|
||||
},
|
||||
{
|
||||
"size" : "20x20",
|
||||
"idiom" : "ipad",
|
||||
"filename" : "Icon-App-20x20@1x.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"size" : "20x20",
|
||||
"idiom" : "ipad",
|
||||
"filename" : "Icon-App-20x20@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"size" : "29x29",
|
||||
"idiom" : "ipad",
|
||||
"filename" : "Icon-App-29x29@1x.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"size" : "29x29",
|
||||
"idiom" : "ipad",
|
||||
"filename" : "Icon-App-29x29@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"size" : "40x40",
|
||||
"idiom" : "ipad",
|
||||
"filename" : "Icon-App-40x40@1x.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"size" : "40x40",
|
||||
"idiom" : "ipad",
|
||||
"filename" : "Icon-App-40x40@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"size" : "76x76",
|
||||
"idiom" : "ipad",
|
||||
"filename" : "Icon-App-76x76@1x.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"size" : "76x76",
|
||||
"idiom" : "ipad",
|
||||
"filename" : "Icon-App-76x76@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"size" : "83.5x83.5",
|
||||
"idiom" : "ipad",
|
||||
"filename" : "Icon-App-83.5x83.5@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"size" : "1024x1024",
|
||||
"idiom" : "ios-marketing",
|
||||
"filename" : "Icon-App-1024x1024@1x.png",
|
||||
"scale" : "1x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
After Width: | Height: | Size: 11 KiB |
After Width: | Height: | Size: 564 B |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 1.9 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.9 KiB |
After Width: | Height: | Size: 2.6 KiB |
After Width: | Height: | Size: 2.6 KiB |
After Width: | Height: | Size: 3.7 KiB |
After Width: | Height: | Size: 1.8 KiB |
After Width: | Height: | Size: 3.2 KiB |
After Width: | Height: | Size: 3.5 KiB |
|
@ -0,0 +1,23 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "universal",
|
||||
"filename" : "LaunchImage.png",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"idiom" : "universal",
|
||||
"filename" : "LaunchImage@2x.png",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"idiom" : "universal",
|
||||
"filename" : "LaunchImage@3x.png",
|
||||
"scale" : "3x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
After Width: | Height: | Size: 68 B |
After Width: | Height: | Size: 68 B |
After Width: | Height: | Size: 68 B |
|
@ -0,0 +1,5 @@
|
|||
# Launch Screen Assets
|
||||
|
||||
You can customize the launch screen with your own desired assets by replacing the image files in this directory.
|
||||
|
||||
You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images.
|
|
@ -0,0 +1,37 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="12121" systemVersion="16G29" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
|
||||
<dependencies>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="12089"/>
|
||||
</dependencies>
|
||||
<scenes>
|
||||
<!--View Controller-->
|
||||
<scene sceneID="EHf-IW-A2E">
|
||||
<objects>
|
||||
<viewController id="01J-lp-oVM" sceneMemberID="viewController">
|
||||
<layoutGuides>
|
||||
<viewControllerLayoutGuide type="top" id="Ydg-fD-yQy"/>
|
||||
<viewControllerLayoutGuide type="bottom" id="xbc-2k-c8Z"/>
|
||||
</layoutGuides>
|
||||
<view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3">
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<imageView opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" image="LaunchImage" translatesAutoresizingMaskIntoConstraints="NO" id="YRO-k0-Ey4">
|
||||
</imageView>
|
||||
</subviews>
|
||||
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
<constraints>
|
||||
<constraint firstItem="YRO-k0-Ey4" firstAttribute="centerX" secondItem="Ze5-6b-2t3" secondAttribute="centerX" id="1a2-6s-vTC"/>
|
||||
<constraint firstItem="YRO-k0-Ey4" firstAttribute="centerY" secondItem="Ze5-6b-2t3" secondAttribute="centerY" id="4X2-HB-R7a"/>
|
||||
</constraints>
|
||||
</view>
|
||||
</viewController>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/>
|
||||
</objects>
|
||||
<point key="canvasLocation" x="53" y="375"/>
|
||||
</scene>
|
||||
</scenes>
|
||||
<resources>
|
||||
<image name="LaunchImage" width="168" height="185"/>
|
||||
</resources>
|
||||
</document>
|
|
@ -0,0 +1,26 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10117" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r">
|
||||
<dependencies>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>
|
||||
</dependencies>
|
||||
<scenes>
|
||||
<!--Flutter View Controller-->
|
||||
<scene sceneID="tne-QT-ifu">
|
||||
<objects>
|
||||
<viewController id="BYZ-38-t0r" customClass="FlutterViewController" sceneMemberID="viewController">
|
||||
<layoutGuides>
|
||||
<viewControllerLayoutGuide type="top" id="y3c-jy-aDJ"/>
|
||||
<viewControllerLayoutGuide type="bottom" id="wfy-db-euE"/>
|
||||
</layoutGuides>
|
||||
<view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
|
||||
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
|
||||
</view>
|
||||
</viewController>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
|
||||
</objects>
|
||||
</scene>
|
||||
</scenes>
|
||||
</document>
|
|
@ -0,0 +1,47 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>$(DEVELOPMENT_LANGUAGE)</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>amap_search_fluttify_example</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>$(FLUTTER_BUILD_NAME)</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>$(FLUTTER_BUILD_NUMBER)</string>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>LaunchScreen</string>
|
||||
<key>UIMainStoryboardFile</key>
|
||||
<string>Main</string>
|
||||
<key>UISupportedInterfaceOrientations</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations~ipad</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UIViewControllerBasedStatusBarAppearance</key>
|
||||
<false/>
|
||||
<key>CADisableMinimumFrameDurationOnPhone</key>
|
||||
<true/>
|
||||
</dict>
|
||||
</plist>
|
|
@ -0,0 +1,9 @@
|
|||
#import <Flutter/Flutter.h>
|
||||
#import <UIKit/UIKit.h>
|
||||
#import "AppDelegate.h"
|
||||
|
||||
int main(int argc, char* argv[]) {
|
||||
@autoreleasepool {
|
||||
return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
|
||||
}
|
||||
}
|
|
@ -0,0 +1,145 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:amap_search_fluttify_example/widgets/function_item.widget.dart';
|
||||
import 'package:core_location_fluttify/core_location_fluttify.dart';
|
||||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class GetAddressDescScreen extends StatelessWidget {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('获取地址描述数据')),
|
||||
body: ListView(
|
||||
children: <Widget>[
|
||||
const FunctionItem(
|
||||
label: '地理编码(地址转坐标)',
|
||||
sublabel: 'AddressEncodeScreen',
|
||||
target: AddressEncodeScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '逆地理编码(坐标转地址)',
|
||||
sublabel: 'AddressDecodeScreen',
|
||||
target: AddressDecodeScreen(),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/// 地理编码(地址转坐标)
|
||||
class AddressEncodeScreen extends StatefulWidget {
|
||||
const AddressEncodeScreen({Key? key}) : super(key: key);
|
||||
|
||||
@override
|
||||
_AddressEncodeScreenState createState() => _AddressEncodeScreenState();
|
||||
}
|
||||
|
||||
class _AddressEncodeScreenState extends State<AddressEncodeScreen> {
|
||||
final _keywordController = TextEditingController(text: '阿里巴巴');
|
||||
final _cityController = TextEditingController(text: '杭州');
|
||||
|
||||
List<Geocode> _geocodeList = [];
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('地理编码(地址转坐标)')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
TextFormField(
|
||||
controller: _keywordController,
|
||||
decoration: const InputDecoration(hintText: '输入关键字'),
|
||||
),
|
||||
TextFormField(
|
||||
controller: _cityController,
|
||||
decoration: const InputDecoration(hintText: '输入城市'),
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final geocodeList = await AmapSearch.instance.searchGeocode(
|
||||
_keywordController.text,
|
||||
city: _cityController.text,
|
||||
);
|
||||
setState(() {
|
||||
_geocodeList = geocodeList;
|
||||
});
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
if (_geocodeList.isNotEmpty) Text(_geocodeList.toString()),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/// 逆地理编码(坐标转地址)
|
||||
class AddressDecodeScreen extends StatefulWidget {
|
||||
@override
|
||||
_AddressDecodeScreenState createState() => _AddressDecodeScreenState();
|
||||
}
|
||||
|
||||
class _AddressDecodeScreenState extends State<AddressDecodeScreen> {
|
||||
final _latController = TextEditingController(text: '39.9824');
|
||||
final _lngController = TextEditingController(text: '116.3053');
|
||||
final _radiusController = TextEditingController(text: '200.0');
|
||||
|
||||
ReGeocode? _reGeocode;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('逆地理编码(坐标转地址)')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
DecoratedRow(
|
||||
children: <Widget>[
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _latController,
|
||||
decoration: const InputDecoration(hintText: '输入纬度'),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _lngController,
|
||||
decoration: const InputDecoration(hintText: '输入经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
TextFormField(
|
||||
controller: _radiusController,
|
||||
decoration: const InputDecoration(hintText: '输入范围半径'),
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final reGeocodeList = await AmapSearch.instance.searchReGeocode(
|
||||
LatLng(
|
||||
double.parse(_latController.text),
|
||||
double.parse(_lngController.text),
|
||||
),
|
||||
radius: 200.0,
|
||||
);
|
||||
setState(() {
|
||||
_reGeocode = reGeocodeList;
|
||||
});
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
Expanded(
|
||||
child: SingleChildScrollView(
|
||||
child: Text(_reGeocode?.toString() ?? ''),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,50 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:amap_search_fluttify_example/widgets/scrollable_text.widget.dart';
|
||||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
/// 获取公交数据
|
||||
class GetBusInfoScreen extends StatefulWidget {
|
||||
@override
|
||||
_GetBusInfoScreenState createState() => _GetBusInfoScreenState();
|
||||
}
|
||||
|
||||
class _GetBusInfoScreenState extends State<GetBusInfoScreen> {
|
||||
final _keywordController = TextEditingController(text: '武林广场');
|
||||
final _cityController = TextEditingController(text: '杭州');
|
||||
|
||||
String _busStation = '';
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('获取公交数据')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
TextFormField(
|
||||
controller: _keywordController,
|
||||
decoration: const InputDecoration(hintText: '输入公交站点名称'),
|
||||
),
|
||||
TextFormField(
|
||||
controller: _cityController,
|
||||
decoration: const InputDecoration(hintText: '输入城市'),
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final busStation = await AmapSearch.instance.searchBusStation(
|
||||
stationName: _keywordController.text,
|
||||
city: _cityController.text,
|
||||
);
|
||||
_busStation = await busStation.toFutureString();
|
||||
setState(() {});
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
Expanded(child: ScrollableText(_busStation)),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,45 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
/// 获取行政区划数据
|
||||
class GetDistrictInfoScreen extends StatefulWidget {
|
||||
@override
|
||||
_GetDistrictInfoScreenState createState() => _GetDistrictInfoScreenState();
|
||||
}
|
||||
|
||||
class _GetDistrictInfoScreenState extends State<GetDistrictInfoScreen> {
|
||||
final _keywordController = TextEditingController(text: '西湖区');
|
||||
|
||||
String _district = '';
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('获取行政区划数据')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
TextFormField(
|
||||
controller: _keywordController,
|
||||
decoration: const InputDecoration(hintText: '输入地区'),
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final district = await AmapSearch.instance.searchDistrict(
|
||||
_keywordController.text,
|
||||
showBoundary: true,
|
||||
showChild: true,
|
||||
);
|
||||
_district = district.toString();
|
||||
setState(() {});
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
Expanded(child: SingleChildScrollView(child: Text(_district))),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,234 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:amap_search_fluttify_example/widgets/function_item.widget.dart';
|
||||
import 'package:amap_search_fluttify_example/widgets/scrollable_text.widget.dart';
|
||||
import 'package:core_location_fluttify/core_location_fluttify.dart';
|
||||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class GetPoiScreen extends StatelessWidget {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('获取POI数据')),
|
||||
body: ListView(
|
||||
children: <Widget>[
|
||||
FunctionItem(
|
||||
label: '关键字检索POI',
|
||||
sublabel: 'KeywordPoiScreen',
|
||||
target: KeywordPoiScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '周边检索POI',
|
||||
sublabel: 'AroundPoiScreen',
|
||||
target: AroundPoiScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '输入提示',
|
||||
sublabel: 'InputTipScreen',
|
||||
target: InputTipScreen(),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/// 关键字检索POI
|
||||
class KeywordPoiScreen extends StatefulWidget {
|
||||
@override
|
||||
_KeywordPoiScreenState createState() => _KeywordPoiScreenState();
|
||||
}
|
||||
|
||||
class _KeywordPoiScreenState extends State<KeywordPoiScreen> {
|
||||
final _keywordController = TextEditingController(text: '肯德基');
|
||||
final _cityController = TextEditingController(text: '杭州');
|
||||
int _page = 1;
|
||||
|
||||
List<String> _poiTitleList = [];
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('关键字检索POI')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
TextFormField(
|
||||
controller: _keywordController,
|
||||
decoration: const InputDecoration(hintText: '输入关键字'),
|
||||
),
|
||||
TextFormField(
|
||||
controller: _cityController,
|
||||
decoration: const InputDecoration(hintText: '输入城市'),
|
||||
),
|
||||
ElevatedButton(
|
||||
onPressed: () async {
|
||||
final poiList = await AmapSearch.instance.searchKeyword(
|
||||
_keywordController.text,
|
||||
city: _cityController.text,
|
||||
);
|
||||
|
||||
setState(() {
|
||||
_poiTitleList = poiList.map((it) => it.toString()).toList();
|
||||
});
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
ElevatedButton(
|
||||
onPressed: () async {
|
||||
final poiList = await AmapSearch.instance.searchKeyword(
|
||||
_keywordController.text,
|
||||
city: _cityController.text,
|
||||
page: ++_page,
|
||||
);
|
||||
|
||||
setState(() {
|
||||
_poiTitleList = poiList.map((it) => it.toString()).toList();
|
||||
});
|
||||
},
|
||||
child: const Text('下一页'),
|
||||
),
|
||||
Expanded(child: ScrollableText(_poiTitleList.join("\n"))),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/// 附近检索POI
|
||||
class AroundPoiScreen extends StatefulWidget {
|
||||
@override
|
||||
_AroundPoiScreenState createState() => _AroundPoiScreenState();
|
||||
}
|
||||
|
||||
class _AroundPoiScreenState extends State<AroundPoiScreen> {
|
||||
final _keywordController = TextEditingController();
|
||||
final _typeController = TextEditingController();
|
||||
final _latController = TextEditingController(text: '29.08');
|
||||
final _lngController = TextEditingController(text: '119.65');
|
||||
int _page = 1;
|
||||
|
||||
List<String> _poiTitleList = [];
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('周边检索POI')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
TextFormField(
|
||||
controller: _keywordController,
|
||||
decoration: const InputDecoration(hintText: '输入关键字'),
|
||||
),
|
||||
TextFormField(
|
||||
controller: _typeController,
|
||||
decoration: const InputDecoration(hintText: '输入类别'),
|
||||
),
|
||||
DecoratedRow(
|
||||
children: <Widget>[
|
||||
Flexible(
|
||||
child: TextField(
|
||||
controller: _latController,
|
||||
decoration: const InputDecoration(hintText: '输入纬度'),
|
||||
),
|
||||
),
|
||||
SPACE_4_HORIZONTAL,
|
||||
Flexible(
|
||||
child: TextField(
|
||||
controller: _lngController,
|
||||
decoration: const InputDecoration(hintText: '输入经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final poiList = await AmapSearch.instance.searchAround(
|
||||
LatLng(
|
||||
double.tryParse(_latController.text) ?? 29.08,
|
||||
double.tryParse(_lngController.text) ?? 119.65,
|
||||
),
|
||||
keyword: _keywordController.text,
|
||||
type: _typeController.text,
|
||||
);
|
||||
|
||||
setState(() {
|
||||
_poiTitleList = poiList.map((it) => it.toString()).toList();
|
||||
});
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final poiList = await AmapSearch.instance.searchAround(
|
||||
LatLng(
|
||||
double.tryParse(_latController.text) ?? 29.08,
|
||||
double.tryParse(_lngController.text) ?? 119.65,
|
||||
),
|
||||
keyword: _keywordController.text,
|
||||
type: _typeController.text,
|
||||
page: ++_page,
|
||||
);
|
||||
|
||||
setState(() {
|
||||
_poiTitleList = poiList.map((it) => it.toString()).toList();
|
||||
});
|
||||
},
|
||||
child: const Text('下一页'),
|
||||
),
|
||||
Expanded(child: ScrollableText(_poiTitleList.join("\n"))),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/// 输入提示
|
||||
class InputTipScreen extends StatefulWidget {
|
||||
@override
|
||||
_InputTipScreenState createState() => _InputTipScreenState();
|
||||
}
|
||||
|
||||
class _InputTipScreenState extends State<InputTipScreen> {
|
||||
final _keywordController = TextEditingController(text: '肯德基');
|
||||
final _cityController = TextEditingController(text: '杭州');
|
||||
|
||||
List<InputTip> _inputTipList = [];
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('输入内容自动提示')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
TextFormField(
|
||||
controller: _keywordController,
|
||||
decoration: const InputDecoration(hintText: '输入关键字'),
|
||||
),
|
||||
TextFormField(
|
||||
controller: _cityController,
|
||||
decoration: const InputDecoration(hintText: '输入所在城市'),
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final inputTipList = await AmapSearch.instance.fetchInputTips(
|
||||
_keywordController.text,
|
||||
city: _cityController.text,
|
||||
);
|
||||
|
||||
setState(() => _inputTipList = inputTipList);
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
Expanded(child: ScrollableText(_inputTipList.join("\n"))),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,42 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
/// 获取天气数据
|
||||
class GetWeatherInfoScreen extends StatefulWidget {
|
||||
@override
|
||||
_GetWeatherInfoScreenState createState() => _GetWeatherInfoScreenState();
|
||||
}
|
||||
|
||||
class _GetWeatherInfoScreenState extends State<GetWeatherInfoScreen> {
|
||||
final _keywordController = TextEditingController(text: '杭州');
|
||||
|
||||
String _district = '';
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('获取天气数据')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
TextFormField(
|
||||
controller: _keywordController,
|
||||
decoration: const InputDecoration(hintText: '输入地区'),
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final district = await AmapSearch.instance
|
||||
.searchDistrict(_keywordController.text);
|
||||
_district = district.toString();
|
||||
setState(() {});
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
Expanded(child: SingleChildScrollView(child: Text(_district))),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,129 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import 'get_map_data/get_address_desc.screen.dart';
|
||||
import 'get_map_data/get_bus_info.screen.dart';
|
||||
import 'get_map_data/get_district_info.screen.dart';
|
||||
import 'get_map_data/get_poi.screen.dart';
|
||||
import 'get_map_data/get_weather_info.screen.dart';
|
||||
import 'route_plan/route_bus.screen.dart';
|
||||
import 'route_plan/route_drive.screen.dart';
|
||||
import 'route_plan/route_ride.screen.dart';
|
||||
import 'route_plan/route_walk.screen.dart';
|
||||
import 'widgets/function_group.widget.dart';
|
||||
import 'widgets/function_item.widget.dart';
|
||||
import 'widgets/todo.screen.dart';
|
||||
|
||||
void main() async {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
|
||||
await AmapSearch.instance.init('f583e0d5b70400167993615c3adc3ced');
|
||||
await AmapSearch.instance.updatePrivacyShow(true);
|
||||
await AmapSearch.instance.updatePrivacyAgree(true);
|
||||
|
||||
runApp(MyApp());
|
||||
}
|
||||
|
||||
class MyApp extends StatefulWidget {
|
||||
@override
|
||||
_MyAppState createState() => _MyAppState();
|
||||
}
|
||||
|
||||
class _MyAppState extends State<MyApp> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return const MaterialApp(home: Home());
|
||||
}
|
||||
}
|
||||
|
||||
class Home extends StatelessWidget {
|
||||
const Home({
|
||||
Key? key,
|
||||
}) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(title: const Text('AMaps examples')),
|
||||
body: ListView(
|
||||
children: <Widget>[
|
||||
FunctionGroup(
|
||||
headLabel: '获取地图数据',
|
||||
children: <Widget>[
|
||||
FunctionItem(
|
||||
label: '获取POI数据',
|
||||
sublabel: 'GetPoiScreen',
|
||||
target: GetPoiScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '获取地址描述数据',
|
||||
sublabel: 'GetAddressDescScreen',
|
||||
target: GetAddressDescScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '获取行政区划数据',
|
||||
sublabel: 'GetDistrictInfoScreen',
|
||||
target: GetDistrictInfoScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '获取公交数据',
|
||||
sublabel: 'GetBusInfoScreenScreen',
|
||||
target: GetBusInfoScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '后获取天气数据',
|
||||
sublabel: 'GetWeatherInfoScreen',
|
||||
target: GetWeatherInfoScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '获取业务数据(云图功能)',
|
||||
sublabel: 'TODO',
|
||||
target: TodoScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '获取交通态势信息',
|
||||
sublabel: 'TODO',
|
||||
target: TodoScreen(),
|
||||
),
|
||||
],
|
||||
),
|
||||
FunctionGroup(
|
||||
headLabel: '出行路线规划',
|
||||
children: <Widget>[
|
||||
FunctionItem(
|
||||
label: '驾车出行路线规划',
|
||||
sublabel: 'RouteDriveScreen',
|
||||
target: RouteDriveScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '步行出行路线规划',
|
||||
sublabel: 'RouteWalkScreen',
|
||||
target: RouteWalkScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '公交出行路线规划',
|
||||
sublabel: 'RouteBusScreen',
|
||||
target: RouteBusScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '骑行出行路线规划',
|
||||
sublabel: 'RouteRideScreen',
|
||||
target: RouteRideScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '货车出行路线规划',
|
||||
sublabel: 'TODO',
|
||||
target: TodoScreen(),
|
||||
),
|
||||
FunctionItem(
|
||||
label: '未来出行路线规划',
|
||||
sublabel: 'TODO',
|
||||
target: TodoScreen(),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,97 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:core_location_fluttify/core_location_fluttify.dart';
|
||||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
/// 公交路线规划
|
||||
class RouteBusScreen extends StatefulWidget {
|
||||
@override
|
||||
_RouteBusScreenState createState() => _RouteBusScreenState();
|
||||
}
|
||||
|
||||
class _RouteBusScreenState extends State<RouteBusScreen> {
|
||||
final _fromLatController = TextEditingController(text: '30.219933');
|
||||
final _fromLngController = TextEditingController(text: '120.023728');
|
||||
|
||||
final _toLatController = TextEditingController(text: '30.27065');
|
||||
final _toLngController = TextEditingController(text: '120.163117');
|
||||
|
||||
String _routeResult = '';
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('公交路线规划')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
DecoratedRow(
|
||||
itemSpacing: kSpace8,
|
||||
children: <Widget>[
|
||||
const Text('起点:'),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _fromLatController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入出发点纬度'),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _fromLngController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入出发点经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
DecoratedRow(
|
||||
itemSpacing: kSpace8,
|
||||
children: <Widget>[
|
||||
const Text('终点:'),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _toLatController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入终点纬度'),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _toLngController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入终点经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final routeResult = await AmapSearch.instance.searchBusRoute(
|
||||
from: LatLng(
|
||||
double.parse(_fromLatController.text),
|
||||
double.parse(_fromLngController.text),
|
||||
),
|
||||
to: LatLng(
|
||||
double.parse(_toLatController.text),
|
||||
double.parse(_toLngController.text),
|
||||
),
|
||||
city: '杭州',
|
||||
);
|
||||
routeResult
|
||||
.toFutureString()
|
||||
.then((it) => setState(() => _routeResult = it));
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
Expanded(
|
||||
child: SingleChildScrollView(
|
||||
child: Text(_routeResult),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,100 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:core_location_fluttify/core_location_fluttify.dart';
|
||||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
/// 驾车路线规划
|
||||
class RouteDriveScreen extends StatefulWidget {
|
||||
@override
|
||||
_RouteDriveScreenState createState() => _RouteDriveScreenState();
|
||||
}
|
||||
|
||||
class _RouteDriveScreenState extends State<RouteDriveScreen> {
|
||||
final _fromLatController = TextEditingController(text: '30.219933');
|
||||
final _fromLngController = TextEditingController(text: '120.023728');
|
||||
|
||||
final _toLatController = TextEditingController(text: '30.27065');
|
||||
final _toLngController = TextEditingController(text: '120.163117');
|
||||
|
||||
String _routeResult = '';
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('驾车路线规划')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
DecoratedRow(
|
||||
itemSpacing: kSpace8,
|
||||
children: <Widget>[
|
||||
const Text('起点:'),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _fromLatController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入出发点纬度'),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _fromLngController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入出发点经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
DecoratedRow(
|
||||
itemSpacing: kSpace8,
|
||||
children: <Widget>[
|
||||
const Text('终点:'),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _toLatController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入终点纬度'),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _toLngController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入终点经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
try {
|
||||
final routeResult = await AmapSearch.instance.searchDriveRoute(
|
||||
from: LatLng(
|
||||
double.parse(_fromLatController.text),
|
||||
double.parse(_fromLngController.text),
|
||||
),
|
||||
to: LatLng(
|
||||
double.parse(_toLatController.text),
|
||||
double.parse(_toLngController.text),
|
||||
),
|
||||
);
|
||||
routeResult
|
||||
.toFutureString()
|
||||
.then((it) => setState(() => _routeResult = it));
|
||||
} catch (e) {
|
||||
setState(() => _routeResult = e.toString());
|
||||
}
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
Expanded(
|
||||
child: SingleChildScrollView(
|
||||
child: Text(_routeResult),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,92 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:core_location_fluttify/core_location_fluttify.dart';
|
||||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
/// 骑行路线规划
|
||||
class RouteRideScreen extends StatefulWidget {
|
||||
@override
|
||||
_RouteRideScreenState createState() => _RouteRideScreenState();
|
||||
}
|
||||
|
||||
class _RouteRideScreenState extends State<RouteRideScreen> {
|
||||
final _fromLatController = TextEditingController(text: '30.219933');
|
||||
final _fromLngController = TextEditingController(text: '120.023728');
|
||||
|
||||
final _toLatController = TextEditingController(text: '30.27065');
|
||||
final _toLngController = TextEditingController(text: '120.163117');
|
||||
|
||||
String _routeResult = '';
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('骑行路线规划')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
DecoratedRow(
|
||||
itemSpacing: kSpace8,
|
||||
children: <Widget>[
|
||||
const Text('起点:'),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _fromLatController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入出发点纬度'),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _fromLngController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入出发点经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
DecoratedRow(
|
||||
itemSpacing: kSpace8,
|
||||
children: <Widget>[
|
||||
const Text('终点:'),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _toLatController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入终点纬度'),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _toLngController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入终点经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final routeResult = await AmapSearch.instance.searchRideRoute(
|
||||
from: LatLng(
|
||||
double.parse(_fromLatController.text),
|
||||
double.parse(_fromLngController.text),
|
||||
),
|
||||
to: LatLng(
|
||||
double.parse(_toLatController.text),
|
||||
double.parse(_toLngController.text),
|
||||
),
|
||||
);
|
||||
routeResult
|
||||
.toFutureString()
|
||||
.then((it) => setState(() => _routeResult = it));
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
Expanded(child: SingleChildScrollView(child: Text(_routeResult))),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,96 @@
|
|||
import 'package:amap_search_fluttify/amap_search_fluttify.dart';
|
||||
import 'package:core_location_fluttify/core_location_fluttify.dart';
|
||||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
/// 步行路线规划
|
||||
class RouteWalkScreen extends StatefulWidget {
|
||||
@override
|
||||
_RouteWalkScreenState createState() => _RouteWalkScreenState();
|
||||
}
|
||||
|
||||
class _RouteWalkScreenState extends State<RouteWalkScreen> {
|
||||
final _fromLatController = TextEditingController(text: '30.219933');
|
||||
final _fromLngController = TextEditingController(text: '120.023728');
|
||||
|
||||
final _toLatController = TextEditingController(text: '30.27065');
|
||||
final _toLngController = TextEditingController(text: '120.163117');
|
||||
|
||||
String _routeResult = '';
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
resizeToAvoidBottomInset: false,
|
||||
appBar: AppBar(title: const Text('步行路线规划')),
|
||||
body: DecoratedColumn(
|
||||
padding: const EdgeInsets.all(kSpace16),
|
||||
children: <Widget>[
|
||||
DecoratedRow(
|
||||
itemSpacing: kSpace8,
|
||||
children: <Widget>[
|
||||
const Text('起点:'),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _fromLatController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入出发点纬度'),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _fromLngController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入出发点经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
DecoratedRow(
|
||||
itemSpacing: kSpace8,
|
||||
children: <Widget>[
|
||||
const Text('终点:'),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _toLatController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入终点纬度'),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
child: TextFormField(
|
||||
controller: _toLngController,
|
||||
keyboardType: TextInputType.number,
|
||||
decoration: const InputDecoration(hintText: '输入终点经度'),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
RaisedButton(
|
||||
onPressed: () async {
|
||||
final routeResult = await AmapSearch.instance.searchWalkRoute(
|
||||
from: LatLng(
|
||||
double.parse(_fromLatController.text),
|
||||
double.parse(_fromLngController.text),
|
||||
),
|
||||
to: LatLng(
|
||||
double.parse(_toLatController.text),
|
||||
double.parse(_toLngController.text),
|
||||
),
|
||||
);
|
||||
routeResult
|
||||
.toFutureString()
|
||||
.then((it) => setState(() => _routeResult = it));
|
||||
},
|
||||
child: const Text('搜索'),
|
||||
),
|
||||
Expanded(
|
||||
child: SingleChildScrollView(
|
||||
child: Text(_routeResult),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
import 'package:decorated_flutter/decorated_flutter.dart';
|
||||
import 'package:permission_handler/permission_handler.dart';
|
||||
|
||||
Future<bool> requestPermission() async {
|
||||
final status = await Permission.location.request();
|
||||
|
||||
if (status == PermissionStatus.granted) {
|
||||
return true;
|
||||
} else {
|
||||
toast('需要定位权限!');
|
||||
return false;
|
||||
}
|
||||
}
|