3

HI I am Using THIA LIBRARY TO GET ANIMATION LIKE FLIPBOARD APPLICATION

When I flip one view, I am calling another view which contains a huge Data including YouTube Video and I am inflating all these into RecyclerView. Things are working fine but When I am playing YouTube Video , My video getting pause after every 1-2 seconds with this Message in my LogCat.

YouTube video playback stopped due to unauthorized overlay on top of player. The YouTubePlayerView is obscured by android.opengl.GLSurfaceView{41ced230 V.E..... ......I. 0,0-720,1230}. YouTubePlayerView is completely covered, with the distance in px between each edge of the obscuring view and the YouTubePlayerView being: left: 20, top: 628, right: 63, bottom: 244..
coder_baba
  • 447
  • 3
  • 21

1 Answers1

2

You may follow this related SO thread. Try removing the padding in the YouTubePlayerView in the layout.

<com.google.android.youtube.player.YouTubePlayerView
    android:id="@+id/video_player"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:background="#000" />

Youtube Player don't allow any view overlay it. Just using setVisibility(View.GONE) for all view overlay it. [Source.]

Community
  • 1
  • 1
abielita
  • 13,147
  • 2
  • 17
  • 59