初始化1v1语聊项目
5
OneToOne/src/main/res/drawable/tab_dynamic.xml
Normal file
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@mipmap/ic_tab_dynamic_select" android:state_selected="true" />
|
||||
<item android:drawable="@mipmap/ic_tab_dynamic" />
|
||||
</selector>
|
||||
13
OneToOne/src/main/res/drawable/tab_friends.xml
Normal file
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_checked="true">
|
||||
<inset >
|
||||
<bitmap android:src="@mipmap/ic_tab_friends_select" />
|
||||
</inset>
|
||||
</item>
|
||||
<item android:state_checked="false">
|
||||
<inset>
|
||||
<bitmap android:src="@mipmap/ic_tab_friends" />
|
||||
</inset>
|
||||
</item>
|
||||
</selector>
|
||||
5
OneToOne/src/main/res/drawable/tab_msg.xml
Normal file
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@mipmap/ic_tab_msg_select" android:state_selected="true" />
|
||||
<item android:drawable="@mipmap/ic_tab_msg" />
|
||||
</selector>
|
||||
5
OneToOne/src/main/res/drawable/tab_my.xml
Normal file
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@mipmap/ic_tab_my_select" android:state_selected="true" />
|
||||
<item android:drawable="@mipmap/ic_tab_my" />
|
||||
</selector>
|
||||
10
OneToOne/src/main/res/layout/activity_launcher.xml
Normal file
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".activitys.LauncherActivity">
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
58
OneToOne/src/main/res/layout/activity_main.xml
Normal file
@@ -0,0 +1,58 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout 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"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".activitys.MainActivity">
|
||||
|
||||
<androidx.viewpager2.widget.ViewPager2
|
||||
android:id="@+id/viewPager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintBottom_toTopOf="@+id/dslTabLayout"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" >
|
||||
|
||||
|
||||
</androidx.viewpager2.widget.ViewPager2>
|
||||
|
||||
<com.angcyo.tablayout.DslTabLayout
|
||||
android:id="@+id/dslTabLayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:background="@color/white"
|
||||
app:tab_item_is_equ_width="true"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
<TextView
|
||||
android:id="@+id/textView"
|
||||
android:gravity="center"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:text="TextView"
|
||||
app:drawableTopCompat="@drawable/tab_friends" />
|
||||
<TextView
|
||||
android:id="@+id/textView2"
|
||||
android:gravity="center"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:text="TextView"
|
||||
app:drawableTopCompat="@drawable/tab_dynamic" />
|
||||
<TextView
|
||||
android:id="@+id/textView3"
|
||||
android:gravity="center"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:text="TextView"
|
||||
app:drawableTopCompat="@drawable/tab_msg" />
|
||||
<TextView
|
||||
android:id="@+id/textView4"
|
||||
android:gravity="center"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:text="TextView"
|
||||
app:drawableTopCompat="@drawable/tab_my" />
|
||||
</com.angcyo.tablayout.DslTabLayout>
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
15
OneToOne/src/main/res/layout/fragment_dynamic.xml
Normal file
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
<Button
|
||||
android:id="@+id/button2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="357dp"
|
||||
android:layout_marginEnd="142dp"
|
||||
android:text="Dynamic"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
17
OneToOne/src/main/res/layout/fragment_friends.xml
Normal file
@@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout 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"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<Button
|
||||
android:id="@+id/button2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="357dp"
|
||||
android:layout_marginEnd="142dp"
|
||||
android:text="Friends"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
15
OneToOne/src/main/res/layout/fragment_msg.xml
Normal file
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
<Button
|
||||
android:id="@+id/button2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="357dp"
|
||||
android:layout_marginEnd="142dp"
|
||||
android:text="Msg"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
15
OneToOne/src/main/res/layout/fragment_my.xml
Normal file
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
<Button
|
||||
android:id="@+id/button2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="357dp"
|
||||
android:layout_marginEnd="142dp"
|
||||
android:text="My"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
BIN
OneToOne/src/main/res/mipmap-xxhdpi/ic_tab_dynamic.png
Normal file
|
After Width: | Height: | Size: 5.7 KiB |
BIN
OneToOne/src/main/res/mipmap-xxhdpi/ic_tab_dynamic_select.png
Normal file
|
After Width: | Height: | Size: 5.8 KiB |
BIN
OneToOne/src/main/res/mipmap-xxhdpi/ic_tab_friends.png
Normal file
|
After Width: | Height: | Size: 5.2 KiB |
BIN
OneToOne/src/main/res/mipmap-xxhdpi/ic_tab_friends_select.png
Normal file
|
After Width: | Height: | Size: 6.0 KiB |
BIN
OneToOne/src/main/res/mipmap-xxhdpi/ic_tab_msg.png
Normal file
|
After Width: | Height: | Size: 4.9 KiB |
BIN
OneToOne/src/main/res/mipmap-xxhdpi/ic_tab_msg_select.png
Normal file
|
After Width: | Height: | Size: 5.9 KiB |
BIN
OneToOne/src/main/res/mipmap-xxhdpi/ic_tab_my.png
Normal file
|
After Width: | Height: | Size: 5.5 KiB |
BIN
OneToOne/src/main/res/mipmap-xxhdpi/ic_tab_my_select.png
Normal file
|
After Width: | Height: | Size: 6.0 KiB |
4
OneToOne/src/main/res/values-zh-rHK/strings.xml
Normal file
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="app_name">1v1</string>
|
||||
</resources>
|
||||
4
OneToOne/src/main/res/values-zh-rTW/strings.xml
Normal file
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="app_name">1v1</string>
|
||||
</resources>
|
||||
3
OneToOne/src/main/res/values/strings.xml
Normal file
@@ -0,0 +1,3 @@
|
||||
<resources>
|
||||
<string name="app_name">1v1</string>
|
||||
</resources>
|
||||