Browse Source

clear code

Signed-off-by: marinofaggiana <marino@marinofaggiana.com>
marinofaggiana 3 năm trước cách đây
mục cha
commit
eb05cb6128

+ 1 - 0
iOSClient/Viewer/NCViewerMedia/NCPlayer/NCPlayer.swift

@@ -314,6 +314,7 @@ class NCPlayer: NSObject {
 extension NCPlayer: AVPictureInPictureControllerDelegate {
     
     func pictureInPictureControllerWillStartPictureInPicture(_ pictureInPictureController: AVPictureInPictureController) {
+        
         activeNCPlayer.insert(self)
     }
     

+ 9 - 9
iOSClient/Viewer/NCViewerMedia/NCPlayer/NCPlayerToolBar.swift

@@ -54,11 +54,10 @@ class NCPlayerToolBar: UIView {
     private var metadata: tableMetadata?
     private var image: UIImage?
     
-    var commandCenterPlayCommand: Any?
-    var commandCenterPauseCommand: Any?
-    var commandCenterSkipForwardCommand: Any?
-    var commandCenterSkipBackwardCommand: Any?
-
+    private var commandCenterPlayCommand: Any?
+    private var commandCenterPauseCommand: Any?
+    private var commandCenterSkipForwardCommand: Any?
+    private var commandCenterSkipBackwardCommand: Any?
     
     // MARK: - View Life Cycle
 
@@ -71,7 +70,6 @@ class NCPlayerToolBar: UIView {
         let singleTapGestureRecognizer = UITapGestureRecognizer(target: self, action: #selector(didSingleTapWith(gestureRecognizer:)))
         addGestureRecognizer(singleTapGestureRecognizer)
         
-        // self
         self.layer.cornerRadius = 15
         self.layer.masksToBounds = true
         
@@ -80,7 +78,6 @@ class NCPlayerToolBar: UIView {
         blurEffectView.autoresizingMask = [.flexibleWidth, .flexibleHeight]
         self.insertSubview(blurEffectView, at:0)
         
-        // Top ToolBar
         playerTopToolBarView.layer.cornerRadius = 10
         playerTopToolBarView.layer.masksToBounds = true
         
@@ -379,6 +376,7 @@ class NCPlayerToolBar: UIView {
     }
     
     func isShow() -> Bool {
+        
         return !self.isHidden
     }
     
@@ -472,11 +470,11 @@ class NCPlayerToolBar: UIView {
         }
     }
     
+    //MARK: - Action
+    
     @objc func didSingleTapWith(gestureRecognizer: UITapGestureRecognizer) {
     }
     
-    //MARK: - Action
-    
     @IBAction func buttonPlayerToolBarTouchInside(_ sender: UIButton) {
     }
     
@@ -527,10 +525,12 @@ class NCPlayerToolBar: UIView {
     }
     
     @IBAction func forwardButtonSec(_ sender: Any) {
+        
         skip(seconds: 10)
     }
     
     @IBAction func backButtonSec(_ sender: Any) {
+        
         skip(seconds: -10)
     }
 }