Merge "Fix the title not translated when resuming app from overview" into sc-v2-dev
diff --git a/src/com/android/customization/model/grid/GridSectionController.java b/src/com/android/customization/model/grid/GridSectionController.java
index 5470d77..64a6cce 100644
--- a/src/com/android/customization/model/grid/GridSectionController.java
+++ b/src/com/android/customization/model/grid/GridSectionController.java
@@ -74,8 +74,8 @@
             }
         }, /* reload= */ true);
 
-        gridSectionView.setOnClickListener(v -> mSectionNavigationController.navigateTo(
-                GridFragment.newInstance(context.getString(R.string.grid_title))));
+        gridSectionView.setOnClickListener(
+                v -> mSectionNavigationController.navigateTo(new GridFragment()));
 
         return gridSectionView;
     }
diff --git a/src/com/android/customization/picker/grid/GridFragment.java b/src/com/android/customization/picker/grid/GridFragment.java
index 5e5ee6a..d554f72 100644
--- a/src/com/android/customization/picker/grid/GridFragment.java
+++ b/src/com/android/customization/picker/grid/GridFragment.java
@@ -61,12 +61,6 @@
     private static final String KEY_STATE_BOTTOM_ACTION_BAR_VISIBLE =
             "GridFragment.bottomActionBarVisible";
 
-    public static GridFragment newInstance(CharSequence title) {
-        GridFragment fragment = new GridFragment();
-        fragment.setArguments(AppbarFragment.createArguments(title));
-        return fragment;
-    }
-
     private WallpaperInfo mHomeWallpaper;
     private RecyclerView mOptionsContainer;
     private OptionSelectorController<GridOption> mOptionsController;
@@ -166,6 +160,11 @@
     }
 
     @Override
+    public CharSequence getDefaultTitle() {
+        return getString(R.string.grid_title);
+    }
+
+    @Override
     protected void onBottomActionBarReady(BottomActionBar bottomActionBar) {
         super.onBottomActionBarReady(bottomActionBar);
         mBottomActionBar = bottomActionBar;