Skip to content

Commit

Permalink
偶现显示时间不准确问题
Browse files Browse the repository at this point in the history
https://docs.qq.com/doc/DQ2hDUXZUdHNhc3hv

Change-Id: I540f1e794a656af7dd96bb7c1b8cdae512fa05f0
  • Loading branch information
sevenhhe authored and SundoggyNew committed Oct 20, 2021
1 parent fad92d9 commit fe22e4a
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,7 @@ class VideoPreviewActivity : VideoBaseActivity(), EventView, TextureView.Surface
override fun onSurfaceTextureSizeChanged(surface: SurfaceTexture?, width: Int, height: Int) {}
override fun onSurfaceTextureDestroyed(surface: SurfaceTexture?): Boolean { return false }
override fun onSurfaceTextureUpdated(surface: SurfaceTexture?) {
if (!showTip) {
if (!showTip && startShowVideoTime > 0) {
showVideoTime = System.currentTimeMillis() - startShowVideoTime
var content = getString(R.string.time_2_show, connectTime.toString(), showVideoTime.toString())
TipToastDialog(this, content, 10000).show()
Expand All @@ -512,6 +512,7 @@ class VideoPreviewActivity : VideoBaseActivity(), EventView, TextureView.Surface
override fun xp2pEventNotify(id: String?, msg: String?, event: Int) {
Log.e(tag, "id=${id}, event=${event}")
if (event == 1003) {
startShowVideoTime = 0L
keepPlayThreadLock?.let {
synchronized(it) {
it.notify()
Expand Down

0 comments on commit fe22e4a

Please sign in to comment.