Use CustomSliceRegistry directly when possible.
This is one step closer to (un)make CustomSliceManager an singleton. Bug: 123937830 Test: manual Change-Id: I844d0fb798c73e2af1945ecb667ba73fac9edf72
This commit is contained in:
@@ -61,11 +61,10 @@ public class SliceBroadcastReceiver extends BroadcastReceiver {
|
||||
final boolean isPlatformSlice = intent.getBooleanExtra(EXTRA_SLICE_PLATFORM_DEFINED,
|
||||
false /* default */);
|
||||
|
||||
final CustomSliceManager mCustomSliceManager = FeatureFactory.getFactory(
|
||||
context).getSlicesFeatureProvider().getCustomSliceManager(context);
|
||||
if (CustomSliceRegistry.isValidAction(action)) {
|
||||
final CustomSliceable sliceable =
|
||||
mCustomSliceManager.getSliceableFromIntentAction(action);
|
||||
CustomSliceable.createInstance(context,
|
||||
CustomSliceRegistry.getSliceClassByUri(Uri.parse(action)));
|
||||
sliceable.onNotifyChange(intent);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user