每日签到 调整
This commit is contained in:
parent
d3fab79e75
commit
5a6cef78b2
|
|
@ -12,12 +12,15 @@ class DailySignDialog(context: Context) : BindingDialog<DialogDailySignBinding>(
|
||||||
fun build(): DailySignDialog {
|
fun build(): DailySignDialog {
|
||||||
with()
|
with()
|
||||||
setCenter()
|
setCenter()
|
||||||
|
setCanCancel(false)
|
||||||
setMaskValue(0.9f)
|
setMaskValue(0.9f)
|
||||||
|
setWidthRatio(0.93)
|
||||||
|
|
||||||
|
|
||||||
mBinding.run {
|
mBinding.run {
|
||||||
setOnClickBatch(butLeft, butRight) {
|
setOnClickBatch(butLeft, butRight, ivClose) {
|
||||||
when (this) {
|
when (this) {
|
||||||
butLeft -> {
|
butLeft, ivClose -> {
|
||||||
dismiss()
|
dismiss()
|
||||||
}
|
}
|
||||||
butRight -> {
|
butRight -> {
|
||||||
|
|
|
||||||
|
|
@ -1,25 +1,25 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
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_width="match_parent"
|
||||||
android:layout_height="wrap_content">
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:src="@mipmap/daily_sign_bg"
|
android:layout_marginTop="20dp">
|
||||||
android:layout_marginTop="30dp"
|
|
||||||
/>
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
android:id="@+id/iv_close"
|
android:id="@+id/aspect_ratio_view"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="0dp"
|
||||||
android:orientation="vertical"
|
android:src="@mipmap/daily_sign_bg"
|
||||||
android:layout_gravity="end"
|
android:paddingEnd="-28dp"
|
||||||
android:src="@mipmap/icon_close"
|
app:layout_constraintDimensionRatio="H,1058:1413"
|
||||||
android:layout_marginEnd="30dp"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -27,21 +27,25 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:layout_marginLeft="15dp"
|
android:gravity="center"
|
||||||
android:layout_marginRight="45dp"
|
android:layout_marginHorizontal="30dp"
|
||||||
android:layout_marginTop="60dp"
|
|
||||||
android:clipChildren="false"
|
android:clipChildren="false"
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
>
|
>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="8dp"
|
android:layout_marginTop="28dp"
|
||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="-10dp"
|
||||||
android:src="@mipmap/icon_smile"/>
|
android:src="@mipmap/icon_smile"/>
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
|
|
@ -56,7 +60,7 @@
|
||||||
android:id="@+id/tv_desc"
|
android:id="@+id/tv_desc"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="10dp"
|
android:layout_marginTop="-5dp"
|
||||||
android:textSize="14sp"
|
android:textSize="14sp"
|
||||||
android:textColor="@color/gray6"
|
android:textColor="@color/gray6"
|
||||||
android:text="@string/daily_sign_desc"
|
android:text="@string/daily_sign_desc"
|
||||||
|
|
@ -114,7 +118,7 @@
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="10dp"
|
android:layout_marginTop="5dp"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
<com.gamedog.vididin.widget.DailySignItemView
|
<com.gamedog.vididin.widget.DailySignItemView
|
||||||
android:id="@+id/sign_item_5"
|
android:id="@+id/sign_item_5"
|
||||||
|
|
@ -142,7 +146,7 @@
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="15dp"
|
android:layout_marginTop="20dp"
|
||||||
android:clipChildren="false"
|
android:clipChildren="false"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
|
@ -211,4 +215,26 @@
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
|
android:id="@+id/iv_close"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_gravity="end"
|
||||||
|
android:src="@mipmap/icon_close"
|
||||||
|
android:layout_marginEnd="30dp"
|
||||||
|
/>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</FrameLayout>
|
</FrameLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue