I need to change this VIDEO_CODE String every day, because inside the app is a boot that leads to a live broadcast, I would have to do it without having to generate a new apk every day and generate a new version on the console.
private final String API_KEY = "AIzaSyArMe4mfDJZYiA2xumhJp0TwHMaetcOE_g";
private final String VIDEO_CODE = "blzjpuWai_8";
player = (YouTubePlayerView) findViewById(R.id.player);
player.initialize(API_KEY, new YouTubePlayer.OnInitializedListener() {
@Override
public void onInitializationSuccess(YouTubePlayer.Provider provider, YouTubePlayer youTubePlayer, boolean b) {
if (!b){
youTubePlayer.loadVideo(VIDEO_CODE);
youTubePlayer.setPlayerStyle(YouTubePlayer.PlayerStyle.DEFAULT);
}
}
@Override
public void onInitializationFailure(YouTubePlayer.Provider provider, YouTubeInitializationResult youTubeInitializationResult) {
Toast.makeText(aovivo.this, youTubeInitializationResult.toString(), Toast.LENGTH_LONG).show();
}
});