Add Slices for Enhanced 4G LTE

Add Slices for Enhanced 4G LTE
Enhanced 4G LTE Slice Provider:
Create slice to display appropriate message with further instructions
Enhanced 4G LTE Slice Broadcast Reciver:
1. Change the setting via ImsManager
2. Ask to requery the slice in one second to display updated settings if 1 is valid or display appropriate message

Bug: 79270171
Test: Robotests
Test: Use support-slices-demos-debug.apk to test on device
Change-Id: I48d412de94d5d9f1ad42a299691ec5cf8001c6a1
This commit is contained in:
Josh Hou
2018-05-04 07:21:29 +08:00
committed by Naina Nalluri
parent 09df7d7071
commit 606222da7f
6 changed files with 618 additions and 17 deletions

View File

@@ -24,6 +24,7 @@ import static com.android.settings.slices.SettingsSliceProvider.EXTRA_SLICE_KEY;
import static com.android.settings.slices.SettingsSliceProvider.EXTRA_SLICE_PLATFORM_DEFINED;
import static com.android.settings.wifi.calling.WifiCallingSliceHelper.ACTION_WIFI_CALLING_CHANGED;
import static com.android.settings.wifi.WifiSliceBuilder.ACTION_WIFI_SLICE_CHANGED;
import static com.android.settings.mobilenetwork.Enhanced4gLteSliceHelper.ACTION_ENHANCED_4G_LTE_CHANGED;
import android.app.slice.Slice;
import android.content.BroadcastReceiver;
@@ -84,6 +85,12 @@ public class SliceBroadcastReceiver extends BroadcastReceiver {
case ACTION_ZEN_MODE_SLICE_CHANGED:
ZenModeSliceBuilder.handleUriChange(context, intent);
break;
case ACTION_ENHANCED_4G_LTE_CHANGED:
FeatureFactory.getFactory(context)
.getSlicesFeatureProvider()
.getNewEnhanced4gLteSliceHelper(context)
.handleEnhanced4gLteChanged(intent);
break;
default:
final String uriString = intent.getStringExtra(SliceBroadcastRelay.EXTRA_URI);
if (!TextUtils.isEmpty(uriString)) {