Snap for 4832339 from 29eec443e0 to pi-release

Change-Id: I17fd812e30dbfff2a563e67ebfee988306fb5b97
This commit is contained in:
android-build-team Robot
2018-06-10 19:05:22 +00:00
3 changed files with 11 additions and 1 deletions

View File

@@ -7421,7 +7421,7 @@
<!-- Do not disturb settings, messages, events and reminders title [CHAR LIMIT=100]-->
<string name="zen_msg_event_reminder_title">Messages, events &amp; reminders</string>
<!-- Do not disturb settings, messages, events and reminders footer [CHAR LIMIT=NONE]-->
<string name="zen_msg_event_reminder_footer">When Do Not Disturb is on, messages, reminders, and events will muted, except for the items you allow above. You can adjust messages settings to allow your friends, family, or other contacts to reach you.</string>
<string name="zen_msg_event_reminder_footer">When Do Not Disturb is on, messages, reminders, and events will be muted, except for the items you allow above. You can adjust messages settings to allow your friends, family, or other contacts to reach you.</string>
<!-- Do not disturb onboarding dialog, accept new settings [CHAR LIMIT=30]-->
<string name="zen_onboarding_ok">Done</string>

View File

@@ -170,12 +170,20 @@ public abstract class AudioSwitchPreferenceController extends BasePreferenceCont
@Override
public void onStart() {
if (mLocalBluetoothManager == null) {
Log.e(TAG, "Bluetooth is not supported on this device");
return;
}
mLocalBluetoothManager.setForegroundActivity(mContext);
register();
}
@Override
public void onStop() {
if (mLocalBluetoothManager == null) {
Log.e(TAG, "Bluetooth is not supported on this device");
return;
}
mLocalBluetoothManager.setForegroundActivity(null);
unregister();
}

View File

@@ -186,6 +186,8 @@ public class AudioOutputSwitchPreferenceControllerTest {
AudioSwitchPreferenceController controller = new AudioSwitchPreferenceControllerTestable(
mContext, TEST_KEY);
controller.onStart();
controller.onStop();
assertThat(mLocalBluetoothManager).isNull();
}