B
boehse04
Neues Mitglied
- 0
Hallo,
habe leider das nächste Problem bei meiner App.
Ich würde gerne ein embedded YouTube-Video aus der App heraus in der YouTube-App starten.
Versucht habe ich es mit folgendem Code:
Und dieser Anpassung in der Manifest:
Bei mir kommt aber nur kurz ein Ladesymbol auf dem YouTube-Video und danach passiert nichts.
Hat jemand eine Lösung?
habe leider das nächste Problem bei meiner App.
Ich würde gerne ein embedded YouTube-Video aus der App heraus in der YouTube-App starten.
Versucht habe ich es mit folgendem Code:
Code:
public boolean shouldOverrideUrlLoading(WebView view, String url) {
if (url.startsWith("vnd.youtube")){
startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse(url)));
return true;
}
}
Code:
<intent-filter>
<action android:name="android.intent.action.VIEW"></action>
<category android:name="android.intent.category.DEFAULT</category>
<category android:name="android.intent.category.BROWSABLE"></category>
<data android:host="www.youtube.com" android:scheme="http"></data>
</intent-filter>
Hat jemand eine Lösung?