diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 2549f6153db..bbf4739b3a4 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -2575,15 +2575,21 @@
-
+
+
+
+
+
+ android:value="com.android.settings.category.ia.homepage" />
+
@@ -2595,24 +2601,6 @@
android:value="com.android.settings.notification.SoundSettings" />
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/res/xml/sound_settings.xml b/res/xml/sound_settings.xml
deleted file mode 100644
index c74d1f158ec..00000000000
--- a/res/xml/sound_settings.xml
+++ /dev/null
@@ -1,109 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/com/android/settings/Settings.java b/src/com/android/settings/Settings.java
index e92027a4e8a..7fc31880272 100644
--- a/src/com/android/settings/Settings.java
+++ b/src/com/android/settings/Settings.java
@@ -121,7 +121,6 @@ public class Settings extends SettingsActivity {
public static class NotificationAppListActivity extends SettingsActivity { /* empty */ }
public static class AppNotificationSettingsActivity extends SettingsActivity { /* empty */ }
public static class ChannelNotificationSettingsActivity extends SettingsActivity { /* empty */ }
- public static class OtherSoundSettingsActivity extends SettingsActivity { /* empty */ }
public static class ManageDomainUrlsActivity extends SettingsActivity { /* empty */ }
public static class AutomaticStorageManagerSettingsActivity extends SettingsActivity { /* empty */ }
public static class GamesStorageActivity extends SettingsActivity { /* empty */ }
diff --git a/src/com/android/settings/core/gateway/SettingsGateway.java b/src/com/android/settings/core/gateway/SettingsGateway.java
index e0bb8bc16d9..02eb0e98ac1 100644
--- a/src/com/android/settings/core/gateway/SettingsGateway.java
+++ b/src/com/android/settings/core/gateway/SettingsGateway.java
@@ -104,7 +104,6 @@ import com.android.settings.notification.ChannelNotificationSettings;
import com.android.settings.notification.ConfigureNotificationSettings;
import com.android.settings.notification.NotificationAccessSettings;
import com.android.settings.notification.NotificationStation;
-import com.android.settings.notification.OtherSoundSettings;
import com.android.settings.notification.SoundSettings;
import com.android.settings.notification.ZenAccessSettings;
import com.android.settings.notification.ZenModeAutomationSettings;
@@ -208,7 +207,6 @@ public class SettingsGateway {
BatterySaverSettings.class.getName(),
AppNotificationSettings.class.getName(),
ChannelNotificationSettings.class.getName(),
- OtherSoundSettings.class.getName(),
ApnSettings.class.getName(),
ApnEditor.class.getName(),
WifiCallingSettings.class.getName(),
diff --git a/src/com/android/settings/notification/OtherSoundSettings.java b/src/com/android/settings/notification/OtherSoundSettings.java
deleted file mode 100644
index 5c409d3990d..00000000000
--- a/src/com/android/settings/notification/OtherSoundSettings.java
+++ /dev/null
@@ -1,109 +0,0 @@
-/*
- * Copyright (C) 2014 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.settings.notification;
-
-import android.content.Context;
-import android.provider.SearchIndexableResource;
-
-import com.android.internal.logging.nano.MetricsProto.MetricsEvent;
-import com.android.settings.R;
-import com.android.settings.core.PreferenceController;
-import com.android.settings.core.lifecycle.Lifecycle;
-import com.android.settings.dashboard.DashboardFragment;
-import com.android.settings.search.BaseSearchIndexProvider;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-/* This class has been deprecated Modifications to Other Sounds settings should be made in
- {@link SoundSettings } instead. */
-@Deprecated
-public class OtherSoundSettings extends DashboardFragment {
- private static final String TAG = "OtherSoundSettings";
-
- @Override
- public int getMetricsCategory() {
- return MetricsEvent.NOTIFICATION_OTHER_SOUND;
- }
-
- @Override
- protected int getHelpResource() {
- return R.string.help_uri_other_sounds;
- }
-
- @Override
- protected String getLogTag() {
- return TAG;
- }
-
- @Override
- protected int getPreferenceScreenResId() {
- return R.xml.other_sound_settings;
- }
-
- @Override
- protected List getPreferenceControllers(Context context) {
- final List controllers = new ArrayList<>();
- Lifecycle lifecycle = getLifecycle();
- controllers.add(new DialPadTonePreferenceController(context, this, lifecycle));
- controllers.add(new ScreenLockSoundPreferenceController(context, this, lifecycle));
- controllers.add(new ChargingSoundPreferenceController(context, this, lifecycle));
- controllers.add(new DockingSoundPreferenceController(context, this, lifecycle));
- controllers.add(new TouchSoundPreferenceController(context, this, lifecycle));
- controllers.add(new VibrateOnTouchPreferenceController(context, this, lifecycle));
- controllers.add(new DockAudioMediaPreferenceController(context, this, lifecycle));
- controllers.add(new BootSoundPreferenceController(context));
- controllers.add(new EmergencyTonePreferenceController(context, this, lifecycle));
- return controllers;
- }
-
- // === Indexing ===
-
- public static final BaseSearchIndexProvider SEARCH_INDEX_DATA_PROVIDER =
- new BaseSearchIndexProvider() {
-
- public List getXmlResourcesToIndex(
- Context context, boolean enabled) {
- final SearchIndexableResource sir = new SearchIndexableResource(context);
- sir.xmlResId = R.xml.other_sound_settings;
- return Arrays.asList(sir);
- }
-
- public List getNonIndexableKeys(Context context) {
- final ArrayList rt = new ArrayList();
- new DialPadTonePreferenceController(context, null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new ScreenLockSoundPreferenceController(context, null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new ChargingSoundPreferenceController(context, null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new DockingSoundPreferenceController(context, null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new TouchSoundPreferenceController(context, null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new VibrateOnTouchPreferenceController(context, null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new DockAudioMediaPreferenceController(context, null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new BootSoundPreferenceController(context).updateNonIndexableKeys(rt);
- new EmergencyTonePreferenceController(context, null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- return rt;
- }
- };
-}
diff --git a/src/com/android/settings/notification/SoundSettings.java b/src/com/android/settings/notification/SoundSettings.java
index c7b0384563d..a5a1bfd52d6 100644
--- a/src/com/android/settings/notification/SoundSettings.java
+++ b/src/com/android/settings/notification/SoundSettings.java
@@ -100,17 +100,13 @@ public class SoundSettings extends DashboardFragment {
@Override
protected int getPreferenceScreenResId() {
- return mDashboardFeatureProvider.isEnabled()
- ? R.xml.ia_sound_settings : R.xml.sound_settings;
+ return R.xml.ia_sound_settings;
}
@Override
protected List getPreferenceControllers(Context context) {
final List controllers = new ArrayList<>();
Lifecycle lifecycle = getLifecycle();
- if (!mDashboardFeatureProvider.isEnabled()) {
- controllers.add(new CastPreferenceController(context));
- }
controllers.add(new ZenModePreferenceController(context));
controllers.add(new EmergencyBroadcastPreferenceController(context));
controllers.add(new VibrateWhenRingPreferenceController(context));
@@ -132,17 +128,15 @@ public class SoundSettings extends DashboardFragment {
controllers.add(mWorkSoundController);
// === Other Sound Settings ===
- if (mDashboardFeatureProvider.isEnabled()) {
- controllers.add(new DialPadTonePreferenceController(context, this, lifecycle));
- controllers.add(new ScreenLockSoundPreferenceController(context, this, lifecycle));
- controllers.add(new ChargingSoundPreferenceController(context, this, lifecycle));
- controllers.add(new DockingSoundPreferenceController(context, this, lifecycle));
- controllers.add(new TouchSoundPreferenceController(context, this, lifecycle));
- controllers.add(new VibrateOnTouchPreferenceController(context, this, lifecycle));
- controllers.add(new DockAudioMediaPreferenceController(context, this, lifecycle));
- controllers.add(new BootSoundPreferenceController(context));
- controllers.add(new EmergencyTonePreferenceController(context, this, lifecycle));
- }
+ controllers.add(new DialPadTonePreferenceController(context, this, lifecycle));
+ controllers.add(new ScreenLockSoundPreferenceController(context, this, lifecycle));
+ controllers.add(new ChargingSoundPreferenceController(context, this, lifecycle));
+ controllers.add(new DockingSoundPreferenceController(context, this, lifecycle));
+ controllers.add(new TouchSoundPreferenceController(context, this, lifecycle));
+ controllers.add(new VibrateOnTouchPreferenceController(context, this, lifecycle));
+ controllers.add(new DockAudioMediaPreferenceController(context, this, lifecycle));
+ controllers.add(new BootSoundPreferenceController(context));
+ controllers.add(new EmergencyTonePreferenceController(context, this, lifecycle));
return controllers;
}
@@ -192,8 +186,6 @@ public class SoundSettings extends DashboardFragment {
}
}
- ;
-
// === Callbacks ===
@@ -222,7 +214,7 @@ public class SoundSettings extends DashboardFragment {
public List getXmlResourcesToIndex(
Context context, boolean enabled) {
final SearchIndexableResource sir = new SearchIndexableResource(context);
- sir.xmlResId = R.xml.sound_settings;
+ sir.xmlResId = R.xml.ia_sound_settings;
return Arrays.asList(sir);
}
@@ -237,36 +229,31 @@ public class SoundSettings extends DashboardFragment {
new PhoneRingtonePreferenceController(context).updateNonIndexableKeys(rt);
new VibrateWhenRingPreferenceController(context).updateNonIndexableKeys(rt);
new EmergencyBroadcastPreferenceController(context).updateNonIndexableKeys(rt);
- if (FeatureFactory.getFactory(context).getDashboardFeatureProvider(context)
- .isEnabled()) {
- new DialPadTonePreferenceController(context,
- null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new ScreenLockSoundPreferenceController(context,
- null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new ChargingSoundPreferenceController(context,
- null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new DockingSoundPreferenceController(context,
- null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new TouchSoundPreferenceController(context, null /*
+ new DialPadTonePreferenceController(context,
+ null /* SettingsPreferenceFragment */,
+ null /* Lifecycle */).updateNonIndexableKeys(rt);
+ new ScreenLockSoundPreferenceController(context,
+ null /* SettingsPreferenceFragment */,
+ null /* Lifecycle */).updateNonIndexableKeys(rt);
+ new ChargingSoundPreferenceController(context,
+ null /* SettingsPreferenceFragment */,
+ null /* Lifecycle */).updateNonIndexableKeys(rt);
+ new DockingSoundPreferenceController(context,
+ null /* SettingsPreferenceFragment */,
+ null /* Lifecycle */).updateNonIndexableKeys(rt);
+ new TouchSoundPreferenceController(context, null /*
SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new VibrateOnTouchPreferenceController(context,
- null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new DockAudioMediaPreferenceController(context,
- null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- new BootSoundPreferenceController(context).updateNonIndexableKeys(rt);
- new EmergencyTonePreferenceController(context,
- null /* SettingsPreferenceFragment */,
- null /* Lifecycle */).updateNonIndexableKeys(rt);
- } else {
- new CastPreferenceController(context).updateNonIndexableKeys(rt);
- }
+ null /* Lifecycle */).updateNonIndexableKeys(rt);
+ new VibrateOnTouchPreferenceController(context,
+ null /* SettingsPreferenceFragment */,
+ null /* Lifecycle */).updateNonIndexableKeys(rt);
+ new DockAudioMediaPreferenceController(context,
+ null /* SettingsPreferenceFragment */,
+ null /* Lifecycle */).updateNonIndexableKeys(rt);
+ new BootSoundPreferenceController(context).updateNonIndexableKeys(rt);
+ new EmergencyTonePreferenceController(context,
+ null /* SettingsPreferenceFragment */,
+ null /* Lifecycle */).updateNonIndexableKeys(rt);
return rt;
}
diff --git a/src/com/android/settings/search/Ranking.java b/src/com/android/settings/search/Ranking.java
index fc1b8d97cd3..9b03a57dad1 100644
--- a/src/com/android/settings/search/Ranking.java
+++ b/src/com/android/settings/search/Ranking.java
@@ -46,7 +46,6 @@ import com.android.settings.inputmethod.InputMethodAndLanguageSettings;
import com.android.settings.location.LocationSettings;
import com.android.settings.location.ScanningSettings;
import com.android.settings.notification.ConfigureNotificationSettings;
-import com.android.settings.notification.OtherSoundSettings;
import com.android.settings.notification.SoundSettings;
import com.android.settings.notification.ZenModeAutomationSettings;
import com.android.settings.notification.ZenModePrioritySettings;
@@ -133,7 +132,6 @@ public final class Ranking {
// Notifications
sRankMap.put(ConfigureNotificationSettings.class.getName(), RANK_NOTIFICATIONS);
- sRankMap.put(OtherSoundSettings.class.getName(), RANK_NOTIFICATIONS);
sRankMap.put(ZenModeSettings.class.getName(), RANK_NOTIFICATIONS);
sRankMap.put(ZenModePrioritySettings.class.getName(), RANK_NOTIFICATIONS);
sRankMap.put(ZenModeAutomationSettings.class.getName(), RANK_NOTIFICATIONS);
diff --git a/src/com/android/settings/search/SearchIndexableResources.java b/src/com/android/settings/search/SearchIndexableResources.java
index 1968c7aff6f..32808fb7e55 100644
--- a/src/com/android/settings/search/SearchIndexableResources.java
+++ b/src/com/android/settings/search/SearchIndexableResources.java
@@ -69,7 +69,6 @@ import com.android.settings.location.ScanningSettings;
import com.android.settings.network.NetworkDashboardFragment;
import com.android.settings.nfc.PaymentSettings;
import com.android.settings.notification.ConfigureNotificationSettings;
-import com.android.settings.notification.OtherSoundSettings;
import com.android.settings.notification.SoundSettings;
import com.android.settings.notification.ZenModePrioritySettings;
import com.android.settings.notification.ZenModeSettings;
@@ -122,7 +121,6 @@ public final class SearchIndexableResources {
addIndex(AppAndNotificationDashboardFragment.class, NO_DATA_RES_ID,
R.drawable.ic_settings_applications);
addIndex(SoundSettings.class, NO_DATA_RES_ID, R.drawable.ic_settings_sound);
- addIndex(OtherSoundSettings.class, NO_DATA_RES_ID, R.drawable.ic_settings_sound);
addIndex(ZenModeSettings.class,
R.xml.zen_mode_settings, R.drawable.ic_settings_notifications);
addIndex(ZenModePrioritySettings.class,
diff --git a/tests/robotests/src/com/android/settings/notification/SettingPrefControllerTest.java b/tests/robotests/src/com/android/settings/notification/SettingPrefControllerTest.java
index b36b19b0a8f..25581b93a2a 100644
--- a/tests/robotests/src/com/android/settings/notification/SettingPrefControllerTest.java
+++ b/tests/robotests/src/com/android/settings/notification/SettingPrefControllerTest.java
@@ -53,7 +53,7 @@ public class SettingPrefControllerTest {
@Mock
private PreferenceScreen mScreen;
@Mock
- private OtherSoundSettings mSetting;
+ private SoundSettings mSetting;
@Mock
private Activity mActivity;
@Mock