游戏上传UI优化
This commit is contained in:
@ -10,6 +10,7 @@ import android.widget.TextView
|
||||
import com.gh.base.fragment.BaseDialogFragment
|
||||
import com.gh.common.DefaultJsApi
|
||||
import com.gh.common.util.MtaHelper
|
||||
import com.gh.common.util.dip2px
|
||||
import com.gh.gamecenter.BuildConfig
|
||||
import com.gh.gamecenter.R
|
||||
import wendu.dsbridge.DWebView
|
||||
@ -89,8 +90,8 @@ class GameResourcePolicyDialogFragment : BaseDialogFragment() {
|
||||
|
||||
override fun onStart() {
|
||||
super.onStart()
|
||||
val width = requireContext().resources.displayMetrics.widthPixels * 0.8
|
||||
val width = requireContext().resources.displayMetrics.widthPixels - 60F.dip2px()
|
||||
val height = ViewGroup.LayoutParams.WRAP_CONTENT
|
||||
dialog?.window?.setLayout(width.toInt(), height)
|
||||
dialog?.window?.setLayout(width, height)
|
||||
}
|
||||
}
|
||||
@ -432,6 +432,7 @@ class GameUploadFragment : NormalFragment() {
|
||||
if (obj is InstallGameEntity) run {
|
||||
mInstallGameEntity = obj
|
||||
chooseGameLl.background = null
|
||||
chooseGameLl.setPadding(0, 0, 0, 0)
|
||||
chooseGameIconIv.visibility = View.GONE
|
||||
tv_choose.text = mInstallGameEntity.packageName
|
||||
}
|
||||
@ -491,6 +492,7 @@ class GameUploadFragment : NormalFragment() {
|
||||
this.gameVersion = version
|
||||
}
|
||||
chooseGameLl.background = null
|
||||
chooseGameLl.setPadding(0, 0, 0, 0)
|
||||
chooseGameIconIv.visibility = View.GONE
|
||||
tv_choose.text = packageName
|
||||
}
|
||||
|
||||
@ -6,8 +6,8 @@
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:gravity="center"
|
||||
android:paddingTop="22dp"
|
||||
android:paddingLeft="20dp"
|
||||
android:paddingRight="20dp"
|
||||
android:paddingLeft="10dp"
|
||||
android:paddingRight="10dp"
|
||||
android:paddingBottom="20dp"
|
||||
android:background="@drawable/background_shape_white_radius_6">
|
||||
|
||||
@ -19,7 +19,7 @@
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:textColor="@color/text_333333"
|
||||
android:textSize="16dp"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold"
|
||||
tools:text="光环助手资源协议"/>
|
||||
|
||||
@ -39,6 +39,7 @@
|
||||
android:layout_height="40dp"
|
||||
android:text="不同意"
|
||||
android:layout_marginTop="20dp"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:textSize="14sp"
|
||||
android:textColor="@color/text_333333"
|
||||
android:gravity="center"
|
||||
@ -53,11 +54,12 @@
|
||||
android:layout_height="40dp"
|
||||
android:text="同意"
|
||||
android:layout_marginTop="20dp"
|
||||
android:layout_marginRight="10dp"
|
||||
android:textSize="14sp"
|
||||
android:textColor="@color/white"
|
||||
android:gravity="center"
|
||||
android:background="@drawable/button_blue_oval"
|
||||
android:layout_marginLeft="40dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
app:layout_constraintStart_toEndOf="@+id/refuseTv"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/webView"
|
||||
|
||||
@ -93,19 +93,19 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingLeft="20dp"
|
||||
android:paddingTop="20dp"
|
||||
android:paddingRight="16dp"
|
||||
android:paddingBottom="14dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:layout_marginBottom="14dp"
|
||||
android:text="游戏图标*"
|
||||
android:textColor="@color/text_333333"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintBottom_toTopOf="@+id/gameIconRv"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="(限制一张,尺寸比例1:1)"
|
||||
android:text="(限制一张,尺寸比例1:1)"
|
||||
android:textColor="@color/text_999999"
|
||||
android:textSize="12sp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/gameIconTitleTv"
|
||||
@ -131,18 +131,17 @@
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="56dp"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_game_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:paddingLeft="20dp"
|
||||
android:paddingTop="16dp"
|
||||
android:paddingRight="16dp"
|
||||
android:paddingBottom="16dp"
|
||||
android:text="游戏名字*"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/text_333333"
|
||||
android:textSize="14sp" />
|
||||
|
||||
@ -244,7 +243,7 @@
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp">
|
||||
android:layout_height="56dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/gameIsNetworkingTv"
|
||||
@ -272,29 +271,27 @@
|
||||
<RadioButton
|
||||
android:id="@+id/gameNetworkingRb"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="28dp"
|
||||
android:background="@drawable/game_upload_rg_button_selector"
|
||||
android:button="@null"
|
||||
android:paddingLeft="12dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingRight="12dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:text="需要联网"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/game_upload_rg_button_selector"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/gameNoNetworkingRb"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="28dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:background="@drawable/game_upload_rg_button_selector"
|
||||
android:button="@null"
|
||||
android:paddingLeft="12dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingRight="12dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:text="无需联网"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/game_upload_rg_button_selector"
|
||||
android:textSize="12sp" />
|
||||
</RadioGroup>
|
||||
@ -307,7 +304,7 @@
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp">
|
||||
android:layout_height="56dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/gameLanguageTv"
|
||||
@ -335,44 +332,41 @@
|
||||
<RadioButton
|
||||
android:id="@+id/gameLanguageChineseRb"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="28dp"
|
||||
android:background="@drawable/game_upload_rg_button_selector"
|
||||
android:button="@null"
|
||||
android:paddingLeft="12dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingRight="12dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:text="中文"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/game_upload_rg_button_selector"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/gameLanguageEnglishRb"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="28dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:background="@drawable/game_upload_rg_button_selector"
|
||||
android:button="@null"
|
||||
android:paddingLeft="12dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingRight="12dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:text="英文"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/game_upload_rg_button_selector"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/gameLanguageOtherRb"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="28dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:background="@drawable/game_upload_rg_button_selector"
|
||||
android:button="@null"
|
||||
android:paddingLeft="12dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingRight="12dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:text="其他"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/game_upload_rg_button_selector"
|
||||
android:textSize="12sp" />
|
||||
</RadioGroup>
|
||||
@ -385,7 +379,7 @@
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp">
|
||||
android:layout_height="56dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/gameTypeTv"
|
||||
@ -413,44 +407,41 @@
|
||||
<RadioButton
|
||||
android:id="@+id/gameTypeLocalRb"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="28dp"
|
||||
android:background="@drawable/game_upload_rg_button_selector"
|
||||
android:button="@null"
|
||||
android:paddingLeft="12dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingRight="12dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:text="单机"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/game_upload_rg_button_selector"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/gameTypeOnlineRb"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="28dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:background="@drawable/game_upload_rg_button_selector"
|
||||
android:button="@null"
|
||||
android:paddingLeft="12dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingRight="12dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:text="网游"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/game_upload_rg_button_selector"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/gameTypeOtherRb"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="28dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:background="@drawable/game_upload_rg_button_selector"
|
||||
android:button="@null"
|
||||
android:paddingLeft="12dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingRight="12dp"
|
||||
android:paddingBottom="8dp"
|
||||
android:text="其他"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/game_upload_rg_button_selector"
|
||||
android:textSize="12sp" />
|
||||
</RadioGroup>
|
||||
@ -535,19 +526,19 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingLeft="20dp"
|
||||
android:paddingTop="16dp"
|
||||
android:paddingRight="20dp"
|
||||
android:paddingBottom="14dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginBottom="14dp"
|
||||
android:text="游戏图片*"
|
||||
android:textColor="@color/text_333333"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintBottom_toTopOf="@+id/rv_screenshot"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="(最多五张,建议图片尺寸比例9:16)"
|
||||
android:text="(最多五张,建议图片尺寸比例9:16)"
|
||||
android:textColor="@color/text_999999"
|
||||
android:textSize="12sp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_screenshot"
|
||||
@ -615,6 +606,7 @@
|
||||
android:layout_margin="20dp"
|
||||
android:button="@null"
|
||||
android:checked="true"
|
||||
android:background="@color/transparent"
|
||||
android:drawableLeft="@drawable/video_upload_protocol_checkbox_style"
|
||||
android:drawablePadding="4dp"
|
||||
android:textColor="@color/text_333333"
|
||||
|
||||
Reference in New Issue
Block a user