提交 4a46ead2 编写于 作者: S shuyu

修复了可移动小窗口播放结束无法移动的问题 (2017-04-20)

上级 5bac38ce
......@@ -488,10 +488,14 @@ public abstract class GSYVideoPlayer extends GSYBaseVideoPlayer implements View.
**/
@Override
protected void setSmallVideoTextureView(View.OnTouchListener onTouchListener) {
mTextureView.setOnTouchListener(onTouchListener);
mTextureViewContainer.setOnTouchListener(onTouchListener);
mProgressBar.setOnTouchListener(null);
mFullscreenButton.setOnTouchListener(null);
mTextureView.setOnClickListener(null);
mFullscreenButton.setVisibility(INVISIBLE);
mProgressBar.setVisibility(INVISIBLE);
mCurrentTimeTextView.setVisibility(INVISIBLE);
mTotalTimeTextView.setVisibility(INVISIBLE);
mTextureViewContainer.setOnClickListener(null);
mSmallClose.setVisibility(VISIBLE);
mSmallClose.setOnClickListener(new OnClickListener() {
@Override
......
......@@ -95,6 +95,10 @@ public abstract class GSYBaseVideoPlayer extends FrameLayout implements GSYMedia
protected boolean mCacheFile = false; //是否是缓存的文件
protected boolean mIsTouchWiget = true; //是否支持非全屏滑动触摸有效
protected boolean mIsTouchWigetFull = true; //是否支持全屏滑动触摸有效
protected Context mContext;
protected String mOriginUrl; //原来的url
......@@ -133,10 +137,6 @@ public abstract class GSYBaseVideoPlayer extends FrameLayout implements GSYMedia
protected OrientationUtils mOrientationUtils; //旋转工具类
protected boolean mIsTouchWiget = true; //是否支持非全屏滑动触摸有效
protected boolean mIsTouchWigetFull = true; //是否支持全屏滑动触摸有效
private Handler mHandler = new Handler();
/**
......
......@@ -634,6 +634,7 @@ public class StandardGSYVideoPlayer extends GSYVideoPlayer {
}
@Override
@SuppressWarnings("ResourceType")
protected void showProgressDialog(float deltaX, String seekTime, int seekTimePosition, String totalTime, int totalTimeDuration) {
super.showProgressDialog(deltaX, seekTime, seekTimePosition, totalTime, totalTimeDuration);
if (mProgressDialog == null) {
......@@ -821,11 +822,19 @@ public class StandardGSYVideoPlayer extends GSYVideoPlayer {
GSYBaseVideoPlayer gsyBaseVideoPlayer = super.showSmallVideo(size, actionBar, statusBar);
if (gsyBaseVideoPlayer != null) {
StandardGSYVideoPlayer gsyVideoPlayer = (StandardGSYVideoPlayer) gsyBaseVideoPlayer;
gsyVideoPlayer.setIsTouchWiget(false);//小窗口不能点击
gsyVideoPlayer.setStandardVideoAllCallBack(mStandardVideoAllCallBack);
}
return gsyBaseVideoPlayer;
}
@Override
protected void setSmallVideoTextureView(View.OnTouchListener onTouchListener) {
super.setSmallVideoTextureView(onTouchListener);
//小窗口播放停止了也可以移动
mThumbImageViewLayout.setOnTouchListener(onTouchListener);
}
/**
* 处理锁屏屏幕触摸逻辑
*/
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册