Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

点击全屏按钮,然后快速点击物理返回键,崩溃 #1938

Closed
WWTDaoDao opened this issue Apr 3, 2019 · 3 comments
Closed

点击全屏按钮,然后快速点击物理返回键,崩溃 #1938

WWTDaoDao opened this issue Apr 3, 2019 · 3 comments

Comments

@WWTDaoDao
Copy link

(!!!!请务必务必按照issue模板,修改 后提交问题!!!!,不按模板提Isuue删除处理)

(ps 首页问题集锦和demo请先了解一下!)

问题描述:

点击全屏按钮之后,然后没等全屏页面显示出来,就按物理返回键,app崩溃,查原因应该是 mOrientationUtils.getIsLand()空指针异常

问题机型/系统:

基本上都有,我用的是三星手机Galaxy Grand Prime和华为手机测试

GSY依赖版本

例如 implementation 'com.shuyu:gsyVideoPlayer-java:6.0.3'

Demo中的复现步骤

demo中也会出现这个问题

问题代码:(如果有)

  public void run() {
                    Debuger.printfLog("GSYVideoBase resolveFullVideoShow isVerticalFullByVideoSize " + isVertical);
                    //autoFull模式下,非横屏视频视频不横屏,并且不自动旋转
                    if (!isVertical && isLockLand && mOrientationUtils.getIsLand() != 1) {
                        mOrientationUtils.resolveByClick();
                    }
                    gsyVideoPlayer.setVisibility(VISIBLE);
                    frameLayout.setVisibility(VISIBLE);
                }
            }, 300);

问题log(如果有)

java.lang.NullPointerException
at com.shuyu.gsyvideoplayer.video.base.GSYBaseVideoPlayer$2.run(GSYBaseVideoPlayer.java:314)
at android.os.Handler.handleCallback(Handler.java:733)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5426)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084)
at dalvik.system.NativeStart.main(Native Method)

xxxxxxx

@CarGuo
Copy link
Owner

CarGuo commented Apr 3, 2019

点击全屏按钮之后,然后没等全屏页面显示出来,就按物理返回键~~

这个场景还真没测试过,收到问题~

@diorslau
Copy link

diorslau commented Apr 5, 2019

嗯 确实 我也碰到过好多这种奔溃日志 希望老哥能修复下

@CarGuo
Copy link
Owner

CarGuo commented Apr 7, 2019

fix next version

@CarGuo CarGuo closed this as completed in b546022 Apr 7, 2019
hudawei996 pushed a commit to hudawei996/GSYVideoPlayer that referenced this issue Jun 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants