diff options
author | Brian Attwell <brianattwell@google.com> | 2014-12-18 19:15:05 -0800 |
---|---|---|
committer | Brian Attwell <brianattwell@google.com> | 2015-01-05 12:11:22 -0800 |
commit | 53fcafb3caf6197451a4ed9e34411da52cf3bf86 (patch) | |
tree | 9387bbc8906dba726aee2c2bb5e644e805f72462 /src/com/android | |
parent | b2e37f9993e0f5c5ff1d021f699e76dd76a448d6 (diff) | |
download | android_packages_apps_PhoneCommon-53fcafb3caf6197451a4ed9e34411da52cf3bf86.tar.gz android_packages_apps_PhoneCommon-53fcafb3caf6197451a4ed9e34411da52cf3bf86.tar.bz2 android_packages_apps_PhoneCommon-53fcafb3caf6197451a4ed9e34411da52cf3bf86.zip |
Unbundle PhoneCommon 1/2
+ Copy android.internal strings
- Remove getVibrateWhenRingingSetting(), which depends on the
hidden Settings.System.VIBRATE_WHEN_RINGING property name. The
property's javadoc suggests it should only be used inside system
apps, so I don't want to prematuraly unhide it.
Bug: 18777272
Change-Id: Ie80adaee100f797259f894b2c413e153e85c3bbb
Diffstat (limited to 'src/com/android')
-rw-r--r-- | src/com/android/phone/common/util/SettingsUtil.java | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/src/com/android/phone/common/util/SettingsUtil.java b/src/com/android/phone/common/util/SettingsUtil.java index 859c1a5..05f2384 100644 --- a/src/com/android/phone/common/util/SettingsUtil.java +++ b/src/com/android/phone/common/util/SettingsUtil.java @@ -37,21 +37,6 @@ import java.lang.String; public class SettingsUtil { /** - * Obtain the setting for "vibrate when ringing" setting. - * - * Watch out: if the setting is missing in the device, this will try obtaining the old - * "vibrate on ring" setting from AudioManager, and save the previous setting to the new one. - */ - public static boolean getVibrateWhenRingingSetting(Context context) { - Vibrator vibrator = (Vibrator) context.getSystemService(Context.VIBRATOR_SERVICE); - if (vibrator == null || !vibrator.hasVibrator()) { - return false; - } - return Settings.System.getInt(context.getContentResolver(), - Settings.System.VIBRATE_WHEN_RINGING, 0) != 0; - } - - /** * Queries for a ringtone name, and sets the name using a handler. * This is a method was originally copied from com.android.settings.SoundSettings. * @@ -88,10 +73,10 @@ public class SettingsUtil { } } } - CharSequence summary = context.getString(com.android.internal.R.string.ringtone_unknown); + CharSequence summary = context.getString(R.string.ringtone_unknown); // Is it a silent ringtone? if (ringtoneUri == null) { - summary = context.getString(com.android.internal.R.string.ringtone_silent); + summary = context.getString(R.string.ringtone_silent); } else { // Fetch the ringtone title from the media provider try { |