0

So my app has a Youtube Player view in the main activity, my initial intention was to add a Tablayout with it's ViewPager, however, when coding I realised i couldn't get Support Fragment manager for my Adapter.

Header of my class:

public class MainActivity extends YouTubeBaseActivity implements YouTubePlayer.OnInitializedListener,
            YouTubePlayer.PlaybackEventListener {
  • 2
    `YouTubeBasicActivity` extends `Activity`, not the Jetpack `FragmentActivity`, so you cannot use Jetpack fragments with it. You might want to consider [using `YouTubePlayerView`](https://developers.google.com/youtube/android/player/reference/com/google/android/youtube/player/YouTubePlayerView) directly in activities and fragments that you control. – CommonsWare Oct 10 '22 at 21:28
  • yeah, thanks. It seems ill have to redesign my app – Santiago Bregonzio Oct 11 '22 at 14:35

0 Answers0