android-youtube-api

YouTubePlayer together with AppCompat v7 library

落爺英雄遲暮 提交于 2019-11-28 03:34:36
问题 I have developed an app that uses YouTube android API to play a certain video inside the app. At that time I have used as target API 19, and also target API 19. Now I want do change the design of the app switching to Material Design using target API 22 and also using AppCompat-v7 :22+ library . But the YouTubeBaseActivity cant be opened and the application crashes. Below I will post what I have done so far. EventDetail.java public class EventDetail extends YouTubeBaseActivity implements

YouTube API 3 Upload Video - Access not configured - Android

China☆狼群 提交于 2019-11-27 21:38:41
I am working on an Android app that records video and allows the user to upload it directly to YouTube using the YouTube Data API v3. I have set up my app in Google's API console. Under services, I have YouTube Data API v3 enabled. Under API access I have both a section "Client ID for installed applications" (including a Client ID and Client Secret) and a section "Simple API Access" -> "Key for Android apps (with certificates)" (which includes an API key and an "Android Apps" section, which is left blank for now, i.e. allow all Android apps, but I have tried it with setting my android key). I

Unable to play some Youtube videos using YouTube Android Player API

懵懂的女人 提交于 2019-11-27 21:13:52
问题 For example this video can't be played with Youtube player API : https://www.youtube.com/watch?v=OLK1efdt3n8 (other videos from search response works ok) I get the following messages : 09-25 17:18:50.226 24280-24280/com.mypackagename W/YouTubeAndroidPlayerAPI﹕ Cannot load modern controls UI. Upgrade to the latest version of the Android YouTube API. 09-25 17:19:05.911 24280-24280/com.mypackagename E/YoutubePlayerFragment﹕ video error : INTERNAL_ERROR YouTubePlayer API version : 1.2.1 (latest)

Youtube API Key

拈花ヽ惹草 提交于 2019-11-27 20:53:29
When I try to use YouTube API for Search, I get this error: There was a service error: 403 : The request did not specify any Android package name or signing-certificate fingerprint. Please ensure that the client is sending them or use the API Console to update your key restrictions. In the MainActivity I have this code: youtube = new YouTube.Builder(new NetHttpTransport(), JSON_FACTORY, new HttpRequestInitializer() { @Override public void initialize(HttpRequest httpRequest) throws IOException { } }).setYouTubeRequestInitializer(new YouTubeRequestInitializer(apiKey)).setApplicationName("Some

Error inflating class com.google.android.youtube.player.YouTubePlayerView In List Adapter

你。 提交于 2019-11-27 15:32:20
I am trying to inflate <com.google.android.youtube.player.YouTubePlayerView android:id="@+id/youtubeplayerview" android:layout_width="match_parent" android:layout_height="wrap_content" android:padding="5dp" /> in List adapter so that I can play video in the listview it self but I am getting error Error inflating class com.google.android.youtube.player.YouTubePlayerView while if I am using <com.google.android.youtube.player.YouTubeThumbnailView android:id="@+id/youtubeplayerview" android:layout_width="match_parent" android:layout_height="wrap_content" android:padding="5dp" /> It is getting

getSupportActionBar with YouTubeBaseActivity

让人想犯罪 __ 提交于 2019-11-27 15:09:37
问题 I am trying out youtube video to be played on my app. I understand this can be achieve by extending activity as YouTubeBaseActivity by doing this I don't have access to you my toolbar. mActionBar = (Toolbar) findViewById(R.id.toolbar); if (mActionBar != null) { setSupportActionBar(mActionBar); } getSupportActionBar().setTitle(getResources().getString(R.string.youtubetitle)); getSupportActionBar().setDisplayHomeAsUpEnabled(true); getSupportActionBar().setHomeButtonEnabled(true); I am getting

Struggling with Youtube Player Support Fragment

帅比萌擦擦* 提交于 2019-11-27 12:31:17
Im trying to use the Youtube Player Support Fragment in a fragment but the app always crash (NullPointerException) and I have not been able to find any similar post to fix it. I have import import android.support.v4.app.Fragment so that should not be the problem. This is how my fragment class looks like: package com.example.activitydetector; import com.google.android.youtube.player.YouTubeBaseActivity; import com.google.android.youtube.player.YouTubeInitializationResult; import com.google.android.youtube.player.YouTubePlayer; import com.google.android.youtube.player.YouTubePlayer

Multiple YouTubePlayerFragments inside a Horizontal ScrollView - all the players display the last loaded video

别说谁变了你拦得住时间么 提交于 2019-11-27 07:10:41
问题 I want to show multiple YouTube videos in a Horizontal ScrollView . For that, I'm adding YouTubePlayerFragments dynamically. Here's the piece of my code: //set videos int count = 0; FragmentTransaction transaction = getChildFragmentManager().beginTransaction(); for (final Video video : mVideos) { //create an instance of a video fragment final VideoFragment fragment = new VideoFragment();// VideoFragment extends YouTubePlayerFragment Bundle bundle = new Bundle(); if (null != mVideos && 0 <

com.google.android.gms.auth.GoogleAuthException: UNREGISTERED_ON_API_CONSOLE

被刻印的时光 ゝ 提交于 2019-11-27 02:40:49
问题 Im implementing an android app that enables users to stream to a youtube channel straight from the app. I have created an API key and a OAuth 2.0 client ID But I get a the following exeption: com.google.android.gms.auth.GoogleAuthException: UNREGISTERED_ON_API_CONSOLE either when I try to ceate an event or when i try to fetch the one a created manually on the youtube channel. I use the following code for create a youtube object String accountName = mContext.getString(R.string.google_account

Youtube API Key

生来就可爱ヽ(ⅴ<●) 提交于 2019-11-26 22:59:20
问题 When I try to use YouTube API for Search, I get this error: There was a service error: 403 : The request did not specify any Android package name or signing-certificate fingerprint. Please ensure that the client is sending them or use the API Console to update your key restrictions. In the MainActivity I have this code: youtube = new YouTube.Builder(new NetHttpTransport(), JSON_FACTORY, new HttpRequestInitializer() { @Override public void initialize(HttpRequest httpRequest) throws IOException