NiceVieoPlayer icon indicating copy to clipboard operation
NiceVieoPlayer copied to clipboard

全屏或者缩放时,一个空指针bug

Open xiaoyinstyle opened this issue 7 years ago • 1 comments

声明,这个bug不是一定会出现,是根据开发者的开发习惯才可能会出现的。 在NiceVideoPlayer类中,有几处是获取 ViewGroup contentView = (ViewGroup) NiceUtil.scanForActivity(mContext) .findViewById(android.R.id.content); 获取的值为null,也就是没拿到Activity的顶层View,但是换一种写法就行 ViewGroup contentView = (ViewGroup) NiceUtil.scanForActivity(mContext) .getWindow().getDecorView();

特在此 写下 问题的解决方法,以防后者 遇到而让费时间

xiaoyinstyle avatar Oct 26 '17 10:10 xiaoyinstyle

好人一生平安!

zhoutianling avatar Mar 10 '23 08:03 zhoutianling