Notification Style
When music is playing, the com.adaptr.android.playersdk.Adaptr class creates a persistent notification with playback control buttons in it so that the user can always control music playback, even when a different app is in the foreground. By creating an instance of this class and passing it to com.adaptr.android.playersdk.AdaptrPlayer the imagery and layout of those notifications can be customized.
When using the default music notification layouts, the background color, play button image, pause button image, and skip button image can be customized through this object
To customize the music notification layout, you need to create two layouts: a small content view and a big content view. These must be identified with the setContentView and setBigContentView methods. Then you must provide the view IDs of any buttons or text fields in those views that you want wired up to the library: track name, artist name, release name, play/pause button, skip button, thumbs up (like) button, thumbs down (dislike) button, progress bar, and media image.
Note that the media artwork that appears in music notifications is defined via a call to com.adaptr.android.playersdk.AdaptrPlayer.artWork and not via this class.
Constructors
Functions
Return the view id of the text view that renders the current artist and appears in the custom setBigContentView or setContentView}.
Return the view id of the cancel button that renders in the custom setBigContentView on pre-Lollipop devices when music is not playing.
Return the resource id of the icon that represents the cancel button in music notifications
Return the view id of the dislike button that appears in the custom setBigContentView or setContentView}.
Return the view id of the like button that appears in the custom setBigContentView or setContentView}.
Return the view id of the image that renders the current media artwork and appears in the custom setBigContentView or setContentView}.
Return the resource id of the icon that represents the pause button in music notifications.
Return the resource id of the icon that represents the play button in music notifications
Return the view id of the play/pause button that appears in the custom setBigContentView or setContentView}.
Return the view id of the progress bar that renders the current track's elapsed playback and appears in the custom setBigContentView or setContentView}.
Return the view id of the text view that renders the current release and appears in the custom setBigContentView or setContentView}.
Return the view id of the skip button that appears in the custom setBigContentView or setContentView}.
Return the resource id of the icon that represents the skip button in music notifications
Return the resource id of the small icon that has been chosen for display in the notification area.
Return the view id of the text view that renders the current track and appears in the custom setBigContentView or setContentView}.
Specify the view id of the view that renders the current artist that appears in the custom setBigContentView or setContentView .
Specify the resource id of a view that will be rendered as a custom big notification to represent the currently playing song. Note that the view must only contain views within it that are permissible in android.widget.RemoteViews.
Specify the view id of the cancel button that appears in the setBigContentView on pre-Lollipop devices to work around a bug with android persistent notifications not going away.
Provide the resource id of the icon that represents the cancel button in music notifications.
Set the background color for the default music notification layout (note this is ignored if you use setContentView or setBigContentView).
Specify the resource id of a view that will be rendered as a custom small notification to represent the currently playing song. Note that the view must only contain views within it that are permissible in a android.widget.RemoteViews.
Specify the view id of the dislike button that appears in the custom setBigContentView or setContentView .
Specify the view id of the like button that appears in the custom setBigContentView or setContentView .
Specify the view id of the image view that renders the current media artwork that appears in the custom setBigContentView or setContentView .
Provide the resource id of the icon that represents the pause button in music notifications.
Provide the resource id of the icon that represents the play button in music notifications.
Specify the id of the play/pause button that appears in the custom setBigContentView or setContentView .
Specify the view id of the progress bar that renders the current track's elapsed playback that appears in the custom setBigContentView or setContentView .
Specify the view id of the view that renders the current release that appears in the custom setBigContentView or setContentView .
Specify the view id of the skip button that appears in the custom setBigContentView or setContentView .
Provide the resource id of the icon that represents the skip button in music notifications.
This is used to specify the image that should be used to represent music notifications for this app in the notification area.
Specify the resource ids of the icons that represent the thumbs down and selected thumbs down icons in custom music notifications.
Specify the resource ids of the icons that represent the thumbs up and selected thumbs up icons in custom music notifications.
Specify the view id of the view that renders the current track that appears in the custom setBigContentView or setContentView .
Properties
Retrieve a new android.widget.RemoteViews instance constructed from the package name and resource ID provided to setBigContentView
Retrieve a new android.widget.RemoteViews instance constructed from the package name and resource is provided to setContentView