aboutsummaryrefslogtreecommitdiff
path: root/app/src/main/res/layout
diff options
context:
space:
mode:
authorAlex Ning <chineseperson5@gmail.com>2019-05-07 15:55:49 +0000
committerAlex Ning <chineseperson5@gmail.com>2019-05-07 15:55:49 +0000
commitc8d1a9e37ada68835838440ce7c25b0ee96798b5 (patch)
treec0c1894dc746149846f42eb1b8f7079b546434c2 /app/src/main/res/layout
parent297db53aa3038e4486a8fc199425a77476c9cb06 (diff)
downloadinfinity-for-reddit-c8d1a9e37ada68835838440ce7c25b0ee96798b5.tar
infinity-for-reddit-c8d1a9e37ada68835838440ce7c25b0ee96798b5.tar.gz
infinity-for-reddit-c8d1a9e37ada68835838440ce7c25b0ee96798b5.tar.bz2
infinity-for-reddit-c8d1a9e37ada68835838440ce7c25b0ee96798b5.tar.lz
infinity-for-reddit-c8d1a9e37ada68835838440ce7c25b0ee96798b5.tar.xz
infinity-for-reddit-c8d1a9e37ada68835838440ce7c25b0ee96798b5.tar.zst
infinity-for-reddit-c8d1a9e37ada68835838440ce7c25b0ee96798b5.zip
Dark theme support.
Diffstat (limited to 'app/src/main/res/layout')
-rw-r--r--app/src/main/res/layout/activity_main.xml7
-rw-r--r--app/src/main/res/layout/activity_view_post_detail.xml14
-rw-r--r--app/src/main/res/layout/activity_view_subreddit_detail.xml8
-rw-r--r--app/src/main/res/layout/activity_view_user_detail.xml6
-rw-r--r--app/src/main/res/layout/fragment_post.xml1
-rw-r--r--app/src/main/res/layout/item_comment.xml231
-rw-r--r--app/src/main/res/layout/item_post.xml9
-rw-r--r--app/src/main/res/layout/item_subreddit_listing.xml5
-rw-r--r--app/src/main/res/layout/item_subscribed_thing.xml (renamed from app/src/main/res/layout/item_subscribed_subreddit.xml)2
-rw-r--r--app/src/main/res/layout/item_user_listing.xml5
10 files changed, 148 insertions, 140 deletions
diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml
index 12eff6dc..f0ba107e 100644
--- a/app/src/main/res/layout/activity_main.xml
+++ b/app/src/main/res/layout/activity_main.xml
@@ -46,21 +46,22 @@
android:layout_height="24dp"
android:layout_gravity="center_vertical"
android:layout_marginEnd="32dp"
- android:src="@drawable/ic_outline_account_circle_24px" />
+ android:src="@drawable/ic_outline_account_circle_24px"
+ android:tint="@color/primaryTextColor"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:text="@string/profile"
- android:textColor="@android:color/black" />
+ android:textColor="@color/primaryTextColor" />
</LinearLayout>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
- android:background="#E0E0E0" />
+ android:background="@color/dividerColor" />
<TextView
android:id="@+id/following_label_main_activity"
diff --git a/app/src/main/res/layout/activity_view_post_detail.xml b/app/src/main/res/layout/activity_view_post_detail.xml
index 1fe7d3cd..b840e22e 100644
--- a/app/src/main/res/layout/activity_view_post_detail.xml
+++ b/app/src/main/res/layout/activity_view_post_detail.xml
@@ -78,7 +78,7 @@
android:layout_height="wrap_content"
android:paddingStart="16dp"
android:paddingEnd="16dp"
- android:textColor="#000000"
+ android:textColor="@color/primaryTextColor"
android:textSize="18sp" />
<ru.noties.markwon.view.MarkwonView
@@ -104,7 +104,7 @@
android:layout_marginEnd="8dp"
android:textColor="@android:color/white"
android:layout_centerVertical="true"
- app:chipBackgroundColor="@color/colorPrimaryDark"/>
+ app:chipBackgroundColor="@color/backgroundColorPrimaryDark"/>
<ImageView
android:id="@+id/gilded_image_view_view_post_detail"
@@ -197,9 +197,10 @@
android:layout_width="match_parent"
android:layout_height="150dp"
android:layout_marginTop="16dp"
- android:background="#E0E0E0"
+ android:background="@color/grey"
android:scaleType="center"
android:src="@drawable/ic_link"
+ android:tint="@android:color/tab_indicator_text"
android:visibility="gone" />
<RelativeLayout
@@ -267,9 +268,10 @@
android:layout_marginBottom="16dp"
app:mlpb_progress_stoke_width="3dp"
app:mlpb_progress_color="@color/colorAccent"
+ app:mlpb_background_color="@color/circularProgressBarBackground"
android:layout_gravity="center_horizontal"/>
- <androidx.cardview.widget.CardView
+ <com.google.android.material.card.MaterialCardView
android:id="@+id/comment_card_view_view_post_detail"
android:layout_width="match_parent"
android:layout_height="wrap_content"
@@ -290,7 +292,7 @@
android:paddingStart="16dp"
android:paddingTop="16dp"
android:text="@string/comments"
- android:textColor="#000000"
+ android:textColor="@color/primaryTextColor"
android:textSize="18sp" />
<com.multilevelview.MultiLevelRecyclerView
@@ -300,7 +302,7 @@
</LinearLayout>
- </androidx.cardview.widget.CardView>
+ </com.google.android.material.card.MaterialCardView>
<LinearLayout
android:id="@+id/no_comment_wrapper_linear_layout_view_post_detail"
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 5fff46ca..ac76d15b 100644
--- a/app/src/main/res/layout/activity_view_subreddit_detail.xml
+++ b/app/src/main/res/layout/activity_view_subreddit_detail.xml
@@ -48,7 +48,7 @@
android:paddingStart="16dp"
android:paddingEnd="16dp"
android:layout_below="@id/banner_image_view_view_subreddit_detail_activity"
- android:background="@android:color/white">
+ android:background="@color/backgroundColor">
<TextView
android:id="@+id/subreddit_name_text_view_view_subreddit_detail_activity"
@@ -77,7 +77,7 @@
android:id="@+id/subscriber_count_text_view_view_subreddit_detail_activity"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:textColor="@android:color/black"
+ android:textColor="@color/primaryTextColor"
android:layout_alignParentStart="true"
android:layout_toStartOf="@id/online_subscriber_count_text_view_view_subreddit_detail_activity" />
@@ -86,7 +86,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentEnd="true"
- android:textColor="@android:color/black" />
+ android:textColor="@color/primaryTextColor" />
</RelativeLayout>
@@ -95,7 +95,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="16dp"
- android:textColor="@android:color/black"
+ android:textColor="@color/primaryTextColor"
android:visibility="gone"/>
</LinearLayout>
diff --git a/app/src/main/res/layout/activity_view_user_detail.xml b/app/src/main/res/layout/activity_view_user_detail.xml
index 9bd70a72..70b225f8 100644
--- a/app/src/main/res/layout/activity_view_user_detail.xml
+++ b/app/src/main/res/layout/activity_view_user_detail.xml
@@ -48,7 +48,7 @@
android:paddingStart="16dp"
android:paddingEnd="16dp"
android:layout_below="@id/banner_image_view_view_user_detail_activity"
- android:background="@android:color/white">
+ android:background="@color/backgroundColor">
<TextView
android:id="@+id/user_name_text_view_view_user_detail_activity"
@@ -56,7 +56,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:textSize="18sp"
- android:textColor="@color/colorPrimaryDark"
+ android:textColor="@color/textColorPrimaryDark"
android:layout_gravity="center_horizontal"/>
<TextView
@@ -65,7 +65,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:layout_marginBottom="16dp"
- android:textColor="@android:color/black"
+ android:textColor="@color/primaryTextColor"
android:layout_gravity="center_horizontal"/>
<com.google.android.material.chip.Chip
diff --git a/app/src/main/res/layout/fragment_post.xml b/app/src/main/res/layout/fragment_post.xml
index ad9e23d7..0ab81ef0 100644
--- a/app/src/main/res/layout/fragment_post.xml
+++ b/app/src/main/res/layout/fragment_post.xml
@@ -14,6 +14,7 @@
android:layout_marginBottom="16dp"
app:mlpb_progress_stoke_width="3dp"
app:mlpb_progress_color="@color/colorAccent"
+ app:mlpb_background_color="@color/circularProgressBarBackground"
android:layout_gravity="center_horizontal"/>
<androidx.recyclerview.widget.RecyclerView
diff --git a/app/src/main/res/layout/item_comment.xml b/app/src/main/res/layout/item_comment.xml
index 81748bbd..c5bb40bc 100644
--- a/app/src/main/res/layout/item_comment.xml
+++ b/app/src/main/res/layout/item_comment.xml
@@ -1,129 +1,134 @@
<?xml version="1.0" encoding="utf-8"?>
-<LinearLayout
- xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:id="@+id/linear_layout_item_post_comment">
-
- <View
- android:id="@+id/vertical_block_item_post_comment"
- android:layout_width="0dp"
- android:layout_height="match_parent"
- android:background="@color/colorPrimary"/>
+<com.google.android.material.card.MaterialCardView xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content">
<LinearLayout
android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_marginTop="12dp"
- android:layout_marginBottom="12dp"
- android:orientation="vertical">
+ android:layout_height="wrap_content">
- <LinearLayout
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_marginStart="16dp"
- android:layout_marginEnd="16dp">
+ <View
+ android:id="@+id/vertical_block_item_post_comment"
+ android:layout_width="0dp"
+ android:layout_height="match_parent"
+ android:background="@color/textColorPrimaryDark"/>
- <TextView
- android:id="@+id/author_text_view_item_post_comment"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:layout_weight="1"
- android:layout_marginEnd="16dp"
- android:textColor="@color/colorPrimary"/>
-
- <TextView
- android:id="@+id/comment_time_text_view_item_post_comment"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:layout_weight="1"
- android:gravity="end" />
-
- </LinearLayout>
-
- <ru.noties.markwon.view.MarkwonView
- android:id="@+id/comment_markdown_view_item_post_comment"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_marginTop="8dp"
- android:layout_marginStart="32dp"
- android:layout_marginEnd="32dp"
- android:layout_marginBottom="8dp"
- android:textColor="@android:color/black"/>
-
- <RelativeLayout
- android:id="@+id/relative_layout_item_post_comment"
+ <LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginStart="16dp"
- android:layout_marginEnd="16dp">
+ android:layout_marginTop="12dp"
+ android:layout_marginBottom="12dp"
+ android:orientation="vertical">
- <ImageView
- android:id="@+id/plus_button_item_post_comment"
- android:layout_width="wrap_content"
+ <LinearLayout
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_alignParentStart="true"
- android:src="@drawable/ic_arrow_upward_black_20dp"
- android:layout_centerVertical="true"
- android:tint="@android:color/tab_indicator_text"
- android:background="?actionBarItemBackground"
- android:clickable="true"
- android:focusable="true"/>
-
- <TextView
- android:id="@+id/score_text_view_item_post_comment"
- android:layout_width="64dp"
+ android:layout_marginStart="16dp"
+ android:layout_marginEnd="16dp">
+
+ <TextView
+ android:id="@+id/author_text_view_item_post_comment"
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:layout_marginEnd="16dp"
+ android:textColor="@color/textColorPrimaryDark"/>
+
+ <TextView
+ android:id="@+id/comment_time_text_view_item_post_comment"
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:gravity="end" />
+
+ </LinearLayout>
+
+ <ru.noties.markwon.view.MarkwonView
+ android:id="@+id/comment_markdown_view_item_post_comment"
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_centerVertical="true"
- android:layout_toEndOf="@id/plus_button_item_post_comment"
- android:gravity="center"/>
-
- <ImageView
- android:id="@+id/minus_button_item_post_comment"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_centerVertical="true"
- android:layout_toEndOf="@id/score_text_view_item_post_comment"
- android:src="@drawable/ic_arrow_downward_black_20dp"
- android:tint="@android:color/tab_indicator_text"
- android:background="?actionBarItemBackground"
- android:clickable="true"
- android:focusable="true"/>
-
- <ProgressBar
- android:id="@+id/load_more_comments_progress_bar"
- android:layout_width="20dp"
- android:layout_height="20dp"
- android:layout_marginEnd="16dp"
- android:layout_toStartOf="@id/expand_button_item_post_comment"
- android:visibility="gone"/>
-
- <ImageView
- android:id="@+id/expand_button_item_post_comment"
- android:layout_width="wrap_content"
+ android:layout_marginTop="8dp"
+ android:layout_marginStart="32dp"
+ android:layout_marginEnd="32dp"
+ android:layout_marginBottom="8dp"
+ android:textColor="@color/primaryTextColor"/>
+
+ <RelativeLayout
+ android:id="@+id/relative_layout_item_post_comment"
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_toStartOf="@id/reply_button_item_post_comment"
- android:layout_centerVertical="true"
- android:layout_marginEnd="16dp"
- android:tint="@android:color/tab_indicator_text"
- android:background="?actionBarItemBackground"
- android:clickable="true"
- android:focusable="true"
- android:visibility="gone"/>
-
- <ImageView
- android:id="@+id/reply_button_item_post_comment"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_centerVertical="true"
- android:layout_alignParentEnd="true"
- android:src="@drawable/ic_reply_black_20dp"
- android:tint="@android:color/tab_indicator_text"
- android:background="?actionBarItemBackground"
- android:clickable="true"
- android:focusable="true"/>
+ android:layout_marginStart="16dp"
+ android:layout_marginEnd="16dp">
+
+ <ImageView
+ android:id="@+id/plus_button_item_post_comment"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentStart="true"
+ android:src="@drawable/ic_arrow_upward_black_20dp"
+ android:layout_centerVertical="true"
+ android:tint="@android:color/tab_indicator_text"
+ android:background="?actionBarItemBackground"
+ android:clickable="true"
+ android:focusable="true"/>
+
+ <TextView
+ android:id="@+id/score_text_view_item_post_comment"
+ android:layout_width="64dp"
+ android:layout_height="wrap_content"
+ android:layout_centerVertical="true"
+ android:layout_toEndOf="@id/plus_button_item_post_comment"
+ android:gravity="center"/>
+
+ <ImageView
+ android:id="@+id/minus_button_item_post_comment"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_centerVertical="true"
+ android:layout_toEndOf="@id/score_text_view_item_post_comment"
+ android:src="@drawable/ic_arrow_downward_black_20dp"
+ android:tint="@android:color/tab_indicator_text"
+ android:background="?actionBarItemBackground"
+ android:clickable="true"
+ android:focusable="true"/>
+
+ <ProgressBar
+ android:id="@+id/load_more_comments_progress_bar"
+ android:layout_width="20dp"
+ android:layout_height="20dp"
+ android:layout_marginEnd="16dp"
+ android:layout_toStartOf="@id/expand_button_item_post_comment"
+ android:visibility="gone"/>
+
+ <ImageView
+ android:id="@+id/expand_button_item_post_comment"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_toStartOf="@id/reply_button_item_post_comment"
+ android:layout_centerVertical="true"
+ android:layout_marginEnd="16dp"
+ android:tint="@android:color/tab_indicator_text"
+ android:background="?actionBarItemBackground"
+ android:clickable="true"
+ android:focusable="true"
+ android:visibility="gone"/>
+
+ <ImageView
+ android:id="@+id/reply_button_item_post_comment"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_centerVertical="true"
+ android:layout_alignParentEnd="true"
+ android:src="@drawable/ic_reply_black_20dp"
+ android:tint="@android:color/tab_indicator_text"
+ android:background="?actionBarItemBackground"
+ android:clickable="true"
+ android:focusable="true"/>
+
+ </RelativeLayout>
- </RelativeLayout>
+ </LinearLayout>
</LinearLayout>
-</LinearLayout> \ No newline at end of file
+</com.google.android.material.card.MaterialCardView> \ No newline at end of file
diff --git a/app/src/main/res/layout/item_post.xml b/app/src/main/res/layout/item_post.xml
index 02c8ce23..8f1beb79 100644
--- a/app/src/main/res/layout/item_post.xml
+++ b/app/src/main/res/layout/item_post.xml
@@ -50,7 +50,7 @@
android:layout_height="24dp"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
- android:tint="@color/colorPrimary"
+ android:tint="@color/textColorPrimaryDark"
android:visibility="gone"
app:layout_constraintStart_toEndOf="@id/subreddit_icon_name_linear_layout_view_item_best_post"
app:layout_constraintEnd_toStartOf="@+id/post_time_text_view_best_post_item"
@@ -77,7 +77,7 @@
android:paddingStart="16dp"
android:paddingEnd="16dp"
android:textSize="18sp"
- android:textColor="#000000"/>
+ android:textColor="@color/primaryTextColor"/>
<RelativeLayout
android:layout_width="match_parent"
@@ -93,7 +93,7 @@
android:layout_marginEnd="16dp"
android:textColor="@android:color/white"
android:layout_centerVertical="true"
- app:chipBackgroundColor="@color/colorPrimaryDark" />
+ app:chipBackgroundColor="@color/backgroundColorPrimaryDark" />
<ImageView
android:id="@+id/gilded_image_view_item_best_post"
@@ -187,7 +187,8 @@
android:layout_marginTop="16dp"
android:scaleType="center"
android:src="@drawable/ic_link"
- android:background="#E0E0E0"
+ android:tint="@android:color/tab_indicator_text"
+ android:background="@color/grey"
android:visibility="gone"/>
<RelativeLayout
diff --git a/app/src/main/res/layout/item_subreddit_listing.xml b/app/src/main/res/layout/item_subreddit_listing.xml
index 10d5055a..52409bfb 100644
--- a/app/src/main/res/layout/item_subreddit_listing.xml
+++ b/app/src/main/res/layout/item_subreddit_listing.xml
@@ -24,7 +24,7 @@
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_marginStart="32dp"
- android:textColor="@android:color/black"
+ android:textColor="@color/primaryTextColor"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toEndOf="@+id/subreddit_icon_gif_image_view_item_subreddit_listing"
app:layout_constraintTop_toTopOf="parent" />
@@ -34,9 +34,8 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
-
android:src="@drawable/baseline_add_white_24"
- android:tint="@color/colorPrimary"
+ android:tint="@color/textColorPrimaryDark"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
diff --git a/app/src/main/res/layout/item_subscribed_subreddit.xml b/app/src/main/res/layout/item_subscribed_thing.xml
index 0717c7c4..0f4afc20 100644
--- a/app/src/main/res/layout/item_subscribed_subreddit.xml
+++ b/app/src/main/res/layout/item_subscribed_thing.xml
@@ -18,7 +18,7 @@
android:id="@+id/subreddit_name_text_view_item_subscribed_subreddit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:textColor="@android:color/black"
+ android:textColor="@color/primaryTextColor"
android:layout_gravity="center_vertical"/>
</LinearLayout> \ No newline at end of file
diff --git a/app/src/main/res/layout/item_user_listing.xml b/app/src/main/res/layout/item_user_listing.xml
index 24ba6102..04b16bdc 100644
--- a/app/src/main/res/layout/item_user_listing.xml
+++ b/app/src/main/res/layout/item_user_listing.xml
@@ -24,7 +24,7 @@
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_marginStart="32dp"
- android:textColor="@android:color/black"
+ android:textColor="@color/primaryTextColor"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toEndOf="@+id/user_icon_gif_image_view_item_user_listing"
app:layout_constraintTop_toTopOf="parent" />
@@ -34,9 +34,8 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
-
android:src="@drawable/baseline_add_white_24"
- android:tint="@color/colorPrimary"
+ android:tint="@color/textColorPrimaryDark"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent"