[Wi-Fi] WiFi Settings inclusive language fix plan phase 1

Replace WiFi related terms which contain Master wording.
Goal: Create a fixit for Android Platform to reduce the use of non-inclusive language for all code.

Bug: 161425297
Test: make RunSettingsRoboTests -j or
make RunSettingsRoboTests ROBOTEST_FILTER=DashboardFragmentTest
make RunSettingsRoboTests ROBOTEST_FILTER=WirelessDebuggingPreferenceControllerTest
make RunSettingsRoboTests ROBOTEST_FILTER=AutomaticStorageManagementSwitchPreferenceControllerTest
make RunSettingsRoboTests ROBOTEST_FILTER=AllInOneTetherPreferenceControllerTest
make RunSettingsRoboTests ROBOTEST_FILTER=TopLevelNetworkEntryPreferenceControllerTest
make RunSettingsRoboTests ROBOTEST_FILTER=PrimarySwitchPreferenceTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiPrimarySwitchPreferenceControllerTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiTetherPreferenceControllerTest

Change-Id: I9395c50e092e124016609f88f7c8151554a0d874
This commit is contained in:
govenliu
2020-07-16 17:09:03 +08:00
parent 670d37c44e
commit b70ddb9df7
29 changed files with 119 additions and 108 deletions

View File

@@ -39,7 +39,7 @@ import com.android.settings.applications.AppInfoBase;
import com.android.settings.core.PreferenceControllerMixin;
import com.android.settings.core.SubSettingLauncher;
import com.android.settings.notification.NotificationBackend;
import com.android.settings.widget.MasterSwitchPreference;
import com.android.settings.widget.PrimarySwitchPreference;
import com.android.settingslib.RestrictedSwitchPreference;
import java.util.ArrayList;
@@ -92,8 +92,8 @@ public class AppChannelsBypassingDndPreferenceController extends NotificationPre
// the 0th index is the mAllNotificationsToggle which allows users to
// toggle all notifications from this app to bypass DND
for (int i = 1; i < mPreferenceCategory.getPreferenceCount(); i++) {
MasterSwitchPreference childPreference =
(MasterSwitchPreference) mPreferenceCategory.getPreference(i);
PrimarySwitchPreference childPreference =
(PrimarySwitchPreference) mPreferenceCategory.getPreference(i);
childPreference.setChecked(showNotificationInDnd(mChannels.get(i - 1)));
}
return true;
@@ -158,7 +158,7 @@ public class AppChannelsBypassingDndPreferenceController extends NotificationPre
mPreferenceCategory.removeAll();
mPreferenceCategory.addPreference(mAllNotificationsToggle);
for (NotificationChannel channel : mChannels) {
MasterSwitchPreference channelPreference = new MasterSwitchPreference(mContext);
PrimarySwitchPreference channelPreference = new PrimarySwitchPreference(mContext);
channelPreference.setDisabledByAdmin(mAdmin);
channelPreference.setSwitchEnabled(
(mAdmin == null || !channelPreference.isDisabledByAdmin())