summaryrefslogtreecommitdiffstats
path: root/packages/SystemUI/src/com/android/systemui/media/NotificationPlayer.java
Commit message (Collapse)AuthorAgeFilesLines
* NotificationPlayer supports MediaPlayer errorsJean-Michel Trivi2015-10-131-1/+10
| | | | | | | | | | If an error is reported while trying to play a notification, behave as if the playback had completed. Bug 21093153 Change-Id: Iedc7691d0b8f4d68ad75cb04292a5d7d9350552f (cherry picked from commit a25f6fcfed280136a16ce5800fcaabae17291dd7)
* Add support for AudioAttributes in android.media.RingtoneJean-Michel Trivi2014-08-121-6/+38
| | | | | | | | | | Deprecate use of stream types. Map deprecated API to AudioAttributes. Add new methods to specify AudioAttributes on a Ringtone instance. Bug 16790748 Change-Id: Ifb3c2e838e1f119614459ad7d71d83a4d7c9ffdb
* Organize the imports in systemui.John Spurlock2013-06-121-1/+0
| | | | | | | To follow android conventions, more importantly to remove the unused. Change-Id: I75881718e84360a579a3b02c26489ad250bc9227
* Remove obsolete importsJean-Michel Trivi2013-02-131-4/+0
| | | | Change-Id: I67d357a1b0bac89447b1e237f61dd18aea7b912b
* Fix AudioFocus for back-to-back notificationsJean-Michel Trivi2013-02-131-12/+35
| | | | | | | | | | | | | | | | A single instance of NotificationPlayer will play notifications back-to-back, and was, for each requesting AudioFocus. But as a new notification was about to be played, its accompanying thread was terminated, and the completion listener was never called, and therefore AudioFocus was not released (e.g. two requests for one release). The fix consists in requesting AudioFocus only once and abandonning it when the only reported completion is received. Added a FIXME note about a better solution to be implemented. Bug 7680947 Change-Id: Ica9d5c1eb5d57c89ceebe66282af69f0f7d43667
* No AudioFocus for notifications when media played remotelyJean-Michel Trivi2013-02-121-6/+8
| | | | | | | | | | | Don't use AudioFocus when playing a notification when media is playing remotely. This behavior may be accompanied by rules in the device's audio policy to not route the notifications to the remote display. Bug 7485803 Change-Id: I8b96aa59cace75f6e9a0e73799ef8c75e9ee97aa
* Migrate ringtone playback to SystemUI.Jeff Sharkey2012-04-271-0/+340
Introduce IRingtonePlayer, which handles playback for both Ringtone objects and Notifications. SystemUI now hosts this player, which it registers with AudioService. It also keeps MediaPlayer instances warm, and cleans them up after stop() or Binder death. Move both Ringtone and NotificationManagerService to play back audio through this new interface. Bug: 6376128, 6350773 Change-Id: I1dcb86d16ee3c4f07cdb2248d33dcff4ead3609a