75d24c15
yangbin
123
|
1
2
3
4
5
6
7
8
9
10
|
//
// AppDelegate.swift
// Twear
//
// Created by yangbin on 2021/11/16.
//
import UIKit
import SwiftDate
import IQKeyboardManagerSwift
|
f2cf74c7
yangbin
1.0.20(4)
|
11
|
import AVFoundation
|
75d24c15
yangbin
123
|
12
13
14
15
16
17
18
19
20
21
22
|
@main
class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
// Override point for customization after application launch.
window = UIWindow()
|
75d24c15
yangbin
123
|
23
24
25
26
27
28
29
30
31
32
|
IQKeyboardManager.shared.enable = true
IQKeyboardManager.shared.shouldResignOnTouchOutside = true
IQKeyboardManager.shared.enableAutoToolbar = false
SwiftDate.defaultRegion = .current
RealmTools.configRealm()
object_setClass(Foundation.Bundle.main, HDFBundle.self)
|
f2cf74c7
yangbin
1.0.20(4)
|
33
|
|
0afed06c
daifengyi
feat:recover config
|
34
|
if AdminHelper.shared.isFirstLaunch() {
|
f2cf74c7
yangbin
1.0.20(4)
|
35
36
|
window?.rootViewController = LaunchViewController()
window?.makeKeyAndVisible()
|
0afed06c
daifengyi
feat:recover config
|
37
38
39
40
|
} else {
window?.rootViewController = ZCTabBarController()
window?.makeKeyAndVisible()
}
|
f2cf74c7
yangbin
1.0.20(4)
|
41
|
|
75d24c15
yangbin
123
|
42
43
44
|
initSDK()
return true
}
|
f2cf74c7
yangbin
1.0.20(4)
|
45
46
47
48
49
|
func application(_ application: UIApplication, supportedInterfaceOrientationsFor window: UIWindow?) -> UIInterfaceOrientationMask {
return .portrait
}
|
75d24c15
yangbin
123
|
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
|
func initSDK() {
//天气QWeather.
AllWeatherInquieirs.sharedInstance().appKey = "9d50ca989b6e441aa5db78494479ed6e"
AllWeatherInquieirs.sharedInstance().publicID = "HE2112221638291473"
AllWeatherInquieirs.sharedInstance().appType = .DEV
//高德地图
AMapServices.shared().enableHTTPS = true
AMapServices.shared().apiKey = "2746712bd306b3543a263e93b6849d48"
//分享 注册平台
ShareSDK.registPlatforms { platformsRegister in
let universalLink = "4c4f12be4f7221d073786a1e98be5601.share2dlink.com"
platformsRegister?.setupWeChat(withAppId: "wx76c8e91b90baa0bb", appSecret: "fe2c51571b50519667c88db7fe6764cb", universalLink: "https://4c4f12be4f7221d073786a1e98be5601.share2dlink.com/")
platformsRegister?.setupQQ(withAppId: "101988383", appkey: "a268282dfeb77f59f5b81265fd5c575b", enableUniversalLink: true, universalLink: "https://4c4f12be4f7221d073786a1e98be5601.share2dlink.com/qq_conn/101988383")
platformsRegister?.setupSinaWeibo(withAppkey: "568898243", appSecret: "38a4f8204cc784f81f9f0daaf31e02e3", redirectUrl: nil, universalLink: universalLink)
|
582f536d
yangbin
common:2022.1.28
|
71
|
// platformsRegister?.setupTwitter(withKey: "LRBM0H75rWrU9gNHvlEAA2aOy", secret: "gbeWsZvA9ELJSdoBzJ5oLKX0TU09UOwrzdGfo9Tg7DjyGuMe8G", redirectUrl: "http://mob.com")
|
75d24c15
yangbin
123
|
72
73
74
|
platformsRegister?.setupInstagram(withClientId: "379235043053926", clientSecret: "581da6660ee4ede2873128ebd310d7e9", redirectUrl: nil)
|
f2cf74c7
yangbin
1.0.20(4)
|
75
|
platformsRegister?.setupFacebook(withAppkey: "656411005631251", appSecret: "2963cb646d3000b71a7fc2a4bef7a20e", displayName: "HDF wear")
|
75d24c15
yangbin
123
|
76
77
78
79
80
81
82
83
84
85
86
|
}
}
// MARK: UISceneSession Lifecycle
}
|