Loading src/com/android/settings/accounts/AccountSettings.java +5 −1 Original line number Diff line number Diff line Loading @@ -251,7 +251,11 @@ public class AccountSettings extends SettingsPreferenceFragment ProfileData profileData = mProfiles.valueAt(i); if (preference == profileData.workModeSwitch) { final int userId = profileData.userInfo.id; mUm.setQuietModeEnabled(userId, !((boolean) newValue)); if ((boolean) newValue) { mUm.trySetQuietModeDisabled(userId, null); } else { mUm.setQuietModeEnabled(userId, true); } return true; } } Loading src/com/android/settings/dashboard/conditional/WorkModeCondition.java +1 −1 Original line number Diff line number Diff line Loading @@ -90,7 +90,7 @@ public class WorkModeCondition extends Condition { @Override public void onActionClick(int index) { if (index == 0) { mUm.setQuietModeEnabled(mUserHandle.getIdentifier(), false); mUm.trySetQuietModeDisabled(mUserHandle.getIdentifier(), null); setActive(false); } else { throw new IllegalArgumentException("Unexpected index " + index); Loading Loading
src/com/android/settings/accounts/AccountSettings.java +5 −1 Original line number Diff line number Diff line Loading @@ -251,7 +251,11 @@ public class AccountSettings extends SettingsPreferenceFragment ProfileData profileData = mProfiles.valueAt(i); if (preference == profileData.workModeSwitch) { final int userId = profileData.userInfo.id; mUm.setQuietModeEnabled(userId, !((boolean) newValue)); if ((boolean) newValue) { mUm.trySetQuietModeDisabled(userId, null); } else { mUm.setQuietModeEnabled(userId, true); } return true; } } Loading
src/com/android/settings/dashboard/conditional/WorkModeCondition.java +1 −1 Original line number Diff line number Diff line Loading @@ -90,7 +90,7 @@ public class WorkModeCondition extends Condition { @Override public void onActionClick(int index) { if (index == 0) { mUm.setQuietModeEnabled(mUserHandle.getIdentifier(), false); mUm.trySetQuietModeDisabled(mUserHandle.getIdentifier(), null); setActive(false); } else { throw new IllegalArgumentException("Unexpected index " + index); Loading