Ver código fonte

[feat]完成ios键盘1.0版本开发

Destiny 6 meses atrás
pai
commit
fe2ea1d04a

+ 3 - 1
ios/AiKeyboard/Info.plist

@@ -2,6 +2,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>ITSAppUsesNonExemptEncryption</key>
+	<false/>
 	<key>LSApplicationQueriesSchemes</key>
 	<array>
 		<string>com.qihuan.zhuiaijianpan</string>
@@ -37,7 +39,7 @@
 	</dict>
 	<key>UIAppFonts</key>
 	<array>
-		<string>淘宝买菜体.ttf</string>
+		<string>tbmct.ttf</string>
 	</array>
 </dict>
 </plist>

+ 1 - 1
ios/Podfile.lock

@@ -232,4 +232,4 @@ SPEC CHECKSUMS:
 
 PODFILE CHECKSUM: 46e41cd7a608d3db06d8570d6fb41a774efc4103
 
-COCOAPODS: 1.15.2
+COCOAPODS: 1.16.2

+ 3 - 0
ios/Runner.xcodeproj/project.pbxproj

@@ -372,6 +372,7 @@
 		97C146E51CF9000F007C117D = {
 			isa = PBXGroup;
 			children = (
+				FED899752DD1F5D5001808D5 /* tbmct.ttf */,
 				043D62362DCB0E7A005D12EE /* KeyboardSharedDataManager.swift */,
 				9740EEB11CF90186004384FC /* Flutter */,
 				97C146F01CF9000F007C117D /* Runner */,
@@ -530,6 +531,7 @@
 				04582A512DC211F100C1792D /* keyboard_dialog_loading.json in Resources */,
 				04582A322DBF6C0800C1792D /* heart.json in Resources */,
 				045828C92DB89ABE00C1792D /* Media.xcassets in Resources */,
+				FED899772DD1F5D5001808D5 /* tbmct.ttf in Resources */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 		};
@@ -549,6 +551,7 @@
 				FE05FA2E2DCE0CFC00CBA944 /* Settings.bundle in Resources */,
 				97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
 				97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
+				FED899762DD1F5D5001808D5 /* tbmct.ttf in Resources */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 		};

ios/AiKeyboard/淘宝买菜体.ttf → ios/tbmct.ttf


+ 0 - 36
lib/data/repository/account_repository.dart

@@ -255,42 +255,6 @@ class AccountRepository {
     });
   }
 
-  // 保存token到ios端
-  Future<void> saveAuthToken(String token) async {
-    // 通知iOS键盘扩展
-    if (Platform.isIOS) {
-      const MethodChannel channel = MethodChannel('keyboard_ios');
-      channel.invokeMethod('saveAuthToken', {'token': token});
-    }
-  }
-
-  // 保存token到ios端
-  Future<void> clearAuthToken() async {
-    // 通知iOS键盘扩展
-    if (Platform.isIOS) {
-      const MethodChannel channel = MethodChannel('keyboard_ios');
-      channel.invokeMethod('clearAuthToken');
-    }
-  }
-
-  // 保存token到ios端
-  Future<void> saveAuthToken(String token) async {
-    // 通知iOS键盘扩展
-    if (Platform.isIOS) {
-      const MethodChannel channel = MethodChannel('keyboard_ios');
-      channel.invokeMethod('saveAuthToken', {'token': token});
-    }
-  }
-
-  // 保存token到ios端
-  Future<void> clearAuthToken() async {
-    // 通知iOS键盘扩展
-    if (Platform.isIOS) {
-      const MethodChannel channel = MethodChannel('keyboard_ios');
-      channel.invokeMethod('clearAuthToken');
-    }
-  }
-
   // 意见反馈
   Future<void> complaintSubmit(String? phone, String content) {
     return atmobApi

+ 0 - 32
lib/utils/navitigation_handler.dart

@@ -1,32 +0,0 @@
-import 'package:flutter/services.dart';
-import 'package:get/get.dart';
-import 'package:keyboard/module/login/login_page.dart';
-import 'package:keyboard/module/store/store_page.dart';
-
-class NavigationHandler {
-  static final NavigationHandler _instance = NavigationHandler._internal();
-  factory NavigationHandler() => _instance;
-  NavigationHandler._internal();
-
-  static const MethodChannel _channel = MethodChannel('keyboard_ios');
-
-  static void initialize() {
-    _channel.setMethodCallHandler(_handleMethod);
-  }
-
-  static Future<dynamic> _handleMethod(MethodCall call) async {
-    switch (call.method) {
-      case 'navigateToLogin':
-        LoginPage.start();
-        break;
-      case 'navigateToMember':
-        StorePage.start();
-        break;
-      default:
-        throw PlatformException(
-          code: 'Unimplemented',
-          details: '未实现的方法: ${call.method}',
-        );
-    }
-  }
-}