Merge "Check for component availability before all AppPrediction logic" into qt-qpr1-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
ae4ab469bf
@@ -493,6 +493,9 @@ public class ChooserActivity extends ResolverActivity {
|
|||||||
@Override
|
@Override
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
final long intentReceivedTime = System.currentTimeMillis();
|
final long intentReceivedTime = System.currentTimeMillis();
|
||||||
|
// This is the only place this value is being set. Effectively final.
|
||||||
|
mIsAppPredictorComponentAvailable = isAppPredictionServiceAvailable();
|
||||||
|
|
||||||
mIsSuccessfullySelected = false;
|
mIsSuccessfullySelected = false;
|
||||||
Intent intent = getIntent();
|
Intent intent = getIntent();
|
||||||
Parcelable targetParcelable = intent.getParcelableExtra(Intent.EXTRA_INTENT);
|
Parcelable targetParcelable = intent.getParcelableExtra(Intent.EXTRA_INTENT);
|
||||||
@@ -619,9 +622,6 @@ public class ChooserActivity extends ResolverActivity {
|
|||||||
.addTaggedData(MetricsEvent.FIELD_SHARESHEET_MIMETYPE, target.getType())
|
.addTaggedData(MetricsEvent.FIELD_SHARESHEET_MIMETYPE, target.getType())
|
||||||
.addTaggedData(MetricsEvent.FIELD_TIME_TO_APP_TARGETS, systemCost));
|
.addTaggedData(MetricsEvent.FIELD_TIME_TO_APP_TARGETS, systemCost));
|
||||||
|
|
||||||
// This is the only place this value is being set. Effectively final.
|
|
||||||
mIsAppPredictorComponentAvailable = isAppPredictionServiceAvailable();
|
|
||||||
|
|
||||||
AppPredictor appPredictor = getAppPredictorForDirectShareIfEnabled();
|
AppPredictor appPredictor = getAppPredictorForDirectShareIfEnabled();
|
||||||
if (appPredictor != null) {
|
if (appPredictor != null) {
|
||||||
mDirectShareAppTargetCache = new HashMap<>();
|
mDirectShareAppTargetCache = new HashMap<>();
|
||||||
|
|||||||
Reference in New Issue
Block a user