[add] 3.0

This commit is contained in:
建喵 2022-09-04 00:46:35 +08:00
parent 1027cc8376
commit 5dce041429
4 changed files with 75 additions and 3 deletions

View File

@ -823,7 +823,7 @@
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
LIBRARY_SEARCH_PATHS = "$(SRCROOT)/../../cocos2d-x/external/ios/libs"; LIBRARY_SEARCH_PATHS = "$(SRCROOT)/../../cocos2d-x/external/ios/libs";
MARKETING_VERSION = 2.1; MARKETING_VERSION = 3.0;
OTHER_LDFLAGS = ( OTHER_LDFLAGS = (
"-ObjC", "-ObjC",
"$(inherited)", "$(inherited)",
@ -873,7 +873,7 @@
"@executable_path/Frameworks", "@executable_path/Frameworks",
); );
LIBRARY_SEARCH_PATHS = "$(SRCROOT)/../../cocos2d-x/external/ios/libs"; LIBRARY_SEARCH_PATHS = "$(SRCROOT)/../../cocos2d-x/external/ios/libs";
MARKETING_VERSION = 2.1; MARKETING_VERSION = 3.0;
OTHER_LDFLAGS = ( OTHER_LDFLAGS = (
"-ObjC", "-ObjC",
"$(inherited)", "$(inherited)",

View File

@ -7,7 +7,7 @@
<key>JMKA-desktop.xcscheme_^#shared#^_</key> <key>JMKA-desktop.xcscheme_^#shared#^_</key>
<dict> <dict>
<key>orderHint</key> <key>orderHint</key>
<integer>3</integer> <integer>1</integer>
</dict> </dict>
<key>JMKA-mobile.xcscheme_^#shared#^_</key> <key>JMKA-mobile.xcscheme_^#shared#^_</key>
<dict> <dict>

View File

@ -0,0 +1,72 @@
//
// Firebase_S.swift
// JMKA-mobile
//
// Created by JianMiau on 2022/8/26.
//
import UIKit
import Foundation
//import UserNotifications
//import Firebase
//class Firebase_S: NSObject, UNUserNotificationCenterDelegate, MessagingDelegate {
// @objc public func onLoad(_ application: UIApplication) {
// FirebaseApp.configure()
// Messaging.messaging().delegate = self
// if #available(iOS 10.0, *) {
// // For iOS 10 display notification (sent via APNS)
// UNUserNotificationCenter.current().delegate = self
//
// let authOptions: UNAuthorizationOptions = [.alert, .badge, .sound]
// UNUserNotificationCenter.current().requestAuthorization(
// options: authOptions,
// completionHandler: { _, _ in }
// )
// } else {
// let settings: UIUserNotificationSettings =
// UIUserNotificationSettings(types: [.alert, .badge, .sound], categories: nil)
// application.registerUserNotificationSettings(settings)
// }
//
// application.registerForRemoteNotifications()
// }
//
// @objc public func getFMTCoken() {
// Messaging.messaging().token { token, error in
// if let error = error {
// print("Error fetching FCM registration token: \(error)")
// } else if let token = token {
// print("FCM registration token: \(token)")
// // self.fcmRegTokenMessage.text = "Remote FCM registration token: \(token)"
// }
// }
// }
//}
//extension Firebase_S: MessagingDelegate {
//
// func messaging(_ messaging: Messaging, didReceiveRegistrationToken fcmToken: String?) {
// print("fcm Token", fcmToken ?? "")
// // fcm token
// }
//}
//extension Firebase_S: UNUserNotificationCenterDelegate {
// // 使
// func userNotificationCenter(_ center: UNUserNotificationCenter, didReceive response: UNNotificationResponse, withCompletionHandler completionHandler: @escaping () -> Void) {
// print(#function)
// let content = response.notification.request.content
// print(content.userInfo)
// completionHandler()
// }
//
// // App
// func userNotificationCenter(_ center: UNUserNotificationCenter, willPresent notification: UNNotification, withCompletionHandler completionHandler: @escaping (UNNotificationPresentationOptions) -> Void) {
// if #available(iOS 14.0, *) {
// completionHandler([.banner])
// } else {
// // Fallback on earlier versions
// }
// }
//}