Ver código fonte

3.6.13(5)提测

100Years 6 dias atrás
pai
commit
8e80dd5bb9

BIN
.DS_Store


+ 2 - 2
TSLiveWallpaper.xcodeproj/project.pbxproj

@@ -1465,7 +1465,7 @@
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
 				CODE_SIGN_IDENTITY = "Apple Development";
 				CODE_SIGN_STYLE = Automatic;
-				CURRENT_PROJECT_VERSION = 4;
+				CURRENT_PROJECT_VERSION = 5;
 				DEVELOPMENT_TEAM = 65UD255J84;
 				ENABLE_APP_SANDBOX = NO;
 				ENABLE_USER_SCRIPT_SANDBOXING = NO;
@@ -1506,7 +1506,7 @@
 				ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
 				CODE_SIGN_IDENTITY = "Apple Development";
 				CODE_SIGN_STYLE = Automatic;
-				CURRENT_PROJECT_VERSION = 4;
+				CURRENT_PROJECT_VERSION = 5;
 				DEVELOPMENT_TEAM = 65UD255J84;
 				ENABLE_APP_SANDBOX = NO;
 				ENABLE_USER_SCRIPT_SANDBOXING = NO;

+ 2 - 1
TSLiveWallpaper/Business/TSAIListVC/TSAIListVC/TSAIListVC.swift

@@ -188,9 +188,10 @@ extension TSAIListVC: UICollectionViewDataSource ,UICollectionViewDelegate,UICol
     }
 }
 
-func kShowGenerateBusyView(view:UIView) ->Bool{
+func kShowGenerateBusyView(view:UIView,clickViewBlock:(()->Void)? = nil) ->Bool{
     if TSGenerateBasePhotoOperationQueue.shared.isAvailability == false {
         kTextToastShared.show(atView: view,text: "1 task is processing".localized) {
+            clickViewBlock?()
             NotificationCenter.default.post(name: .kGenerateoBackStage, object: nil)
         }
         return true

+ 6 - 1
TSLiveWallpaper/Business/TSAIListVC/TSAIUploadPhotoVC/TSAIUploadPhotoVC.swift

@@ -170,7 +170,12 @@ class TSAIUploadPhotoVC: TSBaseVC {
     
     
     func generateImage() {
-
+        if kShowGenerateBusyView(view: WindowHelper.getCurrentWindow() ?? self.view,clickViewBlock: { [weak self]  in
+                guard let self = self else { return }
+            self.navigationController?.popToRootViewController(animated: true)
+        }) {
+            return
+        }
         if kPurchaseBusiness.kJudgeVipFreeType(vipFreeNumType: generatorStyle == .creatVideo ? .generalVideo : .general){ return }//判断 vip
         
         guard let upLoadImage = upLoadImage else { return }

+ 0 - 3
TSLiveWallpaper/Business/TSAIResultsFrameVC/TSAIUsedPhotoVC/TSAIUsedPhotoVC.swift

@@ -169,9 +169,6 @@ extension TSAIUsedPhotoVC: UICollectionViewDataSource ,UICollectionViewDelegate
     }
 
     public func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
-        
-        if kShowGenerateBusyView(view: WindowHelper.getCurrentWindow() ?? self.view) { return }
-        
         if let keyString = listImageKeylArray.safeObj(At:indexPath.row){
             TSImageStoreTool.retrieveImage(urlString: keyString) { [weak self] image in
                 guard let self = self else { return }

+ 19 - 1
TSLiveWallpaper/Business/TSPurchaseMembershipVC/TSPurchaseVC.swift

@@ -429,12 +429,30 @@ struct TSFeatureItemView: View {
                 Spacer().frame(height: 8)
                 Image(image).resizable().frame(width: 24, height: 24)
                 Spacer().frame(height: 8)
-                Text(text).frame(height: 48).padding(EdgeInsets(top: 0, leading: 3, bottom: 8, trailing: 3)) //.frame(height: 48, alignment: .center)
+                WordWrappingText(text: text).frame(height: 48).padding(EdgeInsets(top: 0, leading: 3, bottom: 8, trailing: 3)) //.frame(height: 48, alignment: .center)
             }
         }.frame(width: 80*kDesignScale,height: 96)
     }
 }
 
+struct WordWrappingText: View {
+    let text: String
+    
+    var body: some View {
+        if #available(iOS 15.0, *) {
+            Text(text)
+                .lineBreakMode(.byWordWrapping)
+                .lineLimit(nil)
+                .frame(maxWidth: .infinity, alignment: .center)
+        } else {
+            Text(text)
+                .fixedSize(horizontal: false, vertical: true)
+                .lineLimit(nil)
+                .frame(maxWidth: .infinity, alignment: .center)
+        }
+    }
+}
+
 extension View {
     /// 添加线性渐变背景
     /// - Parameters:

+ 0 - 3
TSLiveWallpaper/Common/Purchase/TSPurchaseBusiness.swift

@@ -42,9 +42,6 @@ class TSPurchaseBusiness {
     public var isOverTotalTimes: Bool {
         if isVip {
             loadTotalUse()
-            #if DEBUG
-                    return false
-            #endif
             return totalUsedTimes >= vipType.freeNumber
         }
         return false

+ 1 - 1
TSLiveWallpaper/Common/Purchase/TSPurchaseManager.swift

@@ -434,7 +434,7 @@ extension PurchaseManager {
             guard let self = self else { return }
             if let data = data,
                let jsonResponse = try? JSONSerialization.jsonObject(with: data) as? [String: Any] {
-//                debugPrint("PurchaseManager verifyPayResult = \(jsonResponse)")
+                debugPrint("PurchaseManager verifyPayResult = \(jsonResponse)")
                 let status = jsonResponse["status"]
                 if let status = status as? String, status == "21007" {
                     self.verifyPayResult(transaction: transaction, useSandBox: true)

+ 1 - 0
TSLiveWallpaper/Common/ViewTool/TSPhotoPickerManager/TSPhotoPickerManager.swift

@@ -128,6 +128,7 @@ class TSPhotoPickerManager: NSObject{
                 picker.autoDismiss = false
                 picker.modalTransitionStyle = .coverVertical
                 viewController?.present(picker, animated: true, completion: nil)
+                picker.reloadAlbumData()
                 self.picker = picker
                 
             } else {

+ 1 - 1
TSLiveWallpaper/en.lproj/Localizable.strings

@@ -214,5 +214,5 @@
 "We've detected unusually high generation activity. You may be a bot. Please try again tomorrow." = "We've detected unusually high generation activity. You may be a bot. Please try again tomorrow.";
 "Unlimited Photo Edits" = "Unlimited Photo Edits";
 "%d Video Generations" = "%d Video Generations";
-"Faster&Higher Quality" = "Faster&Higher Quality";
+"Faster&Higher Quality" = "Faster & Higher Quality";
 "100% Ad-Free" = "100% Ad-Free";