SearchFeatureProvider's context field is removed

SearchFeatureProvider was holding on to a context and
outlived the SettingsActivity, thus leaking the activity.
The context was passed into most methods, and thus it
makes more sense to pass it in to every method.

Bug: 33677967
Test: Run MakeSettingsRoboTests
Change-Id: Ia82f30e7e0b83587b4baeef28e81da6b8e4303fe
This commit is contained in:
Matthew Fritze
2016-12-20 09:37:21 -08:00
parent ad5ccad461
commit 9955db6360
9 changed files with 19 additions and 24 deletions

View File

@@ -66,7 +66,7 @@ public class SearchFragment extends InstrumentedFragment implements
public void onAttach(Context context) {
super.onAttach(context);
mSearchFeatureProvider = FeatureFactory.getFactory(context)
.getSearchFeatureProvider(context);
.getSearchFeatureProvider();
}
@Override