From e53bb69d6f1236df4cf49e3307678e0495d65413 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9B=BE=E8=A7=89=E6=96=B0?= Date: Fri, 18 Apr 2025 10:49:55 +0800 Subject: [PATCH] 1 --- Podfile | 1 + Podfile.lock | 6 ++- ShortPlay.xcodeproj/project.pbxproj | 1 - .../xcshareddata/swiftpm/Package.resolved | 15 ------ ShortPlay/Libs/Login/SPLoginManager.swift | 49 ------------------- 5 files changed, 6 insertions(+), 66 deletions(-) delete mode 100644 ShortPlay.xcworkspace/xcshareddata/swiftpm/Package.resolved diff --git a/Podfile b/Podfile index 2a66bc7..8441898 100644 --- a/Podfile +++ b/Podfile @@ -25,6 +25,7 @@ target 'ShortPlay' do pod 'ZFPlayer/AVPlayer' #播放器 pod 'KTVHTTPCache' #视频缓存 pod 'HWPanModal' #底部弹出控制器 + pod 'Kingfisher' #图片加载 target 'ShortPlayTests' do diff --git a/Podfile.lock b/Podfile.lock index 1478dd5..38fb14f 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -2,6 +2,7 @@ PODS: - Alamofire (5.10.2) - CocoaAsyncSocket (7.6.5) - HWPanModal (0.9.9) + - Kingfisher (8.3.1) - KTVHTTPCache (3.0.2): - CocoaAsyncSocket - MJRefresh (3.7.9) @@ -21,6 +22,7 @@ PODS: DEPENDENCIES: - HWPanModal + - Kingfisher - KTVHTTPCache - MJRefresh - Moya @@ -35,6 +37,7 @@ SPEC REPOS: - Alamofire - CocoaAsyncSocket - HWPanModal + - Kingfisher - KTVHTTPCache - MJRefresh - Moya @@ -48,6 +51,7 @@ SPEC CHECKSUMS: Alamofire: 7193b3b92c74a07f85569e1a6c4f4237291e7496 CocoaAsyncSocket: 065fd1e645c7abab64f7a6a2007a48038fdc6a99 HWPanModal: b57a6717d3cdcd666bff44f9dd2a5be9f4d6f5d2 + Kingfisher: 3204d23de16b5ea53541c44ca5a8efb55741dec3 KTVHTTPCache: 5711692cdf9a5ecfe829b1e16577deb3ffe3dc86 MJRefresh: ff9e531227924c84ce459338414550a05d2aea78 Moya: 138f0573e53411fb3dc17016add0b748dfbd78ee @@ -57,6 +61,6 @@ SPEC CHECKSUMS: YYKit: 7cda43304a8dc3696c449041e2cb3107b4e236e7 ZFPlayer: 5cf39e8d9f0c2394a014b0db4767b5b5a6bffe13 -PODFILE CHECKSUM: 6b8807090aa7efc034949fa4dae871806b3d46fd +PODFILE CHECKSUM: 56661899b7b42659f95553caa85ba6ea5667ded3 COCOAPODS: 1.16.2 diff --git a/ShortPlay.xcodeproj/project.pbxproj b/ShortPlay.xcodeproj/project.pbxproj index d765401..148cb3e 100644 --- a/ShortPlay.xcodeproj/project.pbxproj +++ b/ShortPlay.xcodeproj/project.pbxproj @@ -253,7 +253,6 @@ mainGroup = 1DBC40502DA4EDFC0093FCB0; minimizedProjectReferenceProxies = 1; packageReferences = ( - 1DBC41062DA4FC140093FCB0 /* XCRemoteSwiftPackageReference "Kingfisher" */, ); preferredProjectObjectVersion = 77; productRefGroup = 1DBC405A2DA4EDFC0093FCB0 /* Products */; diff --git a/ShortPlay.xcworkspace/xcshareddata/swiftpm/Package.resolved b/ShortPlay.xcworkspace/xcshareddata/swiftpm/Package.resolved deleted file mode 100644 index 35d94ae..0000000 --- a/ShortPlay.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ /dev/null @@ -1,15 +0,0 @@ -{ - "originHash" : "917a2b512148612347b307b5f8d624e74df48af36fa322c80901a86fc0e1317f", - "pins" : [ - { - "identity" : "kingfisher", - "kind" : "remoteSourceControl", - "location" : "https://github.com/onevcat/Kingfisher.git", - "state" : { - "revision" : "4c6b067f96953ee19526e49e4189403a2be21fb3", - "version" : "8.3.1" - } - } - ], - "version" : 3 -} diff --git a/ShortPlay/Libs/Login/SPLoginManager.swift b/ShortPlay/Libs/Login/SPLoginManager.swift index 5f03d45..4867db6 100644 --- a/ShortPlay/Libs/Login/SPLoginManager.swift +++ b/ShortPlay/Libs/Login/SPLoginManager.swift @@ -47,53 +47,4 @@ extension SPLoginManager { } - func performDependentRequestsWithOperations() { - let queue = OperationQueue() - - // 1. 创建初始请求操作 - let initialOperation = BlockOperation { - let semaphore = DispatchSemaphore(value: 0) - -// initialRequest { result in -// defer { semaphore.signal() } -// -// if result.isSuccess { -// print("初始请求成功") -// } -// } - - semaphore.wait() - } - - // 2. 创建依赖操作 - let request1Operation = BlockOperation { - let semaphore = DispatchSemaphore(value: 0) - -// request1 { -// print("请求1完成") -// semaphore.signal() -// } - - semaphore.wait() - } - - let request2Operation = BlockOperation { - let semaphore = DispatchSemaphore(value: 0) - -// request2 { -// print("请求2完成") -// semaphore.signal() -// } - - semaphore.wait() - } - - // 3. 设置依赖关系 - request1Operation.addDependency(initialOperation) - request2Operation.addDependency(initialOperation) - - // 4. 添加操作到队列 - queue.addOperations([initialOperation, request1Operation, request2Operation], waitUntilFinished: false) - } - }