调整签到dialog布局
This commit is contained in:
parent
33e7503c70
commit
6925c42372
|
|
@ -5,6 +5,7 @@ import android.content.Context
|
||||||
import android.util.AttributeSet
|
import android.util.AttributeSet
|
||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
import android.widget.LinearLayout
|
import android.widget.LinearLayout
|
||||||
|
import androidx.constraintlayout.widget.ConstraintLayout
|
||||||
import androidx.core.view.isVisible
|
import androidx.core.view.isVisible
|
||||||
import com.ama.core.architecture.util.ResUtil
|
import com.ama.core.architecture.util.ResUtil
|
||||||
import com.vididin.real.money.game.R
|
import com.vididin.real.money.game.R
|
||||||
|
|
@ -46,6 +47,8 @@ class DailySignItemView @JvmOverloads constructor(
|
||||||
fun setLargeWidthMode() {
|
fun setLargeWidthMode() {
|
||||||
mBinding.ivGold.setImageResource(R.mipmap.icon_gold_x3)
|
mBinding.ivGold.setImageResource(R.mipmap.icon_gold_x3)
|
||||||
mBinding.ivBg.setImageResource(R.mipmap.bg_biginner_daily_large)
|
mBinding.ivBg.setImageResource(R.mipmap.bg_biginner_daily_large)
|
||||||
|
val param: ConstraintLayout.LayoutParams = mBinding.ivBg.layoutParams as ConstraintLayout.LayoutParams
|
||||||
|
param.dimensionRatio = "H, 438:240"
|
||||||
}
|
}
|
||||||
|
|
||||||
fun setSelectState(isSelect: Boolean) {
|
fun setSelectState(isSelect: Boolean) {
|
||||||
|
|
|
||||||
|
|
@ -1,14 +1,13 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<LinearLayout
|
<LinearLayout 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:id="@+id/content_root"
|
android:id="@+id/content_root"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal">
|
||||||
>
|
|
||||||
|
|
||||||
<RelativeLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/rl_root"
|
android:id="@+id/rl_root"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content">
|
android:layout_height="wrap_content">
|
||||||
|
|
@ -16,9 +15,13 @@
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
android:id="@+id/iv_bg"
|
android:id="@+id/iv_bg"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="80dp"
|
android:layout_height="0dp"
|
||||||
android:layout_centerInParent="true"
|
android:layout_centerInParent="true"
|
||||||
android:src="@mipmap/bg_biginner_daily"/>
|
android:src="@mipmap/bg_biginner_daily"
|
||||||
|
app:layout_constraintDimensionRatio="H, 68:80"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent"/>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
|
|
@ -27,6 +30,10 @@
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
android:layout_centerInParent="true"
|
android:layout_centerInParent="true"
|
||||||
android:layout_marginTop="10dp"
|
android:layout_marginTop="10dp"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
>
|
>
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
android:id="@+id/iv_gold"
|
android:id="@+id/iv_gold"
|
||||||
|
|
@ -45,7 +52,7 @@
|
||||||
android:text="100"
|
android:text="100"
|
||||||
/>
|
/>
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</RelativeLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
|
|
|
||||||
|
|
@ -9,28 +9,17 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="20dp">
|
android:layout_marginTop="20dp">
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
|
||||||
android:id="@+id/aspect_ratio_view"
|
|
||||||
android:layout_width="0dp"
|
|
||||||
android:layout_height="0dp"
|
|
||||||
android:src="@mipmap/daily_sign_bg"
|
|
||||||
android:paddingEnd="-28dp"
|
|
||||||
app:layout_constraintDimensionRatio="H,1058:1413"
|
|
||||||
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="0dp"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
android:layout_marginHorizontal="30dp"
|
android:paddingHorizontal="30dp"
|
||||||
android:clipChildren="false"
|
android:clipChildren="false"
|
||||||
android:layout_marginTop="45dp"
|
android:layout_marginTop="45dp"
|
||||||
|
android:background="@mipmap/daily_sign_bg"
|
||||||
|
app:layout_constraintDimensionRatio="H,1058:1413"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
|
@ -39,7 +28,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="28dp"
|
android:layout_marginTop="68dp"
|
||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue