Updated Activity, Fragment, and loaders to jetpack am: 8161fd4cdd am: 37f20aeab9
Change-Id: I04ab9042b29e089af0ec6f1872cec40b98b42be1
diff --git a/src/com/android/settings/intelligence/search/SearchActivity.java b/src/com/android/settings/intelligence/search/SearchActivity.java
index 3521ef3..0f00a63 100644
--- a/src/com/android/settings/intelligence/search/SearchActivity.java
+++ b/src/com/android/settings/intelligence/search/SearchActivity.java
@@ -17,15 +17,15 @@
package com.android.settings.intelligence.search;
-import android.app.Activity;
-import android.app.Fragment;
-import android.app.FragmentManager;
+import androidx.fragment.app.FragmentActivity;
+import androidx.fragment.app.Fragment;
+import androidx.fragment.app.FragmentManager;
import android.os.Bundle;
import android.view.WindowManager;
import com.android.settings.intelligence.R;
-public class SearchActivity extends Activity {
+public class SearchActivity extends FragmentActivity {
@Override
public void onCreate(Bundle savedInstanceState) {
@@ -34,7 +34,7 @@
// Keeps layouts in-place when keyboard opens.
getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_ADJUST_PAN);
- FragmentManager fragmentManager = getFragmentManager();
+ FragmentManager fragmentManager = getSupportFragmentManager();
Fragment fragment = fragmentManager.findFragmentById(R.id.main_content);
if (fragment == null) {
fragmentManager.beginTransaction()
diff --git a/src/com/android/settings/intelligence/search/SearchFragment.java b/src/com/android/settings/intelligence/search/SearchFragment.java
index 003a457..adb5fd5 100644
--- a/src/com/android/settings/intelligence/search/SearchFragment.java
+++ b/src/com/android/settings/intelligence/search/SearchFragment.java
@@ -20,14 +20,14 @@
import static com.android.settings.intelligence.nano.SettingsIntelligenceLogProto.SettingsIntelligenceEvent;
import android.app.Activity;
-import android.app.Fragment;
-import android.app.LoaderManager;
import android.content.Context;
-import android.content.Loader;
import android.os.Bundle;
import androidx.annotation.VisibleForTesting;
+import androidx.loader.content.Loader;
+import androidx.loader.app.LoaderManager;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
+import androidx.fragment.app.Fragment;
import android.text.TextUtils;
import android.util.EventLog;
import android.util.Log;
diff --git a/src/com/android/settings/intelligence/search/savedqueries/SavedQueryController.java b/src/com/android/settings/intelligence/search/savedqueries/SavedQueryController.java
index e4c2cc1..ab0c11c 100644
--- a/src/com/android/settings/intelligence/search/savedqueries/SavedQueryController.java
+++ b/src/com/android/settings/intelligence/search/savedqueries/SavedQueryController.java
@@ -16,13 +16,13 @@
package com.android.settings.intelligence.search.savedqueries;
-import android.app.LoaderManager;
import android.content.Context;
-import android.content.Loader;
import android.os.Bundle;
import android.util.Log;
import android.view.Menu;
import android.view.MenuItem;
+import androidx.loader.app.LoaderManager;
+import androidx.loader.content.Loader;
import com.android.settings.intelligence.R;
import com.android.settings.intelligence.overlay.FeatureFactory;
diff --git a/src/com/android/settings/intelligence/utils/AsyncLoader.java b/src/com/android/settings/intelligence/utils/AsyncLoader.java
index 54b62b6..edf311e 100644
--- a/src/com/android/settings/intelligence/utils/AsyncLoader.java
+++ b/src/com/android/settings/intelligence/utils/AsyncLoader.java
@@ -1,6 +1,6 @@
package com.android.settings.intelligence.utils;
-import android.content.AsyncTaskLoader;
+import androidx.loader.content.AsyncTaskLoader;
import android.content.Context;
/**