mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 12:23:58 +01:00
New review layout UI for landscape view (#4412)
* ReviewActivity landscape layout created successfully * Minor issues fixed * minor modification * crash fixed
This commit is contained in:
parent
1408fe5e53
commit
b6ffe9ff06
1 changed files with 138 additions and 0 deletions
138
app/src/main/res/layout-land/activity_review.xml
Normal file
138
app/src/main/res/layout-land/activity_review.xml
Normal file
|
|
@ -0,0 +1,138 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.drawerlayout.widget.DrawerLayout
|
||||
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/drawer_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/mediaDetailContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:visibility="gone" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/reviewActivityContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:visibility="visible">
|
||||
|
||||
<include layout="@layout/toolbar" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatButton
|
||||
android:id="@+id/skip_image"
|
||||
style="@style/Widget.AppCompat.Button.Borderless"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:drawableEnd="@drawable/ic_info_outline_24dp"
|
||||
android:drawablePadding="@dimen/medium_height"
|
||||
android:drawableTint="@color/button_blue_dark"
|
||||
android:paddingLeft="@dimen/medium_height"
|
||||
android:paddingRight="@dimen/medium_height"
|
||||
android:text="@string/skip_image"
|
||||
android:textAllCaps="true"
|
||||
android:textColor="@color/button_blue_dark"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="@+id/guideline"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<fr.free.nrw.commons.review.ReviewViewPager
|
||||
android:id="@+id/view_pager_review"
|
||||
android:layout_width="@dimen/dimen_0"
|
||||
android:layout_height="@dimen/dimen_0"
|
||||
android:layout_weight="1"
|
||||
android:fadingEdge="none"
|
||||
app:layout_constraintBottom_toTopOf="@+id/rl_container_bottom_view"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="@+id/guideline"
|
||||
app:layout_constraintTop_toBottomOf="@+id/skip_image" />
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/rl_container_bottom_view"
|
||||
android:layout_width="@dimen/dimen_0"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:background="?attr/colorPrimaryDark"
|
||||
android:elevation="@dimen/miniscule_margin"
|
||||
android:padding="@dimen/medium_height"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="@+id/guideline">
|
||||
|
||||
<com.viewpagerindicator.CirclePageIndicator
|
||||
android:id="@+id/pager_indicator_review"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:background="?attr/colorPrimaryDark"
|
||||
android:foregroundGravity="center_vertical" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="@dimen/dimen_0"
|
||||
android:layout_height="@dimen/dimen_0"
|
||||
android:layout_weight="1"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toStartOf="@+id/view_pager_review"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<com.facebook.drawee.view.SimpleDraweeView
|
||||
android:id="@+id/review_image_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_marginTop="@dimen/dimen_0"
|
||||
app:srcCompat="@drawable/commons_logo" />
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/rl_container_upload_overlay"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_gravity="center|bottom"
|
||||
android:background="#77000000"
|
||||
android:gravity="center"
|
||||
android:padding="@dimen/tiny_gap">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_image_caption"
|
||||
style="?android:textAppearanceMedium"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="#FFFFFFFF" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/pb_review_image"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerInParent="true"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.Guideline
|
||||
android:id="@+id/guideline"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintGuide_percent="0.5" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.drawerlayout.widget.DrawerLayout>
|
||||
Loading…
Add table
Add a link
Reference in a new issue