summaryrefslogtreecommitdiff
path: root/core/java/android/preference/VolumePreference.java
Commit message (Collapse)AuthorAgeFilesLines
* Add 0.5 second delay to set stream or play volume ringtoneHugh Chen2020-09-151-0/+5
| | | | | | | | | | | | | | | | | If get Ring/Alarm/Media stream volume right after stop call volume, it will return the volume of the earpiece then cause UI incorrect. It is because the call volume is from the earpiece and the alarm/ring/media is from the speaker. This CL adds 0.5 second delay when play volume or set stream to avoid get wrong volume. - Add onStartTrackingTouch() callback to stop the ringtone when another seek bar is adjusted. - Add 0.5 second delay to set stream or play volume ringtone. Bug: 80194851 Test: build, adjust call volume then immediately adjust ring volume Change-Id: I06c5e84af60f0d77daffabb4a22644f43a9cf54d
* Use new UnsupportedAppUsage annotation.Artur Satayev2019-12-181-1/+1
| | | | | | | | Existing annotations in libcore/ and frameworks/ will deleted after the migration. This also means that any java library that compiles @UnsupportedAppUsage requires a direct dependency on "unsupportedappusage" java_library. Bug: 145132366 Test: m && diff unsupportedappusage_index.csv Change-Id: I534e3fd1305e2f4af076986770033478448a665c
* All Parcelable CREATOR fields are @NonNull.Jeff Sharkey2019-02-281-1/+1
| | | | | | | | | If they were null, then the Parcelable would fail to work. Bug: 126726802 Test: manual Change-Id: I7929ffa2f20e5de1c8e68e8263cca99496e9d014 Exempt-From-Owner-Approval: Trivial API annotations
* Deprecates framework Preference classesLouis Pullen-Freilich2018-11-191-0/+7
| | | | | | | | | The AndroidX Preference Library is the recommended way to build settings screens moving forward. Bug: b/114357488 Test: n/a Change-Id: I3b3bff2daf43d8239d8bf247a9c2acebbc6374eb
* Add @UnsupportedAppUsage annotationsMathew Inwood2018-08-171-0/+5
| | | | | | | | | | | | | | | | For packages: android.preference This is an automatically generated CL. See go/UnsupportedAppUsage for more details. Exempted-From-Owner-Approval: Mechanical changes to the codebase which have been approved by Android API council and announced on android-eng@ Bug: 110868826 Test: m Change-Id: I31a80552a66554d876edd01950df368c31239c2b
* Volume: Disable seekbar prefs when zen muted.John Spurlock2015-06-101-1/+1
| | | | | | | - And display the last audible value. Bug: 21267436 Change-Id: I667d0680811b48a51eab22c837933e493f1d5c44
* Update seek bar dialog preference for MaterialAlan Viverette2015-06-081-10/+16
| | | | | Bug: 21620889 Change-Id: Ie8e6f570a3be32722f4e49ccf81da263fda736fe
* Volume: Improve inline volume controls used in settings.John Spurlock2014-11-281-0/+10
| | | | | | | | | | | | | | - Make the system internal ringer mode change signal available to other system components via a standard intent, instead of a volume-controller-only binder call. - Update sysui to use new intent for icon policy. - Add proper muting state to the volumizer, to look more like the associated volume panel slider. - Add basic ringer mode state tracking for the notification-ring slider setting. Bug: 17899613 Change-Id: Ie2df52edb070055ef59c74039162a0e785d2fdbb
* Settings: Make SeekBarVolumizer more null-resilient.John Spurlock2014-10-211-1/+1
| | | | | | | | Now that the instances are reusable, ensure all "post" methods do a handler check, and ensure they are all internal. Bug: 18063070 Change-Id: Idc478c636686f666f5656f3d07bf2738ba3e9a5a
* Make SeekBarVolumizer restartable.John Spurlock2014-10-131-0/+1
| | | | | | | | Decouple start from constructor, making it possible to restart once stopped. Bug:17898190 Change-Id: I2f860864161f818d5a62a28331ef1c47051fb39f
* frameworks/base: Performance tweaks for SeekBarVolumizer.John Spurlock2014-05-271-1/+2
| | | | | | | | Move ringtone init to the worker thread. Allow the volumizer instance to be reused by making the seekbar settable. Bug:15091992 Change-Id: Ib616ae0fbb9a45c63391f8335e48ec2754dbdcd5
* VolumeZen: frameworks changes to support Settings.John Spurlock2014-05-181-225/+5
| | | | | | | | - Pull SeekBarVolumizer out into a separately reusable class. - Make register/unregisterOnActivityStopListener avail to system code. - Add new setting for displaying suppressed notifications in zen mode. Change-Id: Ic30aa575ae07650cee62c8c1d83b6bc69395cf0d
* Ensure volume preference has correct defStyleAttrAlan Viverette2014-05-151-1/+1
| | | | | BUG: 14635756 Change-Id: Id78da5df3d355a4dda9bd1b80b14df54803d5d03
* Add View constructor that supplies a default style resourceAlan Viverette2013-09-091-4/+13
| | | | | | | Also updates the constructor of every class that extends View. BUG: 10676369 Change-Id: Ifaf27bf82028d180afa4931c0e906df88d858ac3
* VolumePreference: fix audio sample playbackEric Laurent2013-07-191-25/+70
| | | | | | | | | | | | | Handle audio sample start/stop request in a handler to avoid race conditions. If a sample is active, do not ignore playback requests but schedule a second attempt one second later. This is to avoid ignoring a playback request if a sample is short or about to finish. Bug: 8176776. Change-Id: If2d5f7d469eba345af3f4771067a076a56f4bfed
* Implement new volume display policy.Eric Laurent2012-05-141-3/+1
| | | | | | | | | | | | | | | Whenever a stream type is muted, the progress bar in volume panel is at 0. If a stream is muted by ringer mode and does not control ringer mode, the progress bar is disabled. Pressing VOL- when in vibrate or silent mode resets the last audible volume of ringtone stream (music strem on tablets) to 0. VolumePanel implementation: - Always prefer AudioManager APIs over AudioService APIs when available on both. - Do not use AudioManager.shouldVibrate() (deprecated). Change-Id: I57fcb19ada4e8d729b6b41d668496562ebe340c3
* am 648dc03c: am 4dbd1bc6: am 5f074067: am 712a8cca: Merge ↵Amith Yamasani2011-08-121-1/+3
|\ | | | | | | | | | | | | "VolumePreference.onActivityStop only stops playback" * commit '648dc03cd038a726b25929f9ffc142eb16e891e8': VolumePreference.onActivityStop only stops playback
| * am 4dbd1bc6: am 5f074067: am 712a8cca: Merge ↵Amith Yamasani2011-08-121-1/+3
| |\ | | | | | | | | | | | | | | | | | | "VolumePreference.onActivityStop only stops playback" * commit '4dbd1bc6ae84cb4d0cd28922e917473ec6e53517': VolumePreference.onActivityStop only stops playback
| | * VolumePreference.onActivityStop only stops playbackSamuel Asteberg2011-02-031-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In VolumePreference.onActivityStop, the cleanup has been replaced with only stopping ringtone playback for the seekbar. This will avoid problems when switching between applications that previously lead to inconsistencies in the ring volume dialog. Change-Id: Ia751fe0893610c4f5650eb07705481400642a84e
* | | Inline SeekBarPreferenceJohn Reck2011-06-161-18/+18
|/ / | | | | | | | | | | | | Dialog-based SeekBarPreference renamed to SeekBarDialogPreference New inline SeekBarPreference added Change-Id: I7a5d8f7aa554c4af4086a9bcc74cf07879c8523c
* | Issue 3371080: fix volume update in mute state.Eric Laurent2011-02-031-8/+5
| | | | | | | | | | | | | | | | VolumePreference should take the stream mute state into account when updating the progress bar if a change is received by the content observer Change-Id: Ia1a8af9d4cc349d2d57753d865e8d2e58daf04f1
* | Enable subclass of SeekBarVolumizer to provide a custom file for sample ↵Amith Yamasani2011-01-311-21/+33
| | | | | | | | | | | | | | playback. Bug: 3409194 Change-Id: I8a408a69fd14cf9058afe01ac5c46d0f5afc1503
* | Add plumbing for volume mute key.Jeff Brown2010-11-021-0/+21
|/ | | | | | | | Full support for the volume mute key will be implemented in a later change. Bug: 2912307 Change-Id: I98c27d6360f159c8b7447e04b45f442eff87b38a
* Workaround for a database update callback that claims that the data doesn't ↵Amith Yamasani2010-01-211-3/+7
| | | | | | | exist. It's probably some intermediate state when updating the volumes that's causing the row to be missing.
* Track CPU speed stepping to get more accurate CPU cost per app.Amith Yamasani2009-09-201-0/+3
| | | | | | | | | More CPU speed stepping happening with newer devices, so we need to qualify CPU time with the CPU speed, since power consumption varies greatly by speed. Apps that peg the CPU should get a higher penaltly. Also, fix for 2062930: NPE at VolumePreference.onKey()
* Fix rare NPE due to key being delivered after activity is stopped. #2062930Amith Yamasani2009-08-251-0/+2
|
* Revert volume if it wasn't okayed by user.Amith Yamasani2009-08-241-12/+106
| | | | | | During orientation changes or homing, the volume is reverted. Also, during pause/resume, the original and modified values are remembered and restored if the dialog was up.
* Support for selection of silent ringtone from the ringtone picker.Marco Nelissen2009-07-281-2/+36
| | | | This doesn't actually enable that, but adds the necessary code to make it work when enabled, and cleans up some ringtone related code.
* AI 145870: Add a build property for the default alarm alert. Update the variousPatrick Scott2009-04-131-4/+11
| | | | | | | | | | | framework classes to deal with the new property. Also update various documentation that mentions the default ringtones. Use the build property as the default alert when the user has not chosen an alert for an alarm. This is also used if the alarm alert is null when the alarm fires. BUG=1723684 Automated import of CL 145870
* auto import from //branches/cupcake_rel/...@138607The Android Open Source Project2009-03-131-7/+0
|
* auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-031-0/+219
|
* auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-031-219/+0
|
* Code drop from //branches/cupcake/...@124589The Android Open Source Project2008-12-171-71/+129
|
* Initial ContributionThe Android Open Source Project2008-10-211-0/+161