Commit 08e499bb authored by mengcuiguang2's avatar mengcuiguang2

优化个人中心,关于我们

parent 4d1b0124
......@@ -11,6 +11,7 @@ import com.mints.street.AppApplication
import com.mints.street.BR
import com.mints.street.R
import com.mints.street.common.Constant
import com.mints.street.common.DeviceInfo
import com.mints.street.utils.CommonUtils
import com.mints.street.webview.MintsWebViewActivity
import kotlinx.android.synthetic.main.activity_aboutus.*
......@@ -22,7 +23,7 @@ class AboutusActivity : BaseActivity<ActivityAboutusBinding, AboutusViewModel>()
override fun initVariableId() = BR.viewModel
override fun initContentView(savedInstanceState: Bundle?) = R.layout.activity_aboutus
override fun getStatusBarHeightView(): View? {
return binding.tvText
return binding.tvAboutasVersion
}
override fun initData() {
super.initData()
......@@ -39,8 +40,10 @@ class AboutusActivity : BaseActivity<ActivityAboutusBinding, AboutusViewModel>()
tv_title.setTextColor(Color.BLACK)
iv_left_icon.setImageResource(R.mipmap.ic_arrow_back)
iv_left_icon.visibility = View.VISIBLE
tv_user.setOnClickListener(this)
tv_privacy.setOnClickListener(this)
tvAboutasVersion.text = "3D高清街景 v" + DeviceInfo.instance.versionName
tvAboutasService.setOnClickListener(this)
tvAboutasPolicy.setOnClickListener(this)
iv_app.setOnLongClickListener {
ToastUtils.showLong("自有渠道:" + CommonUtils.getAppMetaData(
......@@ -53,10 +56,10 @@ class AboutusActivity : BaseActivity<ActivityAboutusBinding, AboutusViewModel>()
override fun onClick(v: View?) {
when (v?.id) {
R.id.iv_left_icon -> finish()
R.id.tv_user -> {
R.id.tvAboutasService -> {
MintsWebViewActivity.startWebView(name = "用户协议", url = Constant.REGISTER_URL)
}
R.id.tv_privacy -> {
R.id.tvAboutasPolicy -> {
MintsWebViewActivity.startWebView(name = "隐私协议", url = Constant.PRIVACY_URL)
}
}
......
......@@ -169,6 +169,14 @@ class MyFragment : BaseFragment<FragmentMyBinding, MyViewModel>(), OnRefreshList
aboutus.findViewById<TextView>(R.id.tv_right).visibility = View.GONE
aboutus.findViewById<ImageView>(R.id.iv_right).visibility = View.VISIBLE
item_my_phone.findViewById<TextView>(R.id.tv_title).text = "人工客服"
item_my_phone.findViewById<TextView>(R.id.tv_right).text = "400-777-6667"
item_my_phone.findViewById<TextView>(R.id.tv_right).visibility = View.VISIBLE
val itemMyPhone = ContextCompat.getDrawable(context!!, R.mipmap.ic_my_phone)
itemMyPhone?.setBounds(0, 0, 56, 56)
item_my_phone.findViewById<TextView>(R.id.tv_title).setCompoundDrawables(itemMyPhone, null, null, null)
item_my_phone.findViewById<ImageView>(R.id.iv_right).visibility = View.GONE
moresettings.findViewById<TextView>(R.id.tv_title).text = "更多设置"
val privacyAgree = ContextCompat.getDrawable(context!!, R.mipmap.iv_more_settings)
privacyAgree?.setBounds(0, 0, 56, 56)
......
......@@ -61,7 +61,7 @@ class VRFragment : BaseFragment<FragmentVrBinding, VRViewModel>() {
binding.viewPager.init(this, fragments)
//初始化 magic_indicator
binding.magicIndicator.bindViewPager2(binding.viewPager, tabNames, {}, 16f, true)
binding.magicIndicator.bindViewPager2(binding.viewPager, tabNames, {}, 20f, true)
}
......
......@@ -48,7 +48,7 @@ class SplashActivity : BaseActivity<ActivitySplashBinding, SplashViewModel>() {
override fun initVariableId() = BR.viewModel
override fun getStatusBarHeightView()=binding.rlSplashRoot
override fun getStatusBarHeightView()=binding.viewSplash
override fun initData() {
super.initData()
......
......@@ -8,56 +8,98 @@
name="viewModel"
type="com.mints.street.main.my.AboutusViewModel" />
</data>
<RelativeLayout
<LinearLayout
android:layout_width="match_parent"
android:orientation="vertical"
android:layout_height="match_parent">
<include
android:id="@+id/header"
layout="@layout/include_header" />
<TextView
android:id="@+id/tv_text"
android:layout_below="@+id/header"
android:paddingTop="30dp"
android:id="@+id/tvAboutasVersion"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="3D高清街景"
android:textColor="@color/black"
android:layout_centerInParent="true"/>
android:layout_gravity="center_horizontal"
android:layout_marginTop="30dp"
android:layout_marginBottom="15dp"
android:text="@string/app_name"
android:textColor="@color/color_333"
android:textSize="13sp" />
<ImageView
android:id="@+id/iv_app"
android:layout_width="70dp"
android:layout_height="70dp"
android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true"
android:layout_marginBottom="65dp"
android:layout_width="80dp"
android:layout_height="80dp"
android:layout_gravity="center_horizontal"
android:src="@mipmap/ic_launcher_main" />
<LinearLayout
android:layout_centerHorizontal="true"
android:id="@+id/ly_text"
android:paddingTop="10dp"
android:layout_alignParentBottom="true"
android:layout_marginBottom="25dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:id="@+id/tv_user"
android:layout_marginRight="10dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/black"
android:text="《注册协议》"/>
<TextView
android:id="@+id/tv_privacy"
android:layout_marginLeft="10dp"
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/black"
android:text="《隐私协议》"/>
</LinearLayout>
android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true"
android:layout_marginBottom="20dp"
android:orientation="vertical">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="30dp"
android:orientation="vertical">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:orientation="horizontal">
<TextView
android:id="@+id/tvAboutasService"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="2dp"
android:padding="5dp"
android:text="注册协议"
android:textColor="@color/color_333"
android:textSize="14sp" />
<View
android:layout_width="1dp"
android:layout_height="match_parent"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:background="@color/color_333" />
<TextView
android:id="@+id/tvAboutasPolicy"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="2dp"
android:padding="5dp"
android:text="隐私政策"
android:textColor="@color/color_333"
android:textSize="14sp" />
</LinearLayout>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginLeft="30dp"
android:layout_marginRight="30dp"
android:gravity="center"
android:text="Copyright © 2019 Inc.."
android:textColor="@color/color_333"
android:textSize="12sp" />
</LinearLayout>
</LinearLayout>
</RelativeLayout>
</RelativeLayout>
</LinearLayout>
</layout>
\ No newline at end of file
......@@ -102,6 +102,7 @@
android:layout_height="20dp"
android:layout_alignParentLeft="true"
android:layout_marginStart="15dp"
android:layout_gravity="center_vertical"
android:src="@mipmap/icon_pay_wx" />
<TextView
......@@ -110,6 +111,7 @@
android:layout_marginLeft="5dp"
android:layout_weight="1"
android:text="微信支付"
android:layout_gravity="center_vertical"
android:textColor="@color/black"
android:textSize="18sp" />
......@@ -117,7 +119,7 @@
android:id="@+id/iv_weixin"
android:layout_width="20dp"
android:layout_height="20dp"
android:layout_gravity="center"
android:layout_gravity="center_vertical"
android:src="@mipmap/pay_unselect" />
</LinearLayout>
......@@ -135,6 +137,7 @@
android:layout_height="20dp"
android:layout_alignParentLeft="true"
android:layout_marginStart="15dp"
android:layout_gravity="center_vertical"
android:src="@mipmap/icon_pay_zfb" />
<TextView
......@@ -143,6 +146,7 @@
android:layout_marginLeft="5dp"
android:layout_weight="1"
android:text="支付宝支付"
android:layout_gravity="center_vertical"
android:textColor="@color/black"
android:textSize="18sp" />
......@@ -150,7 +154,7 @@
android:id="@+id/iv_alipay"
android:layout_width="20dp"
android:layout_height="20dp"
android:layout_gravity="center"
android:layout_gravity="center_vertical"
android:src="@mipmap/pay_unselect" />
</LinearLayout>
</LinearLayout>
......
......@@ -2,11 +2,15 @@
<layout xmlns:android="http://schemas.android.com/apk/res/android">
<RelativeLayout
android:id="@+id/rl_splash_root"
android:layout_width="match_parent"
android:background="#061b45"
android:layout_height="match_parent">
<View
android:id="@+id/view_splash"
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
<ImageView
android:layout_centerInParent="true"
android:layout_width="wrap_content"
......
......@@ -125,6 +125,15 @@
<include
android:id="@+id/aboutus"
layout="@layout/item_settings" />
<View
style="@style/view_line_E6E6E6"
android:layout_marginStart="20dp"
android:layout_marginEnd="20dp"
android:layout_alignParentBottom="true" />
<include
android:id="@+id/item_my_phone"
layout="@layout/item_settings" />
<View
style="@style/view_line_E6E6E6"
android:layout_marginStart="20dp"
......
......@@ -9,7 +9,9 @@
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/bg"
android:layout_width="match_parent"
android:layout_height="140dp"
android:layout_height="150dp"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:background="@mipmap/vip_google_bg"
android:layout_marginStart="5dp"
android:layout_marginEnd="5dp"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment