Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
NotesChapter
GSYVideoPlayer
提交
6648391e
G
GSYVideoPlayer
项目概览
NotesChapter
/
GSYVideoPlayer
与 Fork 源项目一致
从无法访问的项目Fork
通知
8
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
GSYVideoPlayer
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
6648391e
编写于
9月 13, 2018
作者:
G
guoshuyu
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修复列表到任务详情中bug和内存泄漏问题
上级
b2e249aa
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
26 addition
and
5 deletion
+26
-5
app/src/main/java/com/example/gsyvideoplayer/DetailPlayer.java
...rc/main/java/com/example/gsyvideoplayer/DetailPlayer.java
+2
-2
app/src/main/java/com/example/gsyvideoplayer/switchplay/SwitchListVideoAdapter.java
...ple/gsyvideoplayer/switchplay/SwitchListVideoAdapter.java
+8
-1
gsyVideoPlayer-java/src/main/java/com/shuyu/gsyvideoplayer/video/base/GSYVideoControlView.java
.../shuyu/gsyvideoplayer/video/base/GSYVideoControlView.java
+16
-2
未找到文件。
app/src/main/java/com/example/gsyvideoplayer/DetailPlayer.java
浏览文件 @
6648391e
...
...
@@ -238,8 +238,8 @@ public class DetailPlayer extends AppCompatActivity {
//断网自动重新链接,url前接上ijkhttphook:
//String url = "ijkhttphook:https://res.exexm.com/cw_145225549855002";
//
String
url
=
"http://7xjmzj.com1.z0.glb.clouddn.com/20171026175005_JObCxCE2.mp4"
;
String
url
=
"http://9890.vod.myqcloud.com/9890_4e292f9a3dd011e6b4078980237cc3d3.f20.mp4"
;
//
String url = "http://7xjmzj.com1.z0.glb.clouddn.com/20171026175005_JObCxCE2.mp4";
//String url = "http://hjq-1257036536.cos.ap-shanghai.myqcloud.com/m3u8/m1/out2.m3u8";
//String url = "http://223.110.243.138/PLTV/2510088/224/3221227177/index.m3u8";
//String url = "http://qiniu.carmmi.com/image/132451525666042.mp4";
...
...
app/src/main/java/com/example/gsyvideoplayer/switchplay/SwitchListVideoAdapter.java
浏览文件 @
6648391e
...
...
@@ -9,6 +9,7 @@ import android.widget.ImageView;
import
com.example.gsyvideoplayer.R
;
import
com.example.gsyvideoplayer.model.VideoModel
;
import
com.shuyu.gsyvideoplayer.GSYVideoManager
;
import
com.shuyu.gsyvideoplayer.utils.OrientationUtils
;
import
com.shuyu.gsyvideoplayer.video.StandardGSYVideoPlayer
;
...
...
@@ -88,7 +89,13 @@ public class SwitchListVideoAdapter extends BaseAdapter {
viewGroup
.
removeView
(
holder
.
imageView
);
}
holder
.
gsyVideoPlayer
.
setThumbImageView
(
holder
.
imageView
);
holder
.
gsyVideoPlayer
.
getThumbImageViewLayout
().
setVisibility
(
View
.
VISIBLE
);
if
(
GSYVideoManager
.
instance
().
getPlayTag
().
equals
(
SwitchListVideoAdapter
.
TAG
)
&&
(
position
==
GSYVideoManager
.
instance
().
getPlayPosition
()))
{
holder
.
gsyVideoPlayer
.
getThumbImageViewLayout
().
setVisibility
(
View
.
GONE
);
}
else
{
holder
.
gsyVideoPlayer
.
getThumbImageViewLayout
().
setVisibility
(
View
.
VISIBLE
);
}
return
convertView
;
...
...
gsyVideoPlayer-java/src/main/java/com/shuyu/gsyvideoplayer/video/base/GSYVideoControlView.java
浏览文件 @
6648391e
...
...
@@ -275,6 +275,8 @@ public abstract class GSYVideoControlView extends GSYVideoView implements View.O
@Override
protected
void
onDetachedFromWindow
()
{
super
.
onDetachedFromWindow
();
Debuger
.
printfLog
(
GSYVideoControlView
.
this
.
hashCode
()
+
"------------------------------ dismiss onDetachedFromWindow"
);
cancelProgressTimer
();
cancelDismissControlViewTimer
();
}
...
...
@@ -305,7 +307,6 @@ public abstract class GSYVideoControlView extends GSYVideoView implements View.O
@Override
protected
void
setStateAndUi
(
int
state
)
{
mCurrentState
=
state
;
if
((
state
==
CURRENT_STATE_NORMAL
&&
isCurrentMediaListener
())
||
state
==
CURRENT_STATE_AUTO_COMPLETE
||
state
==
CURRENT_STATE_ERROR
)
{
mHadPrepared
=
false
;
...
...
@@ -314,6 +315,7 @@ public abstract class GSYVideoControlView extends GSYVideoView implements View.O
switch
(
mCurrentState
)
{
case
CURRENT_STATE_NORMAL:
if
(
isCurrentMediaListener
())
{
Debuger
.
printfLog
(
GSYVideoControlView
.
this
.
hashCode
()
+
"------------------------------ dismiss CURRENT_STATE_NORMAL"
);
cancelProgressTimer
();
getGSYVideoManager
().
releaseMediaPlayer
();
releasePauseCover
();
...
...
@@ -329,9 +331,13 @@ public abstract class GSYVideoControlView extends GSYVideoView implements View.O
resetProgressAndTime
();
break
;
case
CURRENT_STATE_PLAYING:
startProgressTimer
();
if
(
isCurrentMediaListener
())
{
Debuger
.
printfLog
(
GSYVideoControlView
.
this
.
hashCode
()
+
"------------------------------ CURRENT_STATE_PLAYING"
);
startProgressTimer
();
}
break
;
case
CURRENT_STATE_PAUSE:
Debuger
.
printfLog
(
GSYVideoControlView
.
this
.
hashCode
()
+
"------------------------------ CURRENT_STATE_PAUSE"
);
startProgressTimer
();
break
;
case
CURRENT_STATE_ERROR:
...
...
@@ -340,6 +346,7 @@ public abstract class GSYVideoControlView extends GSYVideoView implements View.O
}
break
;
case
CURRENT_STATE_AUTO_COMPLETE:
Debuger
.
printfLog
(
GSYVideoControlView
.
this
.
hashCode
()
+
"------------------------------ dismiss CURRENT_STATE_AUTO_COMPLETE"
);
cancelProgressTimer
();
if
(
mProgressBar
!=
null
)
{
mProgressBar
.
setProgress
(
100
);
...
...
@@ -476,6 +483,9 @@ public abstract class GSYVideoControlView extends GSYVideoView implements View.O
touchSurfaceUp
();
Debuger
.
printfLog
(
GSYVideoControlView
.
this
.
hashCode
()
+
"------------------------------ surface_container ACTION_UP"
);
startProgressTimer
();
//不要和隐藏虚拟按键后,滑出虚拟按键冲突
...
...
@@ -499,6 +509,8 @@ public abstract class GSYVideoControlView extends GSYVideoView implements View.O
break
;
case
MotionEvent
.
ACTION_UP
:
startDismissControlViewTimer
();
Debuger
.
printfLog
(
GSYVideoControlView
.
this
.
hashCode
()
+
"------------------------------ progress ACTION_UP"
);
startProgressTimer
();
ViewParent
vpup
=
getParent
();
while
(
vpup
!=
null
)
{
...
...
@@ -591,6 +603,8 @@ public abstract class GSYVideoControlView extends GSYVideoView implements View.O
super
.
onPrepared
();
if
(
mCurrentState
!=
CURRENT_STATE_PREPAREING
)
return
;
startProgressTimer
();
Debuger
.
printfLog
(
GSYVideoControlView
.
this
.
hashCode
()
+
"------------------------------ surface_container onPrepared"
);
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录