mirror of
https://codeberg.org/Bazsalanszky/Infinity-For-Lemmy.git
synced 2025-10-05 21:39:50 +02:00
Prepare to add report feature.
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="18dp"
|
||||
android:height="18dp"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:pathData="M6,14c-0.55,0 -1,0.45 -1,1v3c0,0.55 0.45,1 1,1h3c0.55,0 1,-0.45 1,-1s-0.45,-1 -1,-1L7,17v-2c0,-0.55 -0.45,-1 -1,-1zM6,10c0.55,0 1,-0.45 1,-1L7,7h2c0.55,0 1,-0.45 1,-1s-0.45,-1 -1,-1L6,5c-0.55,0 -1,0.45 -1,1v3c0,0.55 0.45,1 1,1zM17,17h-2c-0.55,0 -1,0.45 -1,1s0.45,1 1,1h3c0.55,0 1,-0.45 1,-1v-3c0,-0.55 -0.45,-1 -1,-1s-1,0.45 -1,1v2zM14,6c0,0.55 0.45,1 1,1h2v2c0,0.55 0.45,1 1,1s1,-0.45 1,-1L19,6c0,-0.55 -0.45,-1 -1,-1h-3c-0.55,0 -1,0.45 -1,1z"
|
||||
android:fillColor="#FFFFFF"/>
|
||||
</vector>
|
31
app/src/main/res/layout/activity_report.xml
Normal file
31
app/src/main/res/layout/activity_report.xml
Normal file
@@ -0,0 +1,31 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/coordinator_layout_report_activity"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:application=".PostImageActivity">
|
||||
|
||||
<com.google.android.material.appbar.AppBarLayout
|
||||
android:id="@+id/appbar_layout_report_activity"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:theme="@style/AppTheme.AppBarOverlay">
|
||||
|
||||
<androidx.appcompat.widget.Toolbar
|
||||
android:id="@+id/toolbar_report_activity"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
app:navigationIcon="?attr/homeAsUpIndicator"
|
||||
app:popupTheme="@style/AppTheme.PopupOverlay" />
|
||||
|
||||
</com.google.android.material.appbar.AppBarLayout>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recycler_view_report_activity"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior" />
|
||||
|
||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
@@ -57,8 +57,16 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="8dp"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_toStartOf="@id/fullscreen_exo_playback_control_view"
|
||||
android:src="@drawable/ic_mute_white_rounded_18dp"
|
||||
android:visibility="gone" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/fullscreen_exo_playback_control_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="8dp"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:src="@drawable/ic_fullscreen_white_rounded_18dp" />
|
||||
|
||||
</RelativeLayout>
|
29
app/src/main/res/layout/item_report_reason.xml
Normal file
29
app/src/main/res/layout/item_report_reason.xml
Normal file
@@ -0,0 +1,29 @@
|
||||
<?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:paddingStart="16dp"
|
||||
android:paddingEnd="16dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:background="?attr/selectableItemBackground">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/reason_text_view_item_report_reason"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginEnd="32dp"
|
||||
android:textColor="?attr/primaryTextColor"
|
||||
android:textSize="?attr/font_default" />
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/check_box_item_report_reason"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical" />
|
||||
|
||||
</LinearLayout>
|
10
app/src/main/res/menu/report_activity.xml
Normal file
10
app/src/main/res/menu/report_activity.xml
Normal file
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<menu xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
<item
|
||||
android:id="@+id/action_send_report_activity"
|
||||
android:orderInCategory="1"
|
||||
android:title="@string/action_send"
|
||||
android:icon="@drawable/ic_send_toolbar_24dp"
|
||||
app:showAsAction="ifRoom" />
|
||||
</menu>
|
@@ -74,4 +74,11 @@
|
||||
android:title="@string/action_edit_flair"
|
||||
app:showAsAction="never"
|
||||
android:visible="false" />
|
||||
|
||||
<item
|
||||
android:id="@+id/action_report_view_post_detail_activity"
|
||||
android:orderInCategory="12"
|
||||
android:title="@string/action_report"
|
||||
app:showAsAction="never"
|
||||
android:visible="false" />
|
||||
</menu>
|
@@ -25,6 +25,7 @@
|
||||
<string name="theme_preview_activity_label">Theme Preview</string>
|
||||
<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="navigation_drawer_open">Open navigation drawer</string>
|
||||
<string name="navigation_drawer_close">Close navigation drawer</string>
|
||||
@@ -57,6 +58,7 @@
|
||||
<string name="action_delete_multi_reddit">Delete Multireddit</string>
|
||||
<string name="action_share">Share</string>
|
||||
<string name="action_preview">Preview</string>
|
||||
<string name="action_report">Report</string>
|
||||
|
||||
<string name="parse_json_response_error">Error occurred when parsing the JSON response</string>
|
||||
<string name="retrieve_token_error">Error Retrieving the token</string>
|
||||
@@ -702,4 +704,13 @@
|
||||
<string name="n_awards">%1$d Awards</string>
|
||||
<string name="one_award">1 Award</string>
|
||||
|
||||
<string name="report_successful">Reported</string>
|
||||
<string name="report_failed">Report failed</string>
|
||||
<string name="report_reason_not_selected">You haven\'t selected a reason</string>
|
||||
|
||||
<string name="report_reason_general_spam">Spam</string>
|
||||
<string name="report_reason_general_copyright_issue">Copyright Issue</string>
|
||||
<string name="report_reason_general_child_pornography">Child Pornography</string>
|
||||
<string name="report_reason_general_abusive_content">Abusive Content</string>
|
||||
|
||||
</resources>
|
||||
|
Reference in New Issue
Block a user