Commit e940266c by pierce

qq登录接入

parent bd821e8b
Showing with 191 additions and 146 deletions
......@@ -256,9 +256,9 @@ public struct GDSDK {
public static let gd_wechatUniversalLink = "https://yabolive.com/qiezi/"
/// QQ Appid
public static let gd_QQAppId = "1110627651"
public static let gd_QQAppId = "102105469"
/// QQ key
public static let gd_QQAppKey = "xF0T9ElsZgDoC6N0"
public static let gd_QQAppKey = "a5NUO4VihRxEG3f4"
//
// /// 字节推拉流SDK AppID
// public static let gd_byteDanceAppID = "201548"
......
......@@ -104,7 +104,7 @@ class GDAddNewAccountController: BaseViewController {
let otherDescLabel = UILabel()
/// 第三方登录按钮
let qqBtn = UIButton(type: .system)
let wechatBtn = UIButton(type: .system)
// let wechatBtn = UIButton(type: .system)
let appleBtn = UIButton(type: .system)
private func makePhoneTextInputView() {
......@@ -299,9 +299,9 @@ class GDAddNewAccountController: BaseViewController {
qqBtn.setImage(qqBtnImage, for: .normal)
self.view.addSubview(qqBtn)
let wechatBtnImage = GDPersonalBundle.imageNamed("share_invite_wechat_icon")?.withRenderingMode(.alwaysOriginal)
wechatBtn.setImage(wechatBtnImage, for: .normal)
self.view.addSubview(wechatBtn)
// let wechatBtnImage = GDPersonalBundle.imageNamed("share_invite_wechat_icon")?.withRenderingMode(.alwaysOriginal)
// wechatBtn.setImage(wechatBtnImage, for: .normal)
// self.view.addSubview(wechatBtn)
let appleBtnImage = GDPersonalBundle.imageNamed("share_invite_apple_icon")?.withRenderingMode(.alwaysOriginal)
appleBtn.setImage(appleBtnImage, for: .normal)
......@@ -351,35 +351,54 @@ class GDAddNewAccountController: BaseViewController {
}
if #available(iOS 13.0, *) {
wechatBtn.snp.makeConstraints { (make) in
make.size.equalTo(50)
make.right.equalTo(qqBtn.snp.left).offset(-20)
make.bottom.equalTo(qqBtn)
}
// wechatBtn.snp.makeConstraints { (make) in
// make.size.equalTo(50)
// make.right.equalTo(qqBtn.snp.left).offset(-20)
// make.bottom.equalTo(qqBtn)
// }
//
// qqBtn.snp.makeConstraints { (make) in
// make.size.equalTo(50)
// make.centerX.equalToSuperview()
// make.bottom.equalTo(userAgreementTitleBtn.snp.top).offset(-30)
// }
//
// appleBtn.snp.makeConstraints { (make) in
// make.size.equalTo(50)
// make.left.equalTo(qqBtn.snp.right).offset(20)
// make.bottom.equalTo(qqBtn)
// }
qqBtn.snp.makeConstraints { (make) in
make.size.equalTo(50)
make.centerX.equalToSuperview()
make.centerX.equalToSuperview().offset(-60)
make.bottom.equalTo(userAgreementTitleBtn.snp.top).offset(-30)
}
appleBtn.snp.makeConstraints { (make) in
make.size.equalTo(50)
make.left.equalTo(qqBtn.snp.right).offset(20)
make.centerX.equalToSuperview().offset(60)
make.bottom.equalTo(qqBtn)
}
} else {
appleBtn.isHidden = true
wechatBtn.snp.makeConstraints { (make) in
make.size.equalTo(50)
make.centerX.equalToSuperview().offset(-60)
make.bottom.equalTo(qqBtn)
}
// wechatBtn.snp.makeConstraints { (make) in
// make.size.equalTo(50)
// make.centerX.equalToSuperview().offset(-60)
// make.bottom.equalTo(qqBtn)
// }
//
// qqBtn.snp.makeConstraints { (make) in
// make.size.equalTo(50)
// make.centerX.equalToSuperview().offset(60)
// make.bottom.equalTo(userAgreementTitleBtn.snp.top).offset(-30)
// }
qqBtn.snp.makeConstraints { (make) in
make.size.equalTo(50)
make.centerX.equalToSuperview().offset(60)
make.centerX.equalToSuperview()
make.bottom.equalTo(userAgreementTitleBtn.snp.top).offset(-30)
}
}
......@@ -467,10 +486,10 @@ class GDAddNewAccountController: BaseViewController {
}
}).disposed(by: disposeBag)
wechatBtn.rx.tap.subscribe(onNext: {[weak self] (_) in
guard let self = self else { return }
self.socialLogin(with: .wechat)
}).disposed(by: disposeBag)
// wechatBtn.rx.tap.subscribe(onNext: {[weak self] (_) in
// guard let self = self else { return }
// self.socialLogin(with: .wechat)
// }).disposed(by: disposeBag)
qqBtn.rx.tap.subscribe(onNext: {[weak self] _ in
guard let self = self else { return }
......
{
"images": [
{
"idiom": "universal",
"scale": "1x"
},
{
"filename": "share_invite_apple_icon.png",
"idiom": "universal",
"scale": "2x"
},
{
"idiom": "universal",
"scale": "3x"
}
],
"info": {
"author": "xcode",
"version": 1
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "share_invite_apple_icon.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
}
\ No newline at end of file
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images": [
{
"idiom": "universal",
"scale": "1x"
},
{
"filename": "share_invite_bg.png",
"idiom": "universal",
"scale": "2x"
},
{
"idiom": "universal",
"scale": "3x"
}
],
"info": {
"author": "xcode",
"version": 1
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "share_invite_bg.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
}
\ No newline at end of file
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images": [
{
"idiom": "universal",
"scale": "1x"
},
{
"filename": "share_invite_circle_icon.png",
"idiom": "universal",
"scale": "2x"
},
{
"idiom": "universal",
"scale": "3x"
}
],
"info": {
"author": "xcode",
"version": 1
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "share_invite_circle_icon.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
}
\ No newline at end of file
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images": [
{
"idiom": "universal",
"scale": "1x"
},
{
"filename": "share_invite_qq_icon.png",
"idiom": "universal",
"scale": "2x"
},
{
"idiom": "universal",
"scale": "3x"
}
],
"info": {
"author": "xcode",
"version": 1
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "share_invite_qq_icon.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
}
\ No newline at end of file
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images": [
{
"idiom": "universal",
"scale": "1x"
},
{
"filename": "share_invite_qrcode_icon.png",
"idiom": "universal",
"scale": "2x"
},
{
"idiom": "universal",
"scale": "3x"
}
],
"info": {
"author": "xcode",
"version": 1
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "share_invite_qrcode_icon.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
}
\ No newline at end of file
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images": [
{
"idiom": "universal",
"scale": "1x"
},
{
"filename": "share_invite_wechat_icon.png",
"idiom": "universal",
"scale": "2x"
},
{
"idiom": "universal",
"scale": "3x"
}
],
"info": {
"author": "xcode",
"version": 1
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "share_invite_wechat_icon.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
}
\ No newline at end of file
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
......@@ -566,6 +566,7 @@ struct GDPlat {
}
static func setup(with delegate: TencentSessionDelegate) -> TencentOAuth? {
TencentOAuth.setIsUserAgreedAuthorization(true)
return TencentOAuth(appId: GDSDK.gd_QQAppId, andDelegate: delegate)
}
......
......@@ -38,7 +38,6 @@ struct GDTeenagerSocketCID {
let teenagerView = GDTeenagerModePopupView()
teenagerView.currentVC = UIViewController.topViewController()
teenagerView.show(on: view)
}
}
}
......
......@@ -2,6 +2,37 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleTypeRole</key>
<string>Editor</string>
<key>CFBundleURLSchemes</key>
<array>
<string>xiusechat</string>
</array>
</dict>
<dict>
<key>CFBundleTypeRole</key>
<string>Editor</string>
<key>CFBundleURLName</key>
<string>tencent</string>
<key>CFBundleURLSchemes</key>
<array>
<string>tencent102105469</string>
</array>
</dict>
<dict>
<key>CFBundleTypeRole</key>
<string>Editor</string>
<key>CFBundleURLName</key>
<string>qq</string>
<key>CFBundleURLSchemes</key>
<array>
<string>QQ0616017D</string>
</array>
</dict>
</array>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>NSAllowsArbitraryLoads</key>
......
......@@ -7,6 +7,7 @@
<key>com.apple.developer.associated-domains</key>
<array>
<string>applinks:xs.cxylive.top/xiusechat/</string>
<string>applinks:xs.cxylive.top/qq_conn/102105469/</string>
</array>
</dict>
</plist>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment