Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Android™ Runtime Development

Reply
Visitor
mirek
Posts: 1
Registered: ‎10-01-2012
My Device: All

Opening video player for vide/mp4 uri?

Hi,

 

Is there a way to start buildin playbook player "activity" to play video/mp4 uri?

 

Ideally not he android player but the playbook one, ie. is there some kind of special "rim.video/mp4" mime type you can use to skip Android version of the player and open blackberrry native one?

 

Mirek

Retired
mwhiteman
Posts: 159
Registered: ‎11-21-2008
My Device: BlackBerry 10

Re: Opening video player for vide/mp4 uri?

This will use the PlayBook native video player to open video mimeType from your Android App.

 

<activity android:name="VideoFileViewer" android:label="Media Player" android:icon="@drawable/videos"
                  android:theme="@android:style/Theme.Translucent">
            <intent-filter>
                <action android:name="android.intent.action.VIEW"/>
                <category android:name="android.intent.category.DEFAULT"/>
                <data android:scheme="file"/>
                <data android:mimeType="video/*"/>
            </intent-filter>
            <intent-filter>
                <action android:name="android.intent.action.VIEW" />
                <category android:name="android.intent.category.DEFAULT"/>
                <category android:name="android.intent.category.BROWSABLE"/>
                <data android:scheme="http"/>
                <data android:mimeType="video/*"/>
            </intent-filter>
            <intent-filter>
                <action android:name="android.intent.action.VIEW"/>
                <category android:name="android.intent.category.DEFAULT"/>
                <category android:name="android.intent.category.BROWSABLE"/>
                <data android:scheme="content"/>
                <data android:mimeType="video/*"/>
            </intent-filter>
        </activity>

Matt Whiteman
Product Manager, Android, BlackBerry Java & Simulators