Activity extending ActionBarActivity and YouTubeBaseActivity

In my application, I need getSupportActionBar() to change the title and enable the home button back. I also need to have YouTubePlayerView to display the video. I cannot extend ActionBarActivity and YouTubeBaseActivity at the same time. What is the correct way to solve such a problem?

+7
java android android-actionbar android-youtube-api
source share
1 answer

You should use YouTubePlayerFragment instead of YouTubeBaseActivity . You can extend your activity with ActionBarActivity , which will allow you to use both getSupportActionBar() and fragments.

+5
source share

All Articles