Skip to content

Add 10 second seek buttons and audiobook chapter support to Android Auto

Robert Stone requested to merge rhstone/vlc-android:podcast-updates into master

Description

This MR adds support for two new functions: displaying 10 second seek buttons in Android Auto when media is seekable, and showing chapter name for audiobooks. The concept of "podcast mode" is introduced to the media session which disables prev/next buttons when a single track is in the queue that also matches the currently defined podcast criteria. The podcast mode relocates the seek icons into the prev/next position, which is normally always reserved. It also turns out to be beneficial for bluetooth playback to avoid inadvertently jumping back to time 0 when pressing the previous button via steering wheel controls or BT headset.

Motivation and Context

There have been several forum requests for both an audiobook mode and seek buttons in the Android Auto UI. This change does not address showing the chapter name in the app, smart tv, or notification bar. It also does not swap the controls in the notification bar with seek buttons. (Note: If the chapter information could be passed via the "media.nowPlaying" variable, it would likely carry through to all UI elements properly; however, it is unclear if that is the correct usage of the field, or even possible.)

How Has This Been Tested?

Tested with Android Audio Headunit (emulator and physical), Android Auto for Phones, and via Bluetooth.

Android Auto for Phones has unusual icon scaling behavior; the SVGs were updated to 48x48 to properly size the images.

Screenshots / GIFs (if appropriate):

audiobook

Note: The repeat icon is suppressed and remains a placeholder to add a playback speed icon in a future MR.

seek_buttons

Types of change

  • New feature (non-breaking change which adds functionality)
  • Enhancement (non-breaking change which cleans up / improves existing functionality)

Checklist

  • I have read the CONTRIBUTING section of the README document.

Resolves

Mention: #458 (closed)

Edited by Robert Stone

Merge request reports

Loading