Commit db860983 authored by pete谢兆麟's avatar pete谢兆麟

邀请有礼

parent 0c5ea4a2
......@@ -294,4 +294,4 @@ DEPENDENCIES
fastlane-plugin-versioning
BUNDLED WITH
2.5.9
2.5.14
......@@ -41,7 +41,7 @@ platform :ios do
# 显示git当前分支最新submit id
sh "git rev-parse HEAD"
# 更新pod第三方库
# cocoapods(use_bundle_exec: true)
cocoapods(use_bundle_exec: true)
# 先清空打包路径下的文件
sh "pwd"
......
......@@ -275,6 +275,9 @@
0477E17C2BA4238400436346 /* YHCertificateListContainerVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0477E17B2BA4238400436346 /* YHCertificateListContainerVC.swift */; };
0477E17E2BA4362A00436346 /* YHCustomNavigationBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0477E17D2BA4362A00436346 /* YHCustomNavigationBar.swift */; };
047A3DF52C295AFF0048937B /* YHFriendListModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 047A3DF42C295AFF0048937B /* YHFriendListModel.swift */; };
047AA3D52C4A3643009C4554 /* YHInvitationWithGiftsDetailView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 047AA3D42C4A3643009C4554 /* YHInvitationWithGiftsDetailView.swift */; };
047AA3D72C4A4399009C4554 /* YHInvitationWithGiftsShareView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 047AA3D62C4A4399009C4554 /* YHInvitationWithGiftsShareView.swift */; };
047AA3D92C4A4A91009C4554 /* YHInvatationShareViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 047AA3D82C4A4A91009C4554 /* YHInvatationShareViewController.swift */; };
0480976B2BA15269000B9DCA /* YHCertificateInfoCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0480976A2BA15269000B9DCA /* YHCertificateInfoCell.swift */; };
0480976D2BA158A1000B9DCA /* YHCertificateListVC.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0480976C2BA158A1000B9DCA /* YHCertificateListVC.swift */; };
048097712BA18D66000B9DCA /* YHCertificateSearchBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = 048097702BA18D66000B9DCA /* YHCertificateSearchBar.swift */; };
......@@ -876,6 +879,9 @@
0477E17B2BA4238400436346 /* YHCertificateListContainerVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCertificateListContainerVC.swift; sourceTree = "<group>"; };
0477E17D2BA4362A00436346 /* YHCustomNavigationBar.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCustomNavigationBar.swift; sourceTree = "<group>"; };
047A3DF42C295AFF0048937B /* YHFriendListModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHFriendListModel.swift; sourceTree = "<group>"; };
047AA3D42C4A3643009C4554 /* YHInvitationWithGiftsDetailView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHInvitationWithGiftsDetailView.swift; sourceTree = "<group>"; };
047AA3D62C4A4399009C4554 /* YHInvitationWithGiftsShareView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHInvitationWithGiftsShareView.swift; sourceTree = "<group>"; };
047AA3D82C4A4A91009C4554 /* YHInvatationShareViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHInvatationShareViewController.swift; sourceTree = "<group>"; };
0480976A2BA15269000B9DCA /* YHCertificateInfoCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCertificateInfoCell.swift; sourceTree = "<group>"; };
0480976C2BA158A1000B9DCA /* YHCertificateListVC.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCertificateListVC.swift; sourceTree = "<group>"; };
048097702BA18D66000B9DCA /* YHCertificateSearchBar.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = YHCertificateSearchBar.swift; sourceTree = "<group>"; };
......@@ -1292,6 +1298,7 @@
isa = PBXGroup;
children = (
0419A0992C48F87B00A5FCFA /* YHInvitationWithGiftsViewController.swift */,
047AA3D82C4A4A91009C4554 /* YHInvatationShareViewController.swift */,
);
path = C;
sourceTree = "<group>";
......@@ -1311,6 +1318,8 @@
0419A09F2C48FC7D00A5FCFA /* YHInvitationWithGiftsSecondTableViewCell.swift */,
0419A0A12C49099A00A5FCFA /* YHInvitationWithGiftsShareBottomView.swift */,
0419A0A32C49184300A5FCFA /* YHInvitationNumberItemView.swift */,
047AA3D42C4A3643009C4554 /* YHInvitationWithGiftsDetailView.swift */,
047AA3D62C4A4399009C4554 /* YHInvitationWithGiftsShareView.swift */,
);
path = V;
sourceTree = "<group>";
......@@ -3359,6 +3368,7 @@
A582B2452BBA4CF9009D098C /* YHHKPlanDocModel.swift in Sources */,
045EEF142B9F171A0022A143 /* YHItemModel.swift in Sources */,
045EEED72B9F171A0022A143 /* YHEducationInfo.swift in Sources */,
047AA3D92C4A4A91009C4554 /* YHInvatationShareViewController.swift in Sources */,
045EEEDE2B9F171A0022A143 /* YHEducationInfoCell.swift in Sources */,
A5ACE93A2B4564F7002C94D2 /* NSAttributedString+Extension.swift in Sources */,
04E86E662B86EB6F00A35F4B /* YHLoginManager.swift in Sources */,
......@@ -3589,6 +3599,7 @@
A567E5A32BD7643D00D5D5A0 /* YHHomeBannerView.swift in Sources */,
A5ACE9402B4564F7002C94D2 /* String+Extension.swift in Sources */,
045EEEE42B9F171A0022A143 /* YHMySignatureDetailModel.swift in Sources */,
047AA3D72C4A4399009C4554 /* YHInvitationWithGiftsShareView.swift in Sources */,
A58A8C8F2BA6978100632765 /* YHMineCertificateEntryViewController.swift in Sources */,
045EEF1B2B9F171A0022A143 /* YHAddressPickViewTableViewCell.swift in Sources */,
04213B2F2C49154900797900 /* YHHomeInfoDetailContainerViewController.swift in Sources */,
......@@ -3697,6 +3708,7 @@
044D0C022C216AAF00C5CF5E /* YHInformationAuthorizeViewModel.swift in Sources */,
A5ACE9572B4564F7002C94D2 /* YHBasicContentView.swift in Sources */,
A59B43CB2C4A151200B28379 /* YHStatusAdvantageVC.swift in Sources */,
047AA3D52C4A3643009C4554 /* YHInvitationWithGiftsDetailView.swift in Sources */,
A5DF3D462BF72BA1003D5F03 /* YHTestViewController.swift in Sources */,
A566A79C2C227C9B00980D06 /* YHOrderTipsItemView.swift in Sources */,
A517A4E52BB6C4BB000DEECD /* YHDocumentFileItemView.swift in Sources */,
......
//
// YHInvatationShareViewController.swift
// galaxy
//
// Created by EDY on 2024/7/19.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
import CoreImage
import Vision
import Photos
class YHInvatationShareViewController: YHBaseViewController {
var centerImageView: UIImageView!
var imageView: UIImageView!
var bottomView: UIView!
var leftButton: YHShareButton!
var centerButton: YHShareButton!
var rightButton: YHShareButton!
override func viewDidLoad() {
super.viewDidLoad()
setView()
loadData()
}
}
extension YHInvatationShareViewController {
func getData() {
}
func updateDataSource() {
}
func setView() {
view.backgroundColor = .contentBkgColor
gk_navTitle = "分享活动"
centerImageView = {
let view = UIImageView()
view.image = UIImage(named: "invitation_with_gifts_share_detail")
return view
}()
view.addSubview(centerImageView)
centerImageView.snp.makeConstraints { make in
make.center.equalToSuperview()
make.height.equalTo(480)
make.width.equalTo(270)
}
imageView = {
let view = UIImageView()
view.image = UIImage(named: "invitation_with_gifts_share_detail")
return view
}()
centerImageView.addSubview(imageView)
imageView.snp.makeConstraints { make in
make.bottom.equalTo(-36)
make.right.equalTo(-22)
make.width.height.equalTo(56)
}
bottomView = {
let view = UIView()
view.backgroundColor = .white
return view
}()
view.addSubview(bottomView)
bottomView.snp.makeConstraints { make in
make.bottom.left.right.equalToSuperview()
make.height.equalTo(148)
}
leftButton = {
let button = YHShareButton()
button.setContent("invitation_with_gifts_share_left", "保存海报")
button.addTarget(self, action: #selector(saveBtnClick), for: .touchUpInside)
return button
}()
bottomView.addSubview(leftButton)
leftButton.snp.makeConstraints { make in
make.top.equalTo(20)
make.left.equalTo(42)
make.height.equalTo(74)
make.width.equalTo(52)
}
centerButton = {
let button = YHShareButton()
button.setContent("invitation_with_gifts_share_center", "微信好友")
button.addTarget(self, action: #selector(wxClick), for: .touchUpInside)
return button
}()
bottomView.addSubview(centerButton)
centerButton.snp.makeConstraints { make in
make.top.equalTo(20)
make.centerX.equalToSuperview()
make.height.equalTo(74)
make.width.equalTo(52)
}
rightButton = {
let button = YHShareButton()
button.setContent("invitation_with_gifts_share_right", "朋友圈")
button.addTarget(self, action: #selector(peopleClick), for: .touchUpInside)
return button
}()
bottomView.addSubview(rightButton)
rightButton.snp.makeConstraints { make in
make.top.equalTo(20)
make.right.equalTo(-42)
make.height.equalTo(74)
make.width.equalTo(52)
}
}
func loadData() {
if let qrCode = generateQRCode(from: "https://www.baidu.com") {
// 可以将qrCode设置为UIImageView的image属性来显示二维码
imageView.image = qrCode
}
}
@objc func saveBtnClick() {
guard let combinedImage = combinedImageFrom(imageView: centerImageView) else { return }
saveImageToPhotosAlbum(image: combinedImage)
}
func saveImageToPhotosAlbum(image: UIImage) {
// 确保应用有权访问相册
PHPhotoLibrary.requestAuthorization { status in
if status == .authorized {
// 保存图片到相册
UIImageWriteToSavedPhotosAlbum(image, nil, nil, nil)
DispatchQueue.main.async {
YHHUD.flash(message: "保存成功")
}
}
}
}
@objc func wxClick() {
guard let combinedImage = combinedImageFrom(imageView: centerImageView) else { return }
YHShareManager.shared.sendImageContent(combinedImage)
}
@objc func peopleClick() {
guard let combinedImage = combinedImageFrom(imageView: centerImageView) else { return }
YHShareManager.shared.sendImageContent(combinedImage, WXSceneTimeline)
}
func generateQRCode(from string: String) -> UIImage? {
guard let data = string.data(using: .ascii, allowLossyConversion: false) else {
return nil
}
let filter = CIFilter(name: "CIQRCodeGenerator")
filter?.setValue(data, forKey: "inputMessage")
guard let outputImage = filter?.outputImage else {
return nil
}
let context = CIContext()
if let cgImage = context.createCGImage(outputImage, from: outputImage.extent) {
return UIImage(cgImage: cgImage)
}
return nil
}
func combinedImageFrom(imageView: UIImageView) -> UIImage? {
UIGraphicsBeginImageContextWithOptions(imageView.bounds.size, false, 0.0)
// 首先绘制 imageView 的内容
imageView.layer.render(in: UIGraphicsGetCurrentContext()!)
// 获取合成后的图像
let combinedImage = UIGraphicsGetImageFromCurrentImageContext()
// 结束绘图上下文
UIGraphicsEndImageContext()
return combinedImage
}
}
......@@ -79,6 +79,11 @@ extension YHInvitationWithGiftsViewController {
func setView() {
view.backgroundColor = .contentBkgColor
let rightButtonItem = UIBarButtonItem(title: "规则", style: .plain, target: self, action: #selector(lookDeatil))
rightButtonItem.setTitleTextAttributes([.foregroundColor: UIColor.mainTextColor], for: .normal)
rightButtonItem.setTitleTextAttributes([.foregroundColor: UIColor.mainTextColor], for: .highlighted)
gk_navRightBarButtonItem = rightButtonItem
gk_navItemRightSpace = 16
tableView = {
let tableView = UITableView(frame: .zero, style: .grouped)
tableView.contentInsetAdjustmentBehavior = .never
......@@ -102,6 +107,15 @@ extension YHInvitationWithGiftsViewController {
bottomViewForShare = {
let view = YHInvitationWithGiftsShareBottomView()
view.block = { tag in
let view = YHInvitationWithGiftsShareView(frame: CGRect(x: 0, y: 0, width: KScreenWidth, height: KScreenHeight))
view.block = { tag in
let vc = YHInvatationShareViewController()
self.navigationController?.pushViewController(vc)
}
let window = UIApplication.shared.yhKeyWindow()
window?.addSubview(view)
}
return view
}()
view.addSubview(bottomViewForShare)
......@@ -111,6 +125,11 @@ extension YHInvitationWithGiftsViewController {
}
}
@objc func lookDeatil() {
let view = YHInvitationWithGiftsDetailView(frame: CGRect(x: 0, y: 0, width: KScreenWidth, height: KScreenHeight))
let window = UIApplication.shared.yhKeyWindow()
window?.addSubview(view)
}
func loadData() {
......
//
// YHInvitationWithGiftsDetailView.swift
// galaxy
//
// Created by EDY on 2024/7/19.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHInvitationWithGiftsDetailView: UIView {
var centerView: UIView!
var topView: UIView!
var topContentView: UIView!
var topImageView: UIImageView!
var bgImageView: UIImageView!
var scrollView: UIScrollView!
var titleLabel: UILabel!
var titleImage: UIImageView!
var closeButton: UIButton!
var messageLabel: UILabel!
var messageImage: UIImageView!
override init(frame: CGRect) {
super.init(frame: frame)
backgroundColor = UIColor(white: 0.5, alpha: 0.1)
// let tap = UITapGestureRecognizer(target: self, action: #selector(handleTap))
// tap.delegate = self
// addGestureRecognizer(tap)
setView()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setView() {
backgroundColor = UIColor(hex: 0x000000, alpha: 0.5)
centerView = {
let view = UIView()
view.backgroundColor = .clear
return view
}()
addSubview(centerView)
centerView.snp.makeConstraints { make in
make.center.equalToSuperview()
make.height.equalTo(562)
make.width.equalTo(311)
}
topView = {
let view = UIView()
view.backgroundColor = .clear
return view
}()
centerView.addSubview(topView)
topView.snp.makeConstraints { make in
make.top.left.right.equalToSuperview()
make.height.equalTo(518)
}
topContentView = {
let view = UIView()
view.backgroundColor = .white
view.layer.cornerRadius = kCornerRadius6
return view
}()
topView.addSubview(topContentView)
topContentView.snp.makeConstraints { make in
make.top.equalTo(6)
make.left.right.bottom.equalToSuperview()
}
topImageView = {
let imageView = UIImageView()
imageView.image = UIImage(named: "invitation_with_gifts_detail_top")
return imageView
}()
topView.addSubview(topImageView)
topImageView.snp.makeConstraints { make in
make.width.equalTo(157)
make.centerX.equalToSuperview()
make.height.equalTo(37)
make.top.equalToSuperview()
}
scrollView = {
let view = UIScrollView()
view.bounds = CGRect(x: 0, y: 0, width: 287, height: 1252)
// 去除弹簧效果
view.bounces = false
// 去除滑动指示器
view.showsHorizontalScrollIndicator = false
view.showsVerticalScrollIndicator = false
return view
}()
topContentView.addSubview(scrollView)
scrollView.snp.makeConstraints { make in
make.right.bottom.equalTo(-12)
make.top.left.equalTo(12)
}
bgImageView = {
let imageView = UIImageView()
imageView.image = UIImage(named: "invitation_with_gifts_detail_bg")
return imageView
}()
scrollView.addSubview(bgImageView)
bgImageView.snp.makeConstraints { make in
make.right.bottom.left.top.equalToSuperview()
}
titleLabel = {
let label = UILabel()
label.text = "规则说明"
label.font = UIFont.PFSC_M(ofSize: 15)
label.textColor = UIColor.mainTextColor
return label
}()
scrollView.addSubview(titleLabel)
titleLabel.snp.makeConstraints { make in
make.left.equalTo(14)
make.right.equalTo(-14)
make.height.equalTo(21)
make.top.equalTo(38)
}
titleImage = {
let imageView = UIImageView()
imageView.image = UIImage(named: "invitation_with_gifts_detail_title")
return imageView
}()
scrollView.addSubview(titleImage)
titleImage.snp.makeConstraints { make in
make.width.equalTo(259)
make.centerX.equalToSuperview()
make.height.equalTo(681)
make.top.equalTo(71)
}
messageLabel = {
let label = UILabel()
label.text = "积分入账及提现"
label.font = UIFont.PFSC_M(ofSize: 15)
label.textColor = UIColor.mainTextColor
return label
}()
scrollView.addSubview(messageLabel)
messageLabel.snp.makeConstraints { make in
make.left.equalTo(14)
make.right.equalTo(-14)
make.height.equalTo(21)
make.top.equalTo(782)
}
messageImage = {
let imageView = UIImageView()
imageView.image = UIImage(named: "invitation_with_gifts_detail_message")
return imageView
}()
scrollView.addSubview(messageImage)
messageImage.snp.makeConstraints { make in
make.width.equalTo(259)
make.centerX.equalToSuperview()
make.height.equalTo(426)
make.top.equalTo(814)
}
closeButton = {
let button = UIButton(type: .custom)
button.setBackgroundImage(UIImage(named: "invitation_with_gifts_detail_close"), for: .normal)
button.addTarget(self, action: #selector(dismiss), for: .touchUpInside)
return button
}()
centerView.addSubview(closeButton)
closeButton.snp.makeConstraints { make in
make.centerX.equalToSuperview()
make.width.height.equalTo(24)
make.bottom.equalToSuperview()
}
}
@objc private func handleTap(_ sender: AnyObject?) {
print("处理点击手势")
dismiss()
}
@objc func dismiss() {
removeFromSuperview()
}
}
extension YHInvitationWithGiftsDetailView: UIGestureRecognizerDelegate {
func gestureRecognizer(_ gestureRecognizer:UIGestureRecognizer, shouldReceive touch:UITouch) -> Bool {
if touch.view == self {
return true
}
return false
}
}
//
// YHInvitationWithGiftsShareView.swift
// galaxy
//
// Created by EDY on 2024/7/19.
// Copyright © 2024 https://www.galaxy-immi.com. All rights reserved.
//
import UIKit
class YHInvitationWithGiftsShareView: UIView {
typealias Block = (Int) -> ()
var block: Block?
var centerView: UIView!
var topImageView: UIImageView!
var bgImageView: UIImageView!
var closeButton: UIButton!
var shareButton: UIButton!
override init(frame: CGRect) {
super.init(frame: frame)
backgroundColor = UIColor(white: 0.5, alpha: 0.1)
// let tap = UITapGestureRecognizer(target: self, action: #selector(handleTap))
// tap.delegate = self
// addGestureRecognizer(tap)
setView()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setView() {
backgroundColor = UIColor(hex: 0x000000, alpha: 0.5)
centerView = {
let view = UIView()
view.backgroundColor = .clear
return view
}()
addSubview(centerView)
centerView.snp.makeConstraints { make in
make.center.equalToSuperview()
make.height.equalTo(337)
make.width.equalTo(303)
}
topImageView = {
let imageView = UIImageView()
imageView.image = UIImage(named: "invitation_with_gifts_share_bg")
return imageView
}()
centerView.addSubview(topImageView)
topImageView.snp.makeConstraints { make in
make.center.equalToSuperview()
make.height.equalTo(337)
make.width.equalTo(303)
}
closeButton = {
let button = UIButton(type: .custom)
button.setTitleColor(UIColor.white, for: .normal)
button.setTitle("遗憾放弃", for: .normal)
button.titleLabel?.font = UIFont.PFSC_M(ofSize: 15)
button.addTarget(self, action: #selector(dismiss), for: .touchUpInside)
return button
}()
centerView.addSubview(closeButton)
closeButton.snp.makeConstraints { make in
make.centerX.equalToSuperview()
make.height.equalTo(19)
make.width.equalTo(60)
make.bottom.equalTo(-18)
}
shareButton = {
let button = UIButton(type: .custom)
button.addTarget(self, action: #selector(share), for: .touchUpInside)
return button
}()
centerView.addSubview(shareButton)
shareButton.snp.makeConstraints { make in
make.centerX.equalToSuperview()
make.height.equalTo(48)
make.width.equalTo(259)
make.bottom.equalTo(-54)
}
}
@objc private func handleTap(_ sender: AnyObject?) {
print("处理点击手势")
dismiss()
}
@objc func dismiss() {
removeFromSuperview()
}
@objc func share() {
removeFromSuperview()
block?(0)
}
}
extension YHInvitationWithGiftsShareView: UIGestureRecognizerDelegate {
func gestureRecognizer(_ gestureRecognizer:UIGestureRecognizer, shouldReceive touch:UITouch) -> Bool {
if touch.view == self {
return true
}
return false
}
}
......@@ -51,12 +51,49 @@ class YHClipperButton: UIButton {
bottomTitleLabel.text = title
topImageView.image = UIImage(named: image)
}
/*
// Only override draw() if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
override func draw(_ rect: CGRect) {
// Drawing code
}
*/
}
class YHShareButton: UIButton {
var topImageView: UIImageView!
var bottomTitleLabel: UILabel!
override init(frame: CGRect) {
super.init(frame: frame)
setView()
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func setView() {
topImageView = {
let view = UIImageView()
return view
}()
addSubview(topImageView)
topImageView.snp.makeConstraints { make in
make.top.centerX.equalToSuperview()
make.width.height.equalTo(48)
}
bottomTitleLabel = {
let label = UILabel()
label.font = UIFont.PFSC_B(ofSize: 13)
label.textAlignment = .center
label.textColor = UIColor(hex: 0x666666)
return label
}()
addSubview(bottomTitleLabel)
bottomTitleLabel.snp.makeConstraints { make in
make.left.right.bottom.equalToSuperview()
make.height.equalTo(18)
}
}
func setContent(_ image: String, _ title: String) {
bottomTitleLabel.text = title
topImageView.image = UIImage(named: image)
}
}
......@@ -94,7 +94,7 @@ extension YHShareManager {
})
}
func sendTextContect(_ text: String) {
func sendTextContect(_ text: String, _ scene: WXScene = WXSceneSession) {
guard WXApi.isWXAppInstalled() else {
YHHUD.flash(message: "拉起微信失败")
return
......@@ -110,7 +110,7 @@ extension YHShareManager {
}
}
func sendLinkContent(_ title: String = "", _ description: String = "", _ image: UIImage = UIImage(), link: String) {
func sendLinkContent(_ title: String = "", _ description: String = "", _ image: UIImage = UIImage(), link: String, _ scene: WXScene = WXSceneSession) {
guard WXApi.isWXAppInstalled() else {
YHHUD.flash(message: "拉起微信失败")
return
......@@ -144,7 +144,7 @@ extension YHShareManager {
}
}
func sendVideoContent(_ title: String = "", _ description: String = "", _ image: UIImage = UIImage(), link: String) {
func sendVideoContent(_ title: String = "", _ description: String = "", _ image: UIImage = UIImage(), link: String, _ scene: WXScene = WXSceneSession) {
guard WXApi.isWXAppInstalled() else {
YHHUD.flash(message: "拉起微信失败")
return
......@@ -175,7 +175,7 @@ extension YHShareManager {
}
}
func sendImageContent(_ image: UIImage) {
func sendImageContent(_ image: UIImage, _ scene: WXScene = WXSceneSession) {
guard WXApi.isWXAppInstalled() else {
YHHUD.flash(message: "拉起微信失败")
return
......
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_detail_bg@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_detail_bg@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_detail_close@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_detail_close@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_detail_message@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_detail_message@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_detail_share@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_detail_share@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_detail_title@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_detail_title@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_detail_top@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_detail_top@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_share_bg@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_share_bg@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_share_bottom@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_share_bottom@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_share_center@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_share_center.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_share_detail@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_share_detail@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "编组 6@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "编组 6@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_share_right@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_share_right.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "invitation_with_gifts_share_top@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "invitation_with_gifts_share_top@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
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 to comment