From f2eb18749cd591d18bb9034cd9433c64614aaec6 Mon Sep 17 00:00:00 2001 From: Alex Ning Date: Sun, 5 Aug 2018 14:26:01 +0800 Subject: Fetch a new access token in onCreate method of MainActivity when the old access token is about to expire, specifically, to expire within the next 5 minutes or is already expired to avoid refreshing the access token many times by other queries later. --- app/src/main/res/layout/activity_view_subreddit_detail.xml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'app/src/main/res/layout') diff --git a/app/src/main/res/layout/activity_view_subreddit_detail.xml b/app/src/main/res/layout/activity_view_subreddit_detail.xml index a840154b..460f3fb2 100644 --- a/app/src/main/res/layout/activity_view_subreddit_detail.xml +++ b/app/src/main/res/layout/activity_view_subreddit_detail.xml @@ -82,6 +82,7 @@ android:layout_marginStart="16dp" android:layout_marginEnd="16dp" android:layout_alignParentEnd="true" + android:layout_toStartOf="@id/subscriber_count_text_view_view_subreddit_detail_activity" android:textColor="@android:color/black" /> @@ -102,9 +103,11 @@ android:layout_width="match_parent" android:layout_height="?attr/actionBarSize" app:layout_collapseMode="pin" - app:popupTheme="@style/AppTheme.PopupOverlay" /> + app:popupTheme="@style/AppTheme.PopupOverlay" + app:navigationIcon="?attr/homeAsUpIndicator" /> + -- cgit v1.2.3