diff options
Diffstat (limited to 'app/src/main/res')
-rw-r--r-- | app/src/main/res/layout/item_post_card_2_gallery_type.xml | 309 | ||||
-rw-r--r-- | app/src/main/res/layout/item_post_gallery_gallery_type.xml | 47 | ||||
-rw-r--r-- | app/src/main/res/layout/item_post_gallery_type.xml | 26 | ||||
-rw-r--r-- | app/src/main/res/values/strings.xml | 34 |
4 files changed, 397 insertions, 19 deletions
diff --git a/app/src/main/res/layout/item_post_card_2_gallery_type.xml b/app/src/main/res/layout/item_post_card_2_gallery_type.xml new file mode 100644 index 00000000..1455d1fd --- /dev/null +++ b/app/src/main/res/layout/item_post_card_2_gallery_type.xml @@ -0,0 +1,309 @@ +<?xml version="1.0" encoding="utf-8"?> +<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + android:layout_width="match_parent" + android:layout_height="wrap_content" + xmlns:tools="http://schemas.android.com/tools" + android:paddingTop="16dp" + android:clickable="true" + android:focusable="true" + android:background="?attr/selectableItemBackground" + android:orientation="vertical"> + + <com.google.android.material.card.MaterialCardView + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginStart="16dp" + android:layout_marginEnd="16dp" + app:cardElevation="2dp" + app:cardCornerRadius="8dp" + style="?attr/materialCardViewElevatedStyle"> + + <FrameLayout + android:id="@+id/gallery_frame_layout_item_post_card_2_gallery_type" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:visibility="gone"> + + <androidx.recyclerview.widget.RecyclerView + android:id="@+id/gallery_recycler_view_item_post_card_2_gallery_type" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="horizontal" /> + + <com.libRG.CustomTextView + android:id="@+id/image_index_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_margin="16dp" + android:textSize="?attr/font_12" + android:fontFamily="?attr/font_family" + android:padding="4dp" + app:lib_setRadius="6dp" + app:lib_setRoundedView="true" + app:lib_setShape="rectangle" /> + + </FrameLayout> + + <ImageView + android:id="@+id/no_preview_image_view_item_post_card_2_gallery_type" + android:layout_width="match_parent" + android:layout_height="150dp" + android:scaleType="center" + android:visibility="gone" /> + + </com.google.android.material.card.MaterialCardView> + + <TextView + android:id="@+id/title_text_view_item_post_card_2_gallery_type" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="16dp" + android:paddingStart="16dp" + android:paddingEnd="16dp" + android:textSize="?attr/title_font_18" + android:fontFamily="?attr/title_font_family" /> + + <com.nex3z.flowlayout.FlowLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:padding="16dp" + app:flRowVerticalGravity="center" + app:flChildSpacing="16dp" + app:flChildSpacingForLastRow="align" + app:flRowSpacing="8dp"> + + <com.libRG.CustomTextView + android:id="@+id/type_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:padding="4dp" + android:text="@string/gallery" + android:textSize="?attr/font_12" + android:fontFamily="?attr/font_family" + app:lib_setRadius="6dp" + app:lib_setRoundedView="true" + app:lib_setShape="rectangle" /> + + <com.libRG.CustomTextView + android:id="@+id/spoiler_custom_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_gravity="center" + android:text="@string/spoiler" + android:textSize="?attr/font_12" + android:fontFamily="?attr/font_family" + android:padding="4dp" + android:visibility="gone" + app:lib_setRadius="6dp" + app:lib_setRoundedView="true" + app:lib_setShape="rectangle" /> + + <com.libRG.CustomTextView + android:id="@+id/nsfw_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:padding="4dp" + android:text="@string/nsfw" + android:textSize="?attr/font_12" + android:fontFamily="?attr/font_family" + android:visibility="gone" + app:lib_setRadius="6dp" + app:lib_setRoundedView="true" + app:lib_setShape="rectangle" /> + + <com.libRG.CustomTextView + android:id="@+id/flair_custom_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_gravity="center" + android:textSize="?attr/font_12" + android:fontFamily="?attr/font_family" + android:padding="4dp" + android:visibility="gone" + app:lib_setRadius="6dp" + app:lib_setRoundedView="true" + app:lib_setShape="rectangle" /> + + <com.libRG.CustomTextView + android:id="@+id/awards_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:padding="4dp" + android:textSize="?attr/font_12" + android:fontFamily="?attr/font_family" + android:visibility="gone" + app:lib_setRadius="6dp" + app:lib_setRoundedView="true" + app:lib_setShape="rectangle" /> + + <ImageView + android:id="@+id/archived_image_view_item_post_card_2_gallery_type" + android:layout_width="24dp" + android:layout_height="24dp" + android:src="@drawable/ic_archive_outline" + android:visibility="gone" /> + + <ImageView + android:id="@+id/locked_image_view_item_post_card_2_gallery_type" + android:layout_width="24dp" + android:layout_height="24dp" + android:src="@drawable/ic_outline_lock_24dp" + android:visibility="gone" /> + + <ImageView + android:id="@+id/crosspost_image_view_item_post_card_2_gallery_type" + android:layout_width="24dp" + android:layout_height="24dp" + android:src="@drawable/crosspost" + android:visibility="gone" /> + + <ImageView + android:id="@+id/stickied_post_image_view_item_post_card_2_gallery_type" + android:layout_width="24dp" + android:layout_height="24dp" + android:visibility="gone" + tools:visibility="visible" /> + + <TextView + android:id="@+id/link_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textSize="?attr/font_12" + android:fontFamily="?attr/font_family" + android:visibility="gone" /> + + <TextView + android:id="@+id/post_time_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textSize="?attr/font_default" + android:fontFamily="?attr/font_family" /> + + </com.nex3z.flowlayout.FlowLayout> + + <com.nex3z.flowlayout.FlowLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:paddingStart="16dp" + android:paddingEnd="16dp" + app:flRowVerticalGravity="center" + app:flChildSpacing="16dp" + app:flChildSpacingForLastRow="align" + app:flRowSpacing="8dp"> + + <ml.docilealligator.infinityforreddit.customviews.AspectRatioGifImageView + android:id="@+id/icon_gif_image_view_item_post_card_2_gallery_type" + android:layout_width="24dp" + android:layout_height="24dp" /> + + <TextView + android:id="@+id/subreddit_name_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textSize="?attr/font_default" + android:fontFamily="?attr/font_family" /> + + <TextView + android:id="@+id/user_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textSize="?attr/font_default" + android:fontFamily="?attr/font_family" /> + + </com.nex3z.flowlayout.FlowLayout> + + <androidx.constraintlayout.widget.ConstraintLayout + android:id="@+id/bottom_constraint_layout_item_post_card_2_gallery_type" + android:layout_width="match_parent" + android:layout_height="wrap_content"> + + <ImageView + android:id="@+id/upvote_button_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:padding="12dp" + android:src="@drawable/ic_arrow_upward_grey_24dp" + android:background="?actionBarItemBackground" + android:clickable="true" + android:focusable="true" + app:layout_constraintTop_toTopOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintStart_toStartOf="parent" /> + + <TextView + android:id="@+id/score_text_view_item_post_card_2_gallery_type" + android:layout_width="64dp" + android:layout_height="wrap_content" + android:gravity="center" + android:textSize="?attr/font_12" + android:textStyle="bold" + android:fontFamily="?attr/font_family" + app:layout_constraintTop_toTopOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintStart_toEndOf="@id/upvote_button_item_post_card_2_gallery_type" /> + + <ImageView + android:id="@+id/downvote_button_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:padding="12dp" + android:src="@drawable/ic_arrow_downward_grey_24dp" + android:background="?actionBarItemBackground" + android:clickable="true" + android:focusable="true" + app:layout_constraintTop_toTopOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintStart_toEndOf="@id/score_text_view_item_post_card_2_gallery_type" /> + + <TextView + android:id="@+id/comments_count_text_view_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:padding="12dp" + android:gravity="center_vertical" + android:textSize="?attr/font_12" + android:textStyle="bold" + android:fontFamily="?attr/font_family" + android:drawableStart="@drawable/ic_comment_grey_24dp" + android:drawablePadding="12dp" + app:layout_constraintTop_toTopOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintStart_toEndOf="@id/downvote_button_item_post_card_2_gallery_type" /> + + <ImageView + android:id="@+id/save_button_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:padding="12dp" + android:background="?actionBarItemBackground" + android:clickable="true" + android:focusable="true" + app:layout_constraintHorizontal_bias="1" + app:layout_constraintTop_toTopOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintStart_toEndOf="@id/comments_count_text_view_item_post_card_2_gallery_type" + app:layout_constraintEnd_toStartOf="@id/share_button_item_post_card_2_gallery_type" /> + + <ImageView + android:id="@+id/share_button_item_post_card_2_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:padding="12dp" + android:src="@drawable/ic_share_grey_24dp" + android:background="?actionBarItemBackground" + android:clickable="true" + android:focusable="true" + app:layout_constraintTop_toTopOf="parent" + app:layout_constraintBottom_toBottomOf="parent" + app:layout_constraintEnd_toEndOf="parent" /> + + </androidx.constraintlayout.widget.ConstraintLayout> + + <View + android:id="@+id/divider_item_post_card_2_gallery_type" + android:layout_width="match_parent" + android:layout_height="1dp" + android:paddingBottom="8dp" /> + +</LinearLayout>
\ No newline at end of file diff --git a/app/src/main/res/layout/item_post_gallery_gallery_type.xml b/app/src/main/res/layout/item_post_gallery_gallery_type.xml new file mode 100644 index 00000000..d1ee61b6 --- /dev/null +++ b/app/src/main/res/layout/item_post_gallery_gallery_type.xml @@ -0,0 +1,47 @@ +<?xml version="1.0" encoding="utf-8"?> +<com.google.android.material.card.MaterialCardView xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + android:layout_width="match_parent" + android:layout_height="wrap_content" + xmlns:tools="http://schemas.android.com/tools" + android:layout_marginTop="8dp" + android:layout_marginBottom="8dp" + app:cardElevation="2dp" + app:cardCornerRadius="8dp" + style="?attr/materialCardViewElevatedStyle"> + + <FrameLayout + android:id="@+id/gallery_frame_layout_item_post_gallery_gallery_type" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:visibility="gone"> + + <androidx.recyclerview.widget.RecyclerView + android:id="@+id/gallery_recycler_view_item_post_gallery_gallery_type" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="horizontal" /> + + <com.libRG.CustomTextView + android:id="@+id/image_index_text_view_item_post_gallery_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_margin="16dp" + android:textSize="?attr/font_12" + android:fontFamily="?attr/font_family" + android:padding="4dp" + app:lib_setRadius="6dp" + app:lib_setRoundedView="true" + app:lib_setShape="rectangle" /> + + </FrameLayout> + + <ImageView + android:id="@+id/image_view_no_preview_item_post_gallery_gallery_type" + android:layout_width="match_parent" + android:layout_height="150dp" + android:scaleType="center" + android:background="@drawable/thumbnail_compact_layout_rounded_edge" + android:visibility="gone" /> + +</com.google.android.material.card.MaterialCardView>
\ No newline at end of file diff --git a/app/src/main/res/layout/item_post_gallery_type.xml b/app/src/main/res/layout/item_post_gallery_type.xml index 4ea4579c..13bd9517 100644 --- a/app/src/main/res/layout/item_post_gallery_type.xml +++ b/app/src/main/res/layout/item_post_gallery_type.xml @@ -196,11 +196,31 @@ </com.nex3z.flowlayout.FlowLayout> - <androidx.recyclerview.widget.RecyclerView - android:id="@+id/gallery_recycler_view_item_post_gallery_type" + <FrameLayout + android:id="@+id/gallery_frame_layout_item_post_gallery_type" android:layout_width="match_parent" android:layout_height="wrap_content" - android:orientation="horizontal" /> + android:visibility="gone"> + + <androidx.recyclerview.widget.RecyclerView + android:id="@+id/gallery_recycler_view_item_post_gallery_type" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="horizontal" /> + + <com.libRG.CustomTextView + android:id="@+id/image_index_text_view_item_post_gallery_type" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_margin="16dp" + android:textSize="?attr/font_12" + android:fontFamily="?attr/font_family" + android:padding="4dp" + app:lib_setRadius="6dp" + app:lib_setRoundedView="true" + app:lib_setShape="rectangle" /> + + </FrameLayout> <ImageView android:id="@+id/no_preview_image_view_item_post_gallery_type" diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index f7bb044b..bdcba30e 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -25,12 +25,12 @@ <string name="edit_multi_reddit_activity_label">Edit Multireddit</string> <string name="selected_subeddits_activity_label">Selected Subreddits</string> <string name="report_activity_label">Report</string> - <string name="view_imgur_media_activity_image_label">Image %1$,d/%2$d</string> - <string name="view_imgur_media_activity_video_label">Video %1$,d/%2$d</string> + <string name="view_imgur_media_activity_image_label">Image %1$d/%2$d</string> + <string name="view_imgur_media_activity_video_label">Video %1$d/%2$d</string> <string name="send_private_message_activity_label">Send PM</string> - <string name="view_reddit_gallery_activity_image_label">Image %1$,d/%2$d</string> - <string name="view_reddit_gallery_activity_gif_label">Gif %1$,d/%2$d</string> - <string name="view_reddit_gallery_activity_video_label">Video %1$,d/%2$d</string> + <string name="view_reddit_gallery_activity_image_label">Image %1$d/%2$d</string> + <string name="view_reddit_gallery_activity_gif_label">Gif %1$d/%2$d</string> + <string name="view_reddit_gallery_activity_video_label">Video %1$d/%2$d</string> <string name="submit_crosspost_activity_label">Crosspost</string> <string name="give_award_activity_label">Give Award</string> <string name="subreddit_filter_popular_and_all_activity_label">r/all and r/popular</string> @@ -201,7 +201,7 @@ <string name="title_required">The post needs a good title</string> <string name="link_required">Hey where is the link?</string> <string name="select_an_image">Please select an image first</string> - <string name="voting_length">Voting length: %1$,d days</string> + <string name="voting_length">Voting length: %1$d days</string> <string name="posting">Posting</string> <string name="post_failed">Could not post it</string> <string name="error_processing_image">Error processing image</string> @@ -358,7 +358,7 @@ <string name="notification_summary_message">New Message</string> <string name="notification_summary_subreddit">Subreddit</string> <string name="notification_summary_award">Award</string> - <string name="notification_new_messages">%1$,d New Messages</string> + <string name="notification_new_messages">%1$d New Messages</string> <string name="label_account">Account</string> <string name="label_reddit">Reddit</string> @@ -382,9 +382,9 @@ <string name="settings_mute_autoplaying_videos_title">Mute Autoplaying Videos</string> <string name="settings_autoplay_nsfw_videos_title">Autoplay NSFW Videos</string> <string name="settings_start_autoplay_visible_area_offset_portrait_title">Autoplay Videos Visible Area Offset (Portrait)</string> - <string name="settings_start_autoplay_visible_area_offset_portrait_summary">Start autoplaying videos when %1$,d%% of them are visible</string> + <string name="settings_start_autoplay_visible_area_offset_portrait_summary">Start autoplaying videos when %1$d%% of them are visible</string> <string name="settings_start_autoplay_visible_area_offset_landscape_title">Autoplay Videos Visible Area Offset (Landscape)</string> - <string name="settings_start_autoplay_visible_area_offset_landscape_summary">Start autoplaying videos when %1$,d%% of them are visible</string> + <string name="settings_start_autoplay_visible_area_offset_landscape_summary">Start autoplaying videos when %1$d%% of them are visible</string> <string name="settings_immersive_interface_title">Immersive Interface</string> <string name="settings_immersive_interface_summary">Does Not Apply to All Pages</string> <string name="settings_immersive_interface_ignore_nav_bar_title">Ignore Navigation Bar in Immersive Interface</string> @@ -636,7 +636,7 @@ <string name="settings_hide_text_post_content">Hide Text Post Content</string> <string name="settings_hide_comment_awards_title">Hide Comment Awards</string> <string name="settings_show_fewer_toolbar_options_threshold_title">Show Fewer Toolbar Options Starting From</string> - <string name="settings_show_fewer_toolbar_options_threshold_summary">Level %1$,d</string> + <string name="settings_show_fewer_toolbar_options_threshold_summary">Level %1$d</string> <string name="settings_show_author_avatar_title">Show Author Avatar</string> <string name="settings_reddit_user_agreement_title">Reddit User Agreement</string> <string name="settings_always_show_child_comment_count_title">Always Show the Number of Child Comments</string> @@ -688,15 +688,15 @@ <string name="elapsed_time_just_now">Just Now</string> <string name="elapsed_time_a_minute_ago">1 Minute</string> - <string name="elapsed_time_minutes_ago">%1$,d Minutes</string> + <string name="elapsed_time_minutes_ago">%1$d Minutes</string> <string name="elapsed_time_an_hour_ago">1 Hour</string> - <string name="elapsed_time_hours_ago">%1$,d Hours</string> + <string name="elapsed_time_hours_ago">%1$d Hours</string> <string name="elapsed_time_yesterday">Yesterday</string> - <string name="elapsed_time_days_ago">%1$,d Days</string> + <string name="elapsed_time_days_ago">%1$d Days</string> <string name="elapsed_time_a_month_ago">1 Month</string> - <string name="elapsed_time_months_ago">%1$,d Months</string> + <string name="elapsed_time_months_ago">%1$d Months</string> <string name="elapsed_time_a_year_ago">1 Year</string> - <string name="elapsed_time_years_ago">%1$,d Years</string> + <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> @@ -1077,7 +1077,7 @@ <string name="give_award_dialog_title">Give Award?</string> <string name="anonymous">Anonymous</string> - <string name="give_award_error_message">Code: %1$,d/\n Message: %2$s</string> + <string name="give_award_error_message">Code: %1$d/\n Message: %2$s</string> <string name="give_award_success">Award given</string> <string name="give_award_failed">Failed</string> @@ -1315,4 +1315,6 @@ <string name="load_more_posts_failed">Failed to load more posts.\nTap to retry.</string> <string name="no_more_posts">No more posts</string> + <string name="image_index_in_gallery">%1$d/%2$d</string> + </resources> |