视频播放禁止拖动和双击重新开始
This commit is contained in:
@@ -14,7 +14,6 @@ import android.widget.TextView
|
||||
import com.amap.api.navi.view.PoiInputSearchWidget
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger.d
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.eagle.core.utilcode.util.OverlayViewUtils
|
||||
import com.mogo.eagle.core.widget.media.video.SimpleVideoPlayer
|
||||
import com.mogo.och.common.module.wigets.OCHBorderShadowLayout
|
||||
import com.mogo.och.taxi.passenger.R
|
||||
@@ -89,6 +88,11 @@ class TaxiPassengerArrivedView :RelativeLayout, View.OnClickListener {
|
||||
ivAnimalList = findViewById(R.id.iv_animal_list)
|
||||
svpFrame = findViewById(R.id.svp_frame)
|
||||
|
||||
svpFrame.setIsTouchWiget(false)
|
||||
svpFrame.setIsTouchWigetFull(false)
|
||||
svpFrame.enableshowProgressDialog = false
|
||||
svpFrame.enableDoubleClick = false
|
||||
|
||||
allStartOrdered = mutableListOf()
|
||||
initScore()
|
||||
|
||||
|
||||
@@ -29,6 +29,18 @@ class SimpleVideoPlayer : StandardGSYVideoPlayer {
|
||||
private lateinit var start: ImageView
|
||||
private var updateTimer = 0L
|
||||
|
||||
/**
|
||||
* true 开着双击重新播放
|
||||
* false 关闭双击播放
|
||||
*/
|
||||
var enableDoubleClick = true
|
||||
|
||||
/**
|
||||
* true 显示拖动线上进度弹框
|
||||
* false 重写拖动进度弹框
|
||||
*/
|
||||
var enableshowProgressDialog = true
|
||||
|
||||
interface PlayListener {
|
||||
fun onPlayEvent(event: Int)
|
||||
}
|
||||
@@ -195,4 +207,24 @@ class SimpleVideoPlayer : StandardGSYVideoPlayer {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun touchDoubleUp() {
|
||||
if(enableDoubleClick) {
|
||||
super.touchDoubleUp()
|
||||
}
|
||||
}
|
||||
|
||||
override fun showProgressDialog(deltaX: Float, seekTime: String?, seekTimePosition: Int, totalTime: String?, totalTimeDuration: Int) {
|
||||
if(enableshowProgressDialog) {
|
||||
super.showProgressDialog(deltaX, seekTime, seekTimePosition, totalTime, totalTimeDuration)
|
||||
}
|
||||
}
|
||||
|
||||
override fun dismissProgressDialog() {
|
||||
if(enableshowProgressDialog) {
|
||||
super.dismissProgressDialog()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user