|
@@ -104,12 +104,23 @@ class NCViewerVideoToolBar: UIView {
|
|
|
})
|
|
|
|
|
|
setToolBar()
|
|
|
+
|
|
|
+
|
|
|
+ timerAutoHide?.invalidate()
|
|
|
+ updateOutlet()
|
|
|
+ timerAutoHide = Timer.scheduledTimer(timeInterval: 5, target: self, selector: #selector(autoHideToolBar), userInfo: nil, repeats: true)
|
|
|
+ self.isHidden = false
|
|
|
}
|
|
|
|
|
|
@objc public func hideToolBar() {
|
|
|
+ updateOutlet()
|
|
|
self.isHidden = true
|
|
|
}
|
|
|
|
|
|
+ @objc public func showToolBar() {
|
|
|
+ self.isHidden = false
|
|
|
+ }
|
|
|
+
|
|
|
@objc public func autoHideToolBar() {
|
|
|
if playbackSliderEvent == .began || playbackSliderEvent == .moved {
|
|
|
timerAutoHide?.invalidate()
|
|
@@ -121,19 +132,6 @@ class NCViewerVideoToolBar: UIView {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- @objc public func showToolBar(metadata: tableMetadata) {
|
|
|
-
|
|
|
- timerAutoHide?.invalidate()
|
|
|
-
|
|
|
- if !metadata.livePhoto && (metadata.classFile == NCCommunicationCommon.typeClassFile.audio.rawValue || metadata.classFile == NCCommunicationCommon.typeClassFile.video.rawValue) {
|
|
|
- updateOutlet()
|
|
|
- timerAutoHide = Timer.scheduledTimer(timeInterval: 5, target: self, selector: #selector(autoHideToolBar), userInfo: nil, repeats: true)
|
|
|
- UIView.animate(withDuration: 0.2) {
|
|
|
- self.isHidden = false
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
public func setToolBar() {
|
|
|
|
|
|
if player?.rate == 1 {
|