2 Commits b78dbb7a3f ... 7256f0080c

Auteur SHA1 Bericht Datum
  zhongbaojian 7256f0080c 字幕列表默认第一项不显示编辑状态 5 jaren geleden
  zhongbaojian 089961226a log 5 jaren geleden

+ 6 - 6
SuperShow/OJAGPUImageDecoder/OJAAssetReader.swift

@@ -50,7 +50,7 @@ class OJAAssetReader: NSObject {
                 if trackStatus == AVKeyValueStatus.loaded {
                     self.setupTrackOutput(asset: self.urlAsset)
                 } else {
-                    NSLog("loadValuesAsynchronously error: \(error ?? NSError())")
+                    WSSSimpleLog("loadValuesAsynchronously error: \(error ?? NSError())")
                 }
                 semaphore.signal()
             }
@@ -63,7 +63,7 @@ class OJAAssetReader: NSObject {
         do {
             try assetReader = AVAssetReader(asset: asset)
         } catch {
-            NSLog("creating assetReader error")
+            WSSSimpleLog("creating assetReader error")
         }
         guard let reader = assetReader else {
             return
@@ -71,7 +71,7 @@ class OJAAssetReader: NSObject {
         
         let dict = [kCVPixelBufferPixelFormatTypeKey as String : kCVPixelFormatType_420YpCbCr8BiPlanarFullRange]
         guard let videoTrack = asset.tracks(withMediaType: .video).safeObject(atIndex: 0) else {
-            NSLog("no video track")
+            WSSSimpleLog("no video track")
             return
         }
         let videoTrackOutput = AVAssetReaderTrackOutput(track: videoTrack, outputSettings: dict)
@@ -89,7 +89,7 @@ class OJAAssetReader: NSObject {
         
         let success = reader.startReading()
         if !success {
-            NSLog("reading error: \(String(describing: reader.error)) \n ***\(self.urlAsset)")
+            WSSSimpleLog("reading error: \(String(describing: reader.error)) \n ***\(self.urlAsset)")
         }
         self.lock.unlock()
         
@@ -100,7 +100,7 @@ class OJAAssetReader: NSObject {
         let buffer: CMSampleBuffer? = audioTrackOutput?.copyNextSampleBuffer()
         
         if let reader = assetReader, reader.status == .completed {
-            NSLog("reader audio completed")
+            WSSSimpleLog("reader audio completed")
         }
         self.lock.unlock()
         return buffer
@@ -111,7 +111,7 @@ class OJAAssetReader: NSObject {
         let buffer: CMSampleBuffer? = videoTrackOutput?.copyNextSampleBuffer()
         self.lock.unlock()
         if let reader = assetReader, reader.status == .completed {
-            NSLog("reader video completed")
+            WSSSimpleLog("reader video completed")
             if self.shouldRepeat {
                 self.reset() //按理说如果视频不够长,则需要循环播放
             }

+ 0 - 4
SuperShow/UI/CoolVoice/Views/WSSSubtitleView.swift

@@ -207,10 +207,6 @@ class WSSSubtitleView: UIView {
             let model = item.element
 
             let itemView: WSSSubTitleItemView = createItemView(model: model, fontModel: systemFont)
-            if item.offset == 0 {
-                // 默认第一项可编辑
-                itemView.isHighlight = true
-            }
 
             container.addSubview(itemView)
             itemViews.append(itemView)