徐勤民 3 mesi fa
parent
commit
0093af4858

+ 2 - 1
app/src/main/AndroidManifest.xml

@@ -43,7 +43,8 @@
         <activity
             android:name=".ui.ChatActivity"
             android:exported="false"
-            android:windowSoftInputMode="stateVisible|adjustResize" />
+            android:windowSoftInputMode="adjustResize"
+            />
         <activity
             android:name=".ui.FeedbackActivity"
             android:exported="false" />

+ 6 - 0
app/src/main/java/com/xuqinmin/android/app/ui/ChatActivity.kt

@@ -195,6 +195,12 @@ class ChatActivity : BaseActivity<ActivityChatBinding>() {
             binding.empty.gone()
         }
         putInt(MSG_COUNT + "_" + toUser?.userId, 0)//消息全部已读
+        if (intent?.getBooleanExtra("isSys", false) == true){
+            binding.startVideo.gone()
+            binding.startVideo2.gone()
+            binding.msgStartVideo.gone()
+            binding.more.gone()
+        }
     }
 
     override fun initData() {

+ 1 - 1
app/src/main/java/com/xuqinmin/android/app/ui/fragment/MessageFragment.kt

@@ -65,7 +65,6 @@ class MessageFragment : BaseFragment<FragmentMessageBinding>() {
             MessageManager.getConversation()
         }
         adapter.setItemClickListener { _, item, _ ->
-            if (item.isSys == 1)return@setItemClickListener
             startActivity(Intent(mContext, ChatActivity::class.java).apply {
                 putExtra(
                     "model", GsonImplHelp.get().toJson(
@@ -85,6 +84,7 @@ class MessageFragment : BaseFragment<FragmentMessageBinding>() {
                     )
                 )
                 putExtra("conversationId", item.conversationId)
+                putExtra("isSys", item.isSys == 1)
             })
         }
         adapter1.setItemClickListener { _, item, _ ->

+ 4 - 0
app/src/main/java/com/xuqinmin/android/app/ui/fragment/RandomFragment.kt

@@ -13,6 +13,7 @@ import com.xuqinmin.android.app.MyApplication
 import com.xuqinmin.android.app.R
 import com.xuqinmin.android.app.databinding.FragmentRandomBinding
 import com.xuqinmin.android.app.model.Balance
+import com.xuqinmin.android.app.ui.CoinStoreActivity
 import com.xuqinmin.android.app.ui.SearchingActivity
 import com.xuqinmin.android.app.ui.dialog.DialogBalance
 import com.xuqinmin.android.app.ui.dialog.DialogBalanceNew
@@ -66,6 +67,9 @@ class RandomFragment : BaseFragment<FragmentRandomBinding>() {
 //            vm.refreshRtc()
                 })
         }
+        binding.species.setOnClickListener {
+            mContext.startActivity(Intent(mContext, CoinStoreActivity::class.java))
+        }
 
         binding.matchPrice.text = "${MyApplication.modelInit.matchPrice} / Match"
 

+ 1 - 16
app/src/main/res/layout/activity_chat.xml

@@ -5,8 +5,7 @@
 
     <androidx.constraintlayout.widget.ConstraintLayout
         android:layout_width="match_parent"
-        android:layout_height="match_parent"
-        tools:context=".ui.ChatActivity">
+        android:layout_height="match_parent">
 
         <androidx.constraintlayout.widget.ConstraintLayout
             android:id="@+id/top"
@@ -59,20 +58,6 @@
                     android:textStyle="bold" />
             </LinearLayout>
 
-            <TextView
-                android:id="@+id/skip"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_marginEnd="15dp"
-                android:text="Skip"
-                android:textColor="#999999"
-                android:textSize="18sp"
-                android:textStyle="bold"
-                app:layout_constraintBottom_toBottomOf="@+id/back"
-                app:layout_constraintEnd_toEndOf="parent"
-                app:layout_constraintTop_toTopOf="@+id/back" />
-
-
             <ImageView
                 android:id="@+id/more"
                 android:layout_width="40dp"

+ 1 - 1
app/src/main/res/layout/activity_main.xml

@@ -24,7 +24,7 @@
         <com.google.android.material.bottomnavigation.BottomNavigationView
             android:id="@+id/bottom_nav"
             android:layout_width="match_parent"
-            android:layout_height="80dp"
+            android:layout_height="wrap_content"
             android:background="#fcfcfc"
             app:itemIconSize="30dp"
             app:itemTextAppearanceActive="@style/bottom_tab_title_active"

+ 208 - 195
app/src/main/res/layout/activity_register.xml

@@ -1,227 +1,240 @@
 <?xml version="1.0" encoding="utf-8"?>
 <layout 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">
+    xmlns:app="http://schemas.android.com/apk/res-auto">
 
-    <androidx.constraintlayout.widget.ConstraintLayout
+    <ScrollView
         android:layout_width="match_parent"
         android:layout_height="match_parent"
-        android:tag="top_status"
-        tools:context=".ui.RegisterActivity">
+        android:tag="top_status">
 
-        <include
-            android:id="@+id/top_bar"
-            layout="@layout/top_bar" />
-
-        <TextView
-            android:id="@+id/view_avatar"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="Avatar"
-            android:textColor="#999999"
-            android:textSize="18sp"
-            app:layout_constraintBottom_toBottomOf="@+id/top_bar"
-            app:layout_constraintEnd_toEndOf="parent"
-            app:layout_constraintStart_toStartOf="parent"
-            app:layout_constraintTop_toBottomOf="@+id/top_bar" />
-
-        <ImageView
-            android:id="@+id/avatar"
-            android:layout_width="100dp"
-            android:layout_height="100dp"
-            android:layout_marginTop="20dp"
-            android:src="@mipmap/avatar_upload"
-            app:layout_constraintEnd_toEndOf="parent"
-            app:layout_constraintStart_toStartOf="parent"
-            app:layout_constraintTop_toBottomOf="@+id/view_avatar" />
-
-        <ImageView
-            android:id="@+id/avatar_replace"
-            android:layout_width="30dp"
-            android:layout_height="30dp"
-            android:src="@mipmap/avatar_replace"
-            android:visibility="gone"
-            app:layout_constraintBottom_toBottomOf="@+id/avatar"
-            app:layout_constraintEnd_toEndOf="@+id/avatar" />
-
-        <TextView
-            android:id="@+id/view_nick_name"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="20dp"
-            android:text="Nickname"
-            android:textColor="#999999"
-            android:textSize="18sp"
-            app:layout_constraintEnd_toEndOf="parent"
-            app:layout_constraintStart_toStartOf="parent"
-            app:layout_constraintTop_toBottomOf="@+id/avatar" />
-
-        <EditText
-            android:id="@+id/nick_name"
-            android:layout_width="315dp"
-            android:layout_height="54dp"
-            android:layout_marginTop="10dp"
-            android:background="@drawable/bg_input_line"
-            android:gravity="center"
-            android:hint="Enter your nickname"
-            android:imeOptions="actionDone"
-            android:singleLine="true"
-            android:textColor="#222222"
-            android:textColorHint="#999999"
-            android:textSize="18sp"
-            app:layout_constraintEnd_toEndOf="parent"
-            app:layout_constraintStart_toStartOf="parent"
-            app:layout_constraintTop_toBottomOf="@+id/view_nick_name" />
-
-        <TextView
-            android:id="@+id/view_gender"
-            android:layout_width="wrap_content"
+        <LinearLayout
+            android:layout_width="match_parent"
             android:layout_height="wrap_content"
-            android:layout_marginTop="20dp"
-            android:text="Gender"
-            android:textColor="#999999"
-            android:textSize="18sp"
-            app:layout_constraintEnd_toEndOf="parent"
-            app:layout_constraintStart_toStartOf="parent"
-            app:layout_constraintTop_toBottomOf="@+id/nick_name" />
+            android:orientation="vertical">
 
+            <androidx.constraintlayout.widget.ConstraintLayout
+                android:layout_width="match_parent"
+                android:background="@color/black"
+                android:layout_height="wrap_content">
 
-        <LinearLayout
-            android:id="@+id/root_gender"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="10dp"
-            android:orientation="horizontal"
-            app:layout_constraintEnd_toEndOf="@+id/nick_name"
-            app:layout_constraintStart_toStartOf="@+id/nick_name"
-            app:layout_constraintTop_toBottomOf="@+id/view_gender">
-
-            <LinearLayout
-                android:id="@+id/btn_male"
-                android:layout_width="70dp"
-                android:layout_height="wrap_content"
-                android:gravity="center"
-                android:orientation="vertical">
+                <include
+                    android:id="@+id/top_bar"
+                    layout="@layout/top_bar" />
 
-                <ImageView
-                    android:id="@+id/iv_male"
+                <TextView
+                    android:id="@+id/view_avatar"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:src="@mipmap/male_selected" />
+                    android:text="Avatar"
+                    android:textColor="#999999"
+                    android:textSize="18sp"
+                    app:layout_constraintBottom_toBottomOf="@+id/top_bar"
+                    app:layout_constraintEnd_toEndOf="parent"
+                    app:layout_constraintStart_toStartOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/top_bar" />
+
+                <ImageView
+                    android:id="@+id/avatar"
+                    android:layout_width="100dp"
+                    android:layout_height="100dp"
+                    android:layout_marginTop="20dp"
+                    android:src="@mipmap/avatar_upload"
+                    app:layout_constraintEnd_toEndOf="parent"
+                    app:layout_constraintStart_toStartOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/view_avatar" />
+
+                <ImageView
+                    android:id="@+id/avatar_replace"
+                    android:layout_width="30dp"
+                    android:layout_height="30dp"
+                    android:src="@mipmap/avatar_replace"
+                    android:visibility="gone"
+                    app:layout_constraintBottom_toBottomOf="@+id/avatar"
+                    app:layout_constraintEnd_toEndOf="@+id/avatar" />
 
                 <TextView
-                    android:id="@+id/tv_male"
+                    android:id="@+id/view_nick_name"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
+                    android:layout_marginTop="20dp"
+                    android:text="Nickname"
+                    android:textColor="#999999"
+                    android:textSize="18sp"
+                    app:layout_constraintEnd_toEndOf="parent"
+                    app:layout_constraintStart_toStartOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/avatar" />
+
+                <EditText
+                    android:id="@+id/nick_name"
+                    android:layout_width="315dp"
+                    android:layout_height="54dp"
                     android:layout_marginTop="10dp"
-                    android:text="Male"
-                    android:textColor="#05BCFF"
-                    android:textSize="18sp" />
+                    android:background="@drawable/bg_input_line"
+                    android:gravity="center"
+                    android:hint="Enter your nickname"
+                    android:imeOptions="actionDone"
+                    android:singleLine="true"
+                    android:textColor="#222222"
+                    android:textColorHint="#999999"
+                    android:textSize="18sp"
+                    app:layout_constraintEnd_toEndOf="parent"
+                    app:layout_constraintStart_toStartOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/view_nick_name" />
 
-            </LinearLayout>
+                <TextView
+                    android:id="@+id/view_gender"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="20dp"
+                    android:text="Gender"
+                    android:textColor="#999999"
+                    android:textSize="18sp"
+                    app:layout_constraintEnd_toEndOf="parent"
+                    app:layout_constraintStart_toStartOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/nick_name" />
 
-            <LinearLayout
-                android:id="@+id/btn_female"
-                android:layout_width="70dp"
-                android:layout_height="wrap_content"
-                android:layout_marginStart="150dp"
-                android:gravity="center"
-                android:orientation="vertical">
 
-                <ImageView
-                    android:id="@+id/iv_female"
+                <LinearLayout
+                    android:id="@+id/root_gender"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:src="@mipmap/female_normal" />
+                    android:layout_marginTop="10dp"
+                    android:orientation="horizontal"
+                    app:layout_constraintEnd_toEndOf="@+id/nick_name"
+                    app:layout_constraintStart_toStartOf="@+id/nick_name"
+                    app:layout_constraintTop_toBottomOf="@+id/view_gender">
+
+                    <LinearLayout
+                        android:id="@+id/btn_male"
+                        android:layout_width="70dp"
+                        android:layout_height="wrap_content"
+                        android:gravity="center"
+                        android:orientation="vertical">
+
+                        <ImageView
+                            android:id="@+id/iv_male"
+                            android:layout_width="wrap_content"
+                            android:layout_height="wrap_content"
+                            android:src="@mipmap/male_selected" />
+
+                        <TextView
+                            android:id="@+id/tv_male"
+                            android:layout_width="wrap_content"
+                            android:layout_height="wrap_content"
+                            android:layout_marginTop="10dp"
+                            android:text="Male"
+                            android:textColor="#05BCFF"
+                            android:textSize="18sp" />
+
+                    </LinearLayout>
+
+                    <LinearLayout
+                        android:id="@+id/btn_female"
+                        android:layout_width="70dp"
+                        android:layout_height="wrap_content"
+                        android:layout_marginStart="150dp"
+                        android:gravity="center"
+                        android:orientation="vertical">
+
+                        <ImageView
+                            android:id="@+id/iv_female"
+                            android:layout_width="wrap_content"
+                            android:layout_height="wrap_content"
+                            android:src="@mipmap/female_normal" />
+
+                        <TextView
+                            android:id="@+id/tv_female"
+                            android:layout_width="wrap_content"
+                            android:layout_height="wrap_content"
+                            android:layout_marginTop="10dp"
+                            android:text="Female"
+                            android:textColor="#999999"
+                            android:textSize="18sp" />
+
+                    </LinearLayout>
+                </LinearLayout>
 
                 <TextView
-                    android:id="@+id/tv_female"
+                    android:id="@+id/prompt"
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
                     android:layout_marginTop="10dp"
-                    android:text="Female"
-                    android:textColor="#999999"
-                    android:textSize="18sp" />
-
-            </LinearLayout>
-        </LinearLayout>
+                    android:text="Gender cannot be modified after selection"
+                    android:textColor="#FF02A7"
+                    android:textSize="11sp"
+                    app:layout_constraintEnd_toEndOf="parent"
+                    app:layout_constraintStart_toStartOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/root_gender" />
 
-        <TextView
-            android:id="@+id/prompt"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="10dp"
-            android:text="Gender cannot be modified after selection"
-            android:textColor="#FF02A7"
-            android:textSize="11sp"
-            app:layout_constraintEnd_toEndOf="parent"
-            app:layout_constraintStart_toStartOf="parent"
-            app:layout_constraintTop_toBottomOf="@+id/root_gender" />
-
-        <TextView
-            android:id="@+id/view_country"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="20dp"
-            android:text="Country"
-            android:textColor="#999999"
-            android:textSize="18sp"
-            app:layout_constraintEnd_toEndOf="parent"
-            app:layout_constraintStart_toStartOf="parent"
-            app:layout_constraintTop_toBottomOf="@+id/prompt" />
-
-        <androidx.constraintlayout.widget.ConstraintLayout
-            android:id="@+id/view_choose_country"
-            android:layout_width="315dp"
-            android:layout_height="54dp"
-            android:layout_marginTop="20dp"
-            android:background="@drawable/bg_input_line"
-            app:layout_constraintEnd_toEndOf="parent"
-            app:layout_constraintStart_toStartOf="parent"
-            app:layout_constraintTop_toBottomOf="@+id/view_country">
-
-            <TextView
-                android:id="@+id/tv_country"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:gravity="center"
-                android:hint="Choose your country"
-                android:text=""
-                android:textColor="#222222"
-                android:textColorHint="#999999"
+                <TextView
+                    android:id="@+id/view_country"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="20dp"
+                    android:text="Country"
+                    android:textColor="#999999"
+                    android:textSize="18sp"
+                    app:layout_constraintEnd_toEndOf="parent"
+                    app:layout_constraintStart_toStartOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/prompt" />
+
+                <androidx.constraintlayout.widget.ConstraintLayout
+                    android:id="@+id/view_choose_country"
+                    android:layout_width="315dp"
+                    android:layout_height="54dp"
+                    android:layout_marginTop="20dp"
+                    android:background="@drawable/bg_input_line"
+                    app:layout_constraintEnd_toEndOf="parent"
+                    app:layout_constraintStart_toStartOf="parent"
+                    app:layout_constraintTop_toBottomOf="@+id/view_country">
+
+                    <TextView
+                        android:id="@+id/tv_country"
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:gravity="center"
+                        android:hint="Choose your country"
+                        android:text=""
+                        android:textColor="#222222"
+                        android:textColorHint="#999999"
+                        android:textSize="18sp"
+                        android:textStyle="bold"
+                        app:layout_constraintBottom_toBottomOf="parent"
+                        app:layout_constraintEnd_toEndOf="parent"
+                        app:layout_constraintStart_toStartOf="parent"
+                        app:layout_constraintTop_toTopOf="parent" />
+
+                    <ImageView
+                        android:id="@+id/iv_country"
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_marginEnd="15dp"
+                        android:src="@mipmap/choose_country"
+                        app:layout_constraintBottom_toBottomOf="parent"
+                        app:layout_constraintEnd_toEndOf="parent"
+                        app:layout_constraintTop_toTopOf="parent" />
+
+                </androidx.constraintlayout.widget.ConstraintLayout>
+
+
+            </androidx.constraintlayout.widget.ConstraintLayout>
+
+            <Button
+                android:id="@+id/login_next"
+                android:layout_width="315dp"
+                android:layout_height="54dp"
+                android:layout_gravity="center_horizontal"
+                android:layout_marginTop="60dp"
+                android:layout_marginBottom="30dp"
+                android:background="@drawable/bg_btn_success"
+                android:enabled="false"
+                android:text="Next"
+                android:textColor="@color/white"
                 android:textSize="18sp"
-                android:textStyle="bold"
-                app:layout_constraintBottom_toBottomOf="parent"
                 app:layout_constraintEnd_toEndOf="parent"
                 app:layout_constraintStart_toStartOf="parent"
-                app:layout_constraintTop_toTopOf="parent" />
-
-            <ImageView
-                android:id="@+id/iv_country"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_marginEnd="15dp"
-                android:src="@mipmap/choose_country"
-                app:layout_constraintBottom_toBottomOf="parent"
-                app:layout_constraintEnd_toEndOf="parent"
-                app:layout_constraintTop_toTopOf="parent" />
-
-        </androidx.constraintlayout.widget.ConstraintLayout>
-
-        <Button
-            android:id="@+id/login_next"
-            android:layout_width="315dp"
-            android:layout_height="54dp"
-            android:layout_marginTop="60dp"
-            android:background="@drawable/bg_btn_success"
-            android:enabled="false"
-            android:text="Next"
-            android:textColor="@color/white"
-            android:textSize="18sp"
-            app:layout_constraintEnd_toEndOf="parent"
-            app:layout_constraintStart_toStartOf="parent"
-            app:layout_constraintTop_toBottomOf="@+id/view_choose_country" />
-
-
-    </androidx.constraintlayout.widget.ConstraintLayout>
+                app:layout_constraintTop_toBottomOf="@+id/view_choose_country" />
+
+        </LinearLayout>
+    </ScrollView>
 </layout>

+ 1 - 0
app/src/main/res/layout/activity_register_more.xml

@@ -100,6 +100,7 @@
             android:id="@+id/rv_tags"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
             android:layout_marginHorizontal="15dp"
             android:maxHeight="260dp"
             android:overScrollMode="never"

+ 2 - 1
app/src/main/res/layout/item_tag.xml

@@ -7,8 +7,9 @@
     android:gravity="center"
     android:orientation="horizontal"
     android:layout_marginEnd="10dp"
+    android:layout_marginBottom="5dp"
     android:paddingStart="10dp"
-    android:paddingVertical="10dp"
+    android:paddingVertical="5dp"
     android:paddingEnd="20dp">
 
     <ImageView