Release 4.8.0 - 2024-05-26

This commit is contained in:
2024-05-26 11:00:06 +09:00
parent 6a49aed98d
commit ae05a8bbcd
10 changed files with 170 additions and 162 deletions

View File

@ -1,8 +1,10 @@
import UIKit
import CoreLocation
import Flutter
@UIApplicationMain
@objc class AppDelegate: FlutterAppDelegate {
@objc class AppDelegate: FlutterAppDelegate, CLLocationManagerDelegate {
var locationManager: CLLocationManager?
override func application(
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
@ -12,6 +14,7 @@ import Flutter
let controller : FlutterViewController = window?.rootViewController as! FlutterViewController
let locationServiceChannel = FlutterMethodChannel(name: "location",
binaryMessenger: controller.binaryMessenger)
/*
locationServiceChannel.setMethodCallHandler { (call: FlutterMethodCall, result: @escaping FlutterResult) -> Void in
if call.method == "isLocationServiceRunning" {
result(self.isLocationServiceRunning())
@ -19,6 +22,18 @@ import Flutter
result(FlutterMethodNotImplemented)
}
}
*/
locationServiceChannel.setMethodCallHandler { [weak self] (call: FlutterMethodCall, result: @escaping FlutterResult) -> Void in
if call.method == "startLocationService" {
//self?.startLocationService()
result(nil)
} else if call.method == "isLocationServiceRunning" {
result(self?.isLocationServiceRunning() ?? false)
} else {
result(FlutterMethodNotImplemented)
}
}
locationManager = CLLocationManager()
locationManager?.delegate = self

View File

@ -24,8 +24,6 @@
<string>????</string>
<key>CFBundleVersion</key>
<string>$(FLUTTER_BUILD_NUMBER)</string>
<key>FLTEnableImpeller</key>
<false/>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>NSCameraUsageDescription</key>
@ -38,6 +36,8 @@
<string>このアプリはチェックポイントへのチェックインや走行履歴を記録するために、位置情報にアクセスします。</string>
<key>NSPhotoLibraryUsageDescription</key>
<string>撮影した写真はデバイスのアルバムに保存されます。これにより、不具合時の通過記録を安全に担保することができます。</string>
<key>NSMicrophoneUsageDescription</key>
<string>このアプリではカメラは使用しますが、マイクの使用は当面行いません。</string>
<key>UIApplicationSupportsIndirectInputEvents</key>
<true/>
<key>LSApplicationCategoryType</key>