Swipe to refresh in SubscribedThingActivity and MultiRedditListingActivity.

This commit is contained in:
Alex Ning
2019-12-17 21:33:15 +08:00
parent cdd25f3405
commit e69c26db19
12 changed files with 150 additions and 28 deletions

View File

@@ -31,11 +31,18 @@
</com.google.android.material.appbar.AppBarLayout>
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_view_multi_reddit_listing_activity"
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/swipe_refresh_layout_multi_reddit_listing_activity"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior" />
app:layout_behavior="@string/appbar_scrolling_view_behavior">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_view_multi_reddit_listing_activity"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
<LinearLayout
android:id="@+id/fetch_multi_reddit_listing_info_linear_layout_multi_reddit_listing_activity"

View File

@@ -5,11 +5,18 @@
android:layout_height="match_parent"
tools:application=".FollowedUsersListingFragment">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_view_followed_users_listing_fragment"
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/swipe_refresh_layout_followed_users_listing_fragment"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false" />
android:layout_height="match_parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_view_followed_users_listing_fragment"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false" />
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
<LinearLayout
android:id="@+id/no_subscriptions_linear_layout_followed_users_listing_fragment"

View File

@@ -5,11 +5,18 @@
android:layout_height="match_parent"
tools:application=".SubscribedSubredditsListingFragment">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_view_subscribed_subreddits_listing_fragment"
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/swipe_refresh_layout_subscribed_subreddits_listing_fragment"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false" />
android:layout_height="match_parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_view_subscribed_subreddits_listing_fragment"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipToPadding="false" />
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
<LinearLayout
android:id="@+id/no_subscriptions_linear_layout_subreddits_listing_fragment"

View File

@@ -375,4 +375,6 @@
<string name="elapsed_time_years_ago">%1$d Years</string>
<string name="error_getting_multi_reddit_data">Error getting multireddit data</string>
<string name="error_loading_multi_reddit_list">Cannot sync multireddits</string>
<string name="error_loading_subscriptions">Cannot sync subscriptions</string>
</resources>