How to get the music player buttons on Android wear like google play music

1.8k views Asked by At

I have created a notification with normal and expanded view having player controls identical to google play. However, i dont see the notification with play controls on the android wear.

I have tried to build notification with actionButtons rather than remoteViews. Now i am able to see every action as a separate card on wear. But i want the look like the google play on wear. I saw similar screen for VLC player too.

Please help.

enter image description here

2

There are 2 answers

5
ianhanniballake On

Android Wear automatically builds media notifications with play controls when you register a RemoteControlClient or its Android 5.0 replacement, MediaSession, using the transport flags you provide to determine which buttons to show and how responses get sent to your app.

0
Vika L. On
  1. You can create custom notification like I described here Android Wear : Custom Notifications

  2. but best solution I think is to create full screen application for wear. you can check google sdk sample or github how to do it https://github.com/mauimauer/AndroidWearable-Samples/tree/master/SkeletonWearableApp

and send message to wear from phone when you need to open it. Good way to open wear activity from android phone you can find in DataLayer sample app.