Loading android/app/src/com/android/bluetooth/audio_util/MediaPlayerWrapper.java +15 −0 Original line number Diff line number Diff line Loading @@ -175,6 +175,16 @@ public class MediaPlayerWrapper { controller.seekTo(position); } public void fastForward() { MediaController.TransportControls controller = mMediaController.getTransportControls(); controller.fastForward(); } public void rewind() { MediaController.TransportControls controller = mMediaController.getTransportControls(); controller.rewind(); } public void skipToPrevious() { MediaController.TransportControls controller = mMediaController.getTransportControls(); controller.skipToPrevious(); Loading @@ -185,6 +195,11 @@ public class MediaPlayerWrapper { controller.skipToNext(); } public void setPlaybackSpeed(float speed) { MediaController.TransportControls controller = mMediaController.getTransportControls(); controller.setPlaybackSpeed(speed); } // TODO (apanicke): Implement shuffle and repeat support. Right now these use custom actions // and it may only be possible to do this with Google Play Music public boolean isShuffleSupported() { Loading android/app/src/com/android/bluetooth/audio_util/mockable/MediaController.java +7 −0 Original line number Diff line number Diff line Loading @@ -379,6 +379,13 @@ public class MediaController { mTransportDelegate.setRating(rating); } /** * Wrapper for MediaController.TransportControls.setPlaybackSpeed(float speed) */ public void setPlaybackSpeed(float speed) { mTransportDelegate.setPlaybackSpeed(speed); } /** * Wrapper for MediaController.TransportControls.sendCustomAction() */ Loading Loading
android/app/src/com/android/bluetooth/audio_util/MediaPlayerWrapper.java +15 −0 Original line number Diff line number Diff line Loading @@ -175,6 +175,16 @@ public class MediaPlayerWrapper { controller.seekTo(position); } public void fastForward() { MediaController.TransportControls controller = mMediaController.getTransportControls(); controller.fastForward(); } public void rewind() { MediaController.TransportControls controller = mMediaController.getTransportControls(); controller.rewind(); } public void skipToPrevious() { MediaController.TransportControls controller = mMediaController.getTransportControls(); controller.skipToPrevious(); Loading @@ -185,6 +195,11 @@ public class MediaPlayerWrapper { controller.skipToNext(); } public void setPlaybackSpeed(float speed) { MediaController.TransportControls controller = mMediaController.getTransportControls(); controller.setPlaybackSpeed(speed); } // TODO (apanicke): Implement shuffle and repeat support. Right now these use custom actions // and it may only be possible to do this with Google Play Music public boolean isShuffleSupported() { Loading
android/app/src/com/android/bluetooth/audio_util/mockable/MediaController.java +7 −0 Original line number Diff line number Diff line Loading @@ -379,6 +379,13 @@ public class MediaController { mTransportDelegate.setRating(rating); } /** * Wrapper for MediaController.TransportControls.setPlaybackSpeed(float speed) */ public void setPlaybackSpeed(float speed) { mTransportDelegate.setPlaybackSpeed(speed); } /** * Wrapper for MediaController.TransportControls.sendCustomAction() */ Loading