aboutsummaryrefslogtreecommitdiff
path: root/app/src/main/res
diff options
context:
space:
mode:
authorAlex Ning <chineseperson5@gmail.com>2021-01-06 08:40:27 +0000
committerAlex Ning <chineseperson5@gmail.com>2021-01-06 08:40:27 +0000
commit99129a2b144f1d2eddda49eb2e870ce41a52bee1 (patch)
treeff19e29451655b6d6830d72dec0fd790aeb4b9ef /app/src/main/res
parentb3da83e3735e974d14cbc002c562e33f58b846b2 (diff)
downloadinfinity-for-reddit-99129a2b144f1d2eddda49eb2e870ce41a52bee1.tar
infinity-for-reddit-99129a2b144f1d2eddda49eb2e870ce41a52bee1.tar.gz
infinity-for-reddit-99129a2b144f1d2eddda49eb2e870ce41a52bee1.tar.bz2
infinity-for-reddit-99129a2b144f1d2eddda49eb2e870ce41a52bee1.tar.lz
infinity-for-reddit-99129a2b144f1d2eddda49eb2e870ce41a52bee1.tar.xz
infinity-for-reddit-99129a2b144f1d2eddda49eb2e870ce41a52bee1.tar.zst
infinity-for-reddit-99129a2b144f1d2eddda49eb2e870ce41a52bee1.zip
Add two buttons to add subreddits and users in CustomizePostFilterActivity. Show search users and search subreddits when searching them.
Diffstat (limited to 'app/src/main/res')
-rw-r--r--app/src/main/res/layout/activity_customize_post_filter.xml93
-rw-r--r--app/src/main/res/values/strings.xml2
2 files changed, 65 insertions, 30 deletions
diff --git a/app/src/main/res/layout/activity_customize_post_filter.xml b/app/src/main/res/layout/activity_customize_post_filter.xml
index b7940c7a..7768b75c 100644
--- a/app/src/main/res/layout/activity_customize_post_filter.xml
+++ b/app/src/main/res/layout/activity_customize_post_filter.xml
@@ -343,45 +343,78 @@
</com.google.android.material.textfield.TextInputLayout>
- <com.google.android.material.textfield.TextInputLayout
- android:id="@+id/excludes_subreddits_text_input_layout_customize_post_filter_activity"
+ <LinearLayout
android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:paddingTop="8dp"
- android:paddingBottom="8dp"
- android:paddingStart="16dp"
- android:paddingEnd="16dp"
- style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox">
+ android:layout_height="wrap_content">
- <com.google.android.material.textfield.TextInputEditText
- android:id="@+id/excludes_subreddits_text_input_edit_text_customize_post_filter_activity"
- android:layout_width="match_parent"
+ <com.google.android.material.textfield.TextInputLayout
+ android:id="@+id/excludes_subreddits_text_input_layout_customize_post_filter_activity"
+ android:layout_width="0dp"
android:layout_height="wrap_content"
- android:fontFamily="?attr/font_family"
- android:textSize="?attr/font_default"
- android:hint="@string/exclude_subreddits_hint" />
+ android:layout_weight="1"
+ android:paddingTop="8dp"
+ android:paddingBottom="8dp"
+ android:layout_marginStart="16dp"
+ style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox">
+
+ <com.google.android.material.textfield.TextInputEditText
+ android:id="@+id/excludes_subreddits_text_input_edit_text_customize_post_filter_activity"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:fontFamily="?attr/font_family"
+ android:textSize="?attr/font_default"
+ android:hint="@string/exclude_subreddits_hint" />
+
+ </com.google.android.material.textfield.TextInputLayout>
+
+ <ImageView
+ android:id="@+id/add_subreddits_image_view_customize_post_filter_activity"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_gravity="center_vertical"
+ android:padding="16dp"
+ android:background="?actionBarItemBackground"
+ android:clickable="true"
+ android:focusable="true" />
- </com.google.android.material.textfield.TextInputLayout>
+ </LinearLayout>
- <com.google.android.material.textfield.TextInputLayout
- android:id="@+id/excludes_users_text_input_layout_customize_post_filter_activity"
+ <LinearLayout
android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:paddingTop="8dp"
- android:paddingBottom="8dp"
- android:paddingStart="16dp"
- android:paddingEnd="16dp"
- style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox">
+ android:layout_height="wrap_content">
- <com.google.android.material.textfield.TextInputEditText
- android:id="@+id/excludes_users_text_input_edit_text_customize_post_filter_activity"
- android:layout_width="match_parent"
+ <com.google.android.material.textfield.TextInputLayout
+ android:id="@+id/excludes_users_text_input_layout_customize_post_filter_activity"
+ android:layout_width="0dp"
android:layout_height="wrap_content"
- android:fontFamily="?attr/font_family"
- android:textSize="?attr/font_default"
- android:hint="@string/exclude_users_hint" />
+ android:layout_weight="1"
+ android:paddingTop="8dp"
+ android:paddingBottom="8dp"
+ android:layout_marginStart="16dp"
+ style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox">
+
+ <com.google.android.material.textfield.TextInputEditText
+ android:id="@+id/excludes_users_text_input_edit_text_customize_post_filter_activity"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:fontFamily="?attr/font_family"
+ android:textSize="?attr/font_default"
+ android:hint="@string/exclude_users_hint" />
+
+ </com.google.android.material.textfield.TextInputLayout>
+
+ <ImageView
+ android:id="@+id/add_users_image_view_customize_post_filter_activity"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_gravity="center_vertical"
+ android:padding="16dp"
+ android:background="?actionBarItemBackground"
+ android:clickable="true"
+ android:focusable="true" />
- </com.google.android.material.textfield.TextInputLayout>
+ </LinearLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/excludes_flairs_text_input_layout_customize_post_filter_activity"
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index 29d5930c..957b5a48 100644
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -150,6 +150,8 @@
<string name="app_label">Infinity</string>
<string name="search_hint">Search anything</string>
+ <string name="search_only_subreddits_hint">Search subreddits</string>
+ <string name="search_only_users_hint">Search users</string>
<string name="no_posts_no_lazy_mode">No posts available</string>
<string name="lazy_mode_start">Lazy Mode starts in %1$.1fs</string>