535 Commits

Author SHA1 Message Date
olly
a028ce8964 Fix missing Javadoc
PiperOrigin-RevId: 346764371
2021-01-11 16:13:28 +00:00
olly
27d8bcf4cb Support enabling next/previous actions in PlayerNotificationManager
The ref'd issue was marked as a doucmentation candidate, but I think
the confusion likely arises from the lack of "next" and "previous" in
the method names. Our other UI components also support enabling each
button individually, so this also brings notifications in line with
those.

Issue: #6491
#exofixit
PiperOrigin-RevId: 344058969
2020-11-30 10:42:06 +00:00
christosts
07a8b59a2e Set tag for every track in TrackSelectionView
#minor-release

PiperOrigin-RevId: 344051610
2020-11-30 10:40:03 +00:00
olly
3509f50783 Fix fastforward and rewind color tinting and text alignment
Issue: #7898
PiperOrigin-RevId: 343251455
2020-11-23 09:58:48 +00:00
olly
bb8a2de37d Update Styled Player settings dialogs to respect RTL.
PiperOrigin-RevId: 342672124
2020-11-23 09:58:48 +00:00
insun
82969c823c Increase touch target height of timebar in StyledPlayerControlView
This change also introduces gravity attribute to DefaultTimeBar.

PiperOrigin-RevId: 342573167
2020-11-23 09:58:43 +00:00
olly
12e428ec87 Fix incorrect IntDef usage
#minor-release

PiperOrigin-RevId: 341668326
2020-11-19 16:55:34 +00:00
bachinger
11b09dd58d Add dispatchPrepare(player) to ControlDispatcher
Issue: #7882
PiperOrigin-RevId: 341394254
2020-11-19 16:54:23 +00:00
ibaker
81d68317ac Fix or suppress nullness warnings introduced by checkerframework 3.7.0
PiperOrigin-RevId: 340826532
2020-11-19 16:52:32 +00:00
insun
de2b58e7e1 Fix bottom area to have even paddings and make seekbar slimmer.
Also removed unused thumb resources.

PiperOrigin-RevId: 338184661
2020-10-21 10:27:24 +01:00
ibaker
a635bdd4ba Switch to an 'api' dependency on Guava
The 'implementation' dependency causes problems when resolving
ListenableFuture in contexts that also include the
com.google.guava:listenablefuture:1.0 dependency.

Issue: #7905
Issue: #7997
Issue: #7993
PiperOrigin-RevId: 337093024
2020-10-20 22:16:12 +01:00
olly
3149dd0ffc Fix a couple of StyledPlayerControlView bugs
1. The first time the player controls are are made visible,
   there is no animation.
2. The first time the player controls are made visible, the
   "select tracks" button isn't displayed. When tapping to
   subsequently hide the player controls, the button briefly
   becomes visible and then is hidden again. This bug is due
   to state in StyledPlayerControlViewLayoutManager being
   out of sync, resulting in StyledPlayerControlView's
   onVisibilityChange not being called properly.

After this change both of these issues should be resolved.

PiperOrigin-RevId: 336704031
2020-10-20 22:16:10 +01:00
andrewlewis
8dc6b7e8c5 Update translations for UI module
This should fix gradle errors like: "warn: removing resource
com.google.android.exoplayer2.demo:string/exo_controls_fastforward_by_amount_description
without required default value."

PiperOrigin-RevId: 336670827
2020-10-20 22:11:34 +01:00
insun
1e315e47d6 Expand bottom button's height and extend greyed background area to seekbar
Adjusted the bottom layout of StyledPlayerControlView :
- Enlarged bottom button's height to make tapping easier.
- Extended greyed background area to upper edge of seekbar.
- Gave padding between bottom edge of the overall layout and bottom buttons.
- Reduced horizontal margins between bottom buttons.

PiperOrigin-RevId: 336041160
2020-10-20 22:11:34 +01:00
andrewlewis
837cdc4f67 Fix miscellaneous nits/typos
PiperOrigin-RevId: 335642909
2020-10-17 12:18:13 +01:00
samrobinson
89cd796bf6 Do not require subtitleButton in custom layouts of StyledPlayerView
Every other subtitleButton has an if not null check, but does not force non null.

Issue: #7962
PiperOrigin-RevId: 334124323
2020-10-17 11:52:45 +01:00
Oliver Woodman
9819664bd1 Merge pull request #7798 from yoobi:trackSelectionView
PiperOrigin-RevId: 333751261
2020-10-17 11:51:53 +01:00
bachinger
19530866c7 Always pass true for ongoing with the first notification
ISSUE: #7977
PiperOrigin-RevId: 333726625
2020-10-17 11:51:30 +01:00
olly
a837e7a3b0 Cleanup layout XMLs to be consistent with others
PiperOrigin-RevId: 333023580
2020-10-17 11:44:43 +01:00
olly
f4896d769f Replace duration strings with plurals
PiperOrigin-RevId: 332014290
2020-10-17 11:41:35 +01:00
olly
9fb2902dad Exclude Guava transitive annotation dependencies
PiperOrigin-RevId: 331148067
2020-09-11 16:02:37 +01:00
insun
61b253bd5e Fix not to show repeat button when its mode is NONE.
PiperOrigin-RevId: 330627047
2020-09-09 09:45:54 +01:00
insun
ea158dcdb0 Apply styled widget's bug fixes to legacy widget
- Prevent buffering when clicking ffwd button at the end of stream
- Set VR button disabled when listener is not registered

