aboutsummaryrefslogtreecommitdiff
path: root/app/src/main/res
diff options
context:
space:
mode:
authorAlex Ning <chineseperson5@gmail.com>2019-06-08 00:01:31 +0000
committerAlex Ning <chineseperson5@gmail.com>2019-06-08 00:01:31 +0000
commit7cfc4296a0c6e429a07a8cc8cdc32489220cb04b (patch)
tree352eb8652e3b243762ef3819b0727a7b80343193 /app/src/main/res
parentd7a90b53970416ae7fe5df34270924fc5191e009 (diff)
downloadinfinity-for-reddit-7cfc4296a0c6e429a07a8cc8cdc32489220cb04b.tar
infinity-for-reddit-7cfc4296a0c6e429a07a8cc8cdc32489220cb04b.tar.gz
infinity-for-reddit-7cfc4296a0c6e429a07a8cc8cdc32489220cb04b.tar.bz2
infinity-for-reddit-7cfc4296a0c6e429a07a8cc8cdc32489220cb04b.tar.lz
infinity-for-reddit-7cfc4296a0c6e429a07a8cc8cdc32489220cb04b.tar.xz
infinity-for-reddit-7cfc4296a0c6e429a07a8cc8cdc32489220cb04b.tar.zst
infinity-for-reddit-7cfc4296a0c6e429a07a8cc8cdc32489220cb04b.zip
Lazy Mode: Automatically scroll down the recyclerview in PostFragment to view posts without using hands.
Diffstat (limited to 'app/src/main/res')
-rw-r--r--app/src/main/res/layout/app_bar_main.xml1
-rw-r--r--app/src/main/res/menu/main_activity.xml17
-rw-r--r--app/src/main/res/values/strings.xml5
3 files changed, 17 insertions, 6 deletions
diff --git a/app/src/main/res/layout/app_bar_main.xml b/app/src/main/res/layout/app_bar_main.xml
index 483a7e55..f7efde6c 100644
--- a/app/src/main/res/layout/app_bar_main.xml
+++ b/app/src/main/res/layout/app_bar_main.xml
@@ -12,6 +12,7 @@
android:theme="@style/AppTheme.AppBarOverlay">
<com.google.android.material.appbar.CollapsingToolbarLayout
+ android:id="@+id/collapsing_toolbar_layout_main_activity"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:titleEnabled="false"
diff --git a/app/src/main/res/menu/main_activity.xml b/app/src/main/res/menu/main_activity.xml
index 6ef9b037..2d4d02ad 100644
--- a/app/src/main/res/menu/main_activity.xml
+++ b/app/src/main/res/menu/main_activity.xml
@@ -4,16 +4,21 @@
xmlns:tools="http://schemas.android.com/tools"
tools:context="ml.docilealligator.infinityforreddit.MainActivity">
<item
+ android:id="@+id/action_search_main_activity"
+ android:orderInCategory="1"
+ android:title="@string/action_search"
+ android:icon="@drawable/ic_search_white_24dp"
+ app:showAsAction="ifRoom" />
+
+ <item
android:id="@+id/action_refresh_main_activity"
android:orderInCategory="2"
android:title="@string/action_refresh"
- android:icon="@drawable/ic_refresh_white_24dp"
app:showAsAction="never" />
<item
- android:id="@+id/action_search_main_activity"
- android:orderInCategory="1"
- android:title="@string/action_search"
- android:icon="@drawable/ic_search_white_24dp"
- app:showAsAction="ifRoom" />
+ android:id="@+id/action_lazy_mode_main_activity"
+ android:orderInCategory="3"
+ android:title="@string/action_start_lazy_mode"
+ app:showAsAction="never" />
</menu> \ No newline at end of file
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index bf1a320d..0d23c7ca 100644
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -10,6 +10,8 @@
<string name="action_download">Download</string>
<string name="action_refresh">Refresh</string>
<string name="action_search">Search</string>
+ <string name="action_start_lazy_mode">Start Lazy Mode</string>
+ <string name="action_stop_lazy_mode">Stop Lazy Mode</string>
<string name="tap_to_retry">Error loading image. Tap to retry.</string>
<string name="load_posts_error">Error loading posts.\nTap to retry.</string>
@@ -63,4 +65,7 @@
<string name="app_label">Infinity</string>
<string name="search_hint">Search anything</string>
+ <string name="lazy_mode_start">Lazy Mode starts in %1$fs</string>
+ <string name="lazy_mode_stop">Lazy Mode stopped</string>
+
</resources>