mirror of
https://github.com/FossifyOrg/Gallery.git
synced 2024-11-26 22:47:59 +01:00
add a null check to surfaceholder
This commit is contained in:
parent
dccca19844
commit
9e4d53684a
1 changed files with 3 additions and 0 deletions
|
@ -297,6 +297,9 @@ class VideoFragment : ViewPagerFragment(), SurfaceHolder.Callback, SeekBar.OnSee
|
|||
}
|
||||
|
||||
private fun setVideoSize() {
|
||||
if (mSurfaceHolder == null)
|
||||
mSurfaceHolder = mSurfaceView!!.holder
|
||||
|
||||
if (activity == null || !mSurfaceHolder!!.surface.isValid)
|
||||
return
|
||||
|
||||
|
|
Loading…
Reference in a new issue