PiperOrigin-RevId: 330039336
2020-09-07 20:43:10 +01:00
insun
f68faff30b Set VR button disabled when listener is not registered (styled view)
PiperOrigin-RevId: 329851964
2020-09-07 20:42:33 +01:00
olly
b5a4dc8f36 Fix dispatch of play when in IDLE or ENDED
PiperOrigin-RevId: 329722282
2020-09-07 20:42:04 +01:00
insun
f31411b128 Revise Play/Pause button toggling logic
This CL fixes two bugs:
- Play/pause button toggling looked inconsistent when playback fails.
  When player state goes into idle, play button should dispatch
  playwhenready again.
- Clicking play button at the end of stream should restart playback.
  But previously it changed playwhenready state and so playback has
  been paused. This CL fix it.

PiperOrigin-RevId: 329675660
2020-09-07 20:41:27 +01:00
insun
be103ac553 Add padding to styled widget's settings items
PiperOrigin-RevId: 329671522
2020-09-07 20:41:18 +01:00
olly
5c24d1ccea Clean up unnecessary use of full package name
PiperOrigin-RevId: 329666401
2020-09-07 20:41:09 +01:00
insun
f68fc3e701 Prevent buffering when clicking ffwd button at the end of stream
PiperOrigin-RevId: 329634001
2020-09-07 20:40:32 +01:00
bachinger
0045d20d2c Document how to set the priority on API level above 25
Issue: #7820
PiperOrigin-RevId: 328917063
2020-09-07 20:39:08 +01:00
bachinger
8a8a1517ec Handle KEYCODE_HEADSETHOOK as alias of KEYCODE_MEDIA_PLAY_PAUSE
ISSUE: #7813
PiperOrigin-RevId: 328910220
2020-09-07 20:38:59 +01:00
tonihei
237cb9df54 Merge pull request #7804 from yoobi:TrackSelectionDialogBuilderTheme
PiperOrigin-RevId: 328726246
2020-08-27 14:41:28 +00:00
andrewlewis
74c493f51e Add back support for setting audio pitch
To play slow motion streams where the audio has been recorded at
slower speeds, it is necessary to be able to resample (rather than
time-stretch) the audio. This change undeprecates back the previously
deprecated PlaybackParameters class to allow apps to set pitch.

PiperOrigin-RevId: 328703116
2020-08-27 12:06:41 +01:00
Yoni Obadia
0176422f0b Review: Update according to review 2020-08-26 19:07:47 +02:00
Yoni Obadia
88d7587ca7 dev: add setting theme for TrackSelectionDialogBuilder 2020-08-26 11:40:48 +02:00
insun
74f788afc3 Improve a11y in minimal mode
Previously, the fullscreen button and timebar has been overlapped in minimal mode

PiperOrigin-RevId: 327606728
2020-08-21 12:51:15 +01:00
insun
b853978a91 Fix bug to show 'play' button at the end of stream
PiperOrigin-RevId: 327158791
2020-08-18 08:11:54 +01:00
insun
333ccedf80 Improve error message and correct reference to proper layout
PiperOrigin-RevId: 326944292
2020-08-17 16:13:43 +01:00
insun
602d880841 Fix StyledControlView's minimal mode bug and setShow{*}Button bug
There were two bugs in StyledPlayerControlView:
- Center icons are shown when toggling control view in minimal mode.
- `StyledControlView#setShow{*}Button` methods and corresponding
  `set_show_*_button` attributes didn't work properly.

This CL fixes bugs by controlling the buttons' visibility in one place,
StyledPlayerControlViewLayoutManager.

PiperOrigin-RevId: 326567213
2020-08-17 16:12:30 +01:00
insun
454a38c366 Increase touch target size and margins between icons
PiperOrigin-RevId: 326423935
2020-08-17 16:11:44 +01:00
insun
cda35f6677 Make play/pause button to reflect getPlayWhenReady state
Previously, it refelects isPlaying() and it makes the button to seem
unresponsive when playback error occurs.

PiperOrigin-RevId: 326396570
2020-08-17 16:10:59 +01:00
insun
b95c984d16 Cleanup unused ui resources and code
PiperOrigin-RevId: 326390725
2020-08-17 16:10:40 +01:00
insun
8661876960 Remove unnessary resources
1) As we don't display metadata (title) removed titlebar.
2) Removed exo_ic_{forward,rewind}_30.xml which are not used.

PiperOrigin-RevId: 325195605
2020-08-07 19:01:55 +01:00
insun
b26d578ff3 Fix bug that clicking didn't show up controls at the beginning
StyledLayoutManager#isFullyVisibility() was wrong and
so hiding/showing logic didn't work properly.

PiperOrigin-RevId: 324996446
2020-08-07 19:01:45 +01:00
olly
5c879ac8f8 Final string import for 2.12
PiperOrigin-RevId: 324579230
2020-08-07 18:58:51 +01:00
insun
f99023e887 Makes controls initially hidden
Also, there was a bug that controls are always shown at the beginning
even when controlview's hide() is called.

PiperOrigin-RevId: 323300617
2020-07-27 23:59:16 +01:00
insun
6fb28a8dc9 Hide fullscreen button if no listener is registered
PiperOrigin-RevId: 322912266
2020-07-24 10:48:43 +01:00
insun
cf2a58e6dc Fix styled ui's documents
#exofixit

PiperOrigin-RevId: 322854029
2020-07-24 10:48:25 +01:00
olly
132c9d15e3 UI module string cleanup
PiperOrigin-RevId: 322323784
2020-07-24 10:43:07 +01:00
olly
899a78fca9 StyledPlayerControlView: Some cleanup
PiperOrigin-RevId: 322317638
2020-07-24 10:42:48 +01:00