Use FragmentContainerView

This commit is contained in:
TacoTheDank 2021-09-24 21:28:22 -04:00
parent 14a09c725f
commit a5ca6ac2bc
11 changed files with 15 additions and 13 deletions

View File

@ -122,11 +122,12 @@ public class SearchSubredditsResultActivity extends BaseActivity implements Acti
bundle.putString(SubredditListingFragment.EXTRA_ACCOUNT_NAME, mAccountName); bundle.putString(SubredditListingFragment.EXTRA_ACCOUNT_NAME, mAccountName);
bundle.putBoolean(SubredditListingFragment.EXTRA_IS_MULTI_SELECTION, getIntent().getBooleanExtra(EXTRA_IS_MULTI_SELECTION, false)); bundle.putBoolean(SubredditListingFragment.EXTRA_IS_MULTI_SELECTION, getIntent().getBooleanExtra(EXTRA_IS_MULTI_SELECTION, false));
mFragment.setArguments(bundle); mFragment.setArguments(bundle);
getSupportFragmentManager().beginTransaction().replace(R.id.frame_layout_search_subreddits_result_activity, mFragment).commit();
} else { } else {
mFragment = getSupportFragmentManager().getFragment(savedInstanceState, FRAGMENT_OUT_STATE); mFragment = getSupportFragmentManager().getFragment(savedInstanceState, FRAGMENT_OUT_STATE);
getSupportFragmentManager().beginTransaction().replace(R.id.frame_layout_search_subreddits_result_activity, mFragment).commit();
} }
getSupportFragmentManager().beginTransaction()
.replace(R.id.frame_layout_search_subreddits_result_activity, mFragment)
.commit();
} }
@Override @Override

View File

@ -119,11 +119,12 @@ public class SearchUsersResultActivity extends BaseActivity implements ActivityT
bundle.putString(UserListingFragment.EXTRA_ACCOUNT_NAME, mAccountName); bundle.putString(UserListingFragment.EXTRA_ACCOUNT_NAME, mAccountName);
bundle.putBoolean(UserListingFragment.EXTRA_IS_MULTI_SELECTION, getIntent().getBooleanExtra(EXTRA_IS_MULTI_SELECTION, false)); bundle.putBoolean(UserListingFragment.EXTRA_IS_MULTI_SELECTION, getIntent().getBooleanExtra(EXTRA_IS_MULTI_SELECTION, false));
mFragment.setArguments(bundle); mFragment.setArguments(bundle);
getSupportFragmentManager().beginTransaction().replace(R.id.frame_layout_search_users_result_activity, mFragment).commit();
} else { } else {
mFragment = getSupportFragmentManager().getFragment(savedInstanceState, FRAGMENT_OUT_STATE); mFragment = getSupportFragmentManager().getFragment(savedInstanceState, FRAGMENT_OUT_STATE);
getSupportFragmentManager().beginTransaction().replace(R.id.frame_layout_search_users_result_activity, mFragment).commit();
} }
getSupportFragmentManager().beginTransaction()
.replace(R.id.frame_layout_search_users_result_activity, mFragment)
.commit();
} }
@Override @Override

View File

@ -33,7 +33,7 @@
</com.google.android.material.appbar.AppBarLayout> </com.google.android.material.appbar.AppBarLayout>
<FrameLayout <androidx.fragment.app.FragmentContainerView
android:id="@+id/frame_layout_account_posts_activity" android:id="@+id/frame_layout_account_posts_activity"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"

View File

@ -32,7 +32,7 @@
</com.google.android.material.appbar.AppBarLayout> </com.google.android.material.appbar.AppBarLayout>
<FrameLayout <androidx.fragment.app.FragmentContainerView
android:id="@+id/frame_layout_anonymous_subscriptions_activity" android:id="@+id/frame_layout_anonymous_subscriptions_activity"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"

View File

@ -34,7 +34,7 @@
</com.google.android.material.appbar.AppBarLayout> </com.google.android.material.appbar.AppBarLayout>
<FrameLayout <androidx.fragment.app.FragmentContainerView
android:id="@+id/frame_layout_filtered_posts_activity" android:id="@+id/frame_layout_filtered_posts_activity"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"

View File

@ -32,7 +32,7 @@
</com.google.android.material.appbar.AppBarLayout> </com.google.android.material.appbar.AppBarLayout>
<FrameLayout <androidx.fragment.app.FragmentContainerView
android:id="@+id/frame_layout_multireddit_selection_activity" android:id="@+id/frame_layout_multireddit_selection_activity"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"

View File

@ -23,7 +23,7 @@
</com.google.android.material.appbar.AppBarLayout> </com.google.android.material.appbar.AppBarLayout>
<FrameLayout <androidx.fragment.app.FragmentContainerView
android:id="@+id/frame_layout_search_subreddits_result_activity" android:id="@+id/frame_layout_search_subreddits_result_activity"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"

View File

@ -23,7 +23,7 @@
</com.google.android.material.appbar.AppBarLayout> </com.google.android.material.appbar.AppBarLayout>
<FrameLayout <androidx.fragment.app.FragmentContainerView
android:id="@+id/frame_layout_search_users_result_activity" android:id="@+id/frame_layout_search_users_result_activity"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"

View File

@ -28,7 +28,7 @@
</com.google.android.material.appbar.AppBarLayout> </com.google.android.material.appbar.AppBarLayout>
<FrameLayout <androidx.fragment.app.FragmentContainerView
android:id="@+id/frame_layout_settings_activity" android:id="@+id/frame_layout_settings_activity"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"

View File

@ -32,7 +32,7 @@
</com.google.android.material.appbar.AppBarLayout> </com.google.android.material.appbar.AppBarLayout>
<FrameLayout <androidx.fragment.app.FragmentContainerView
android:id="@+id/frame_layout_subreddit_selection_activity" android:id="@+id/frame_layout_subreddit_selection_activity"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"

View File

@ -33,7 +33,7 @@
</com.google.android.material.appbar.AppBarLayout> </com.google.android.material.appbar.AppBarLayout>
<FrameLayout <androidx.fragment.app.FragmentContainerView
android:id="@+id/frame_layout_view_multi_reddit_detail_activity" android:id="@+id/frame_layout_view_multi_reddit_detail_activity"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"