修改主页样式
This commit is contained in:
@@ -16,8 +16,8 @@ android {
|
|||||||
applicationId "com.uiui.aios"
|
applicationId "com.uiui.aios"
|
||||||
minSdkVersion 24
|
minSdkVersion 24
|
||||||
targetSdkVersion 29
|
targetSdkVersion 29
|
||||||
versionCode 29
|
versionCode 31
|
||||||
versionName "3.8"
|
versionName "4.0"
|
||||||
|
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
|
||||||
|
|||||||
@@ -19,6 +19,7 @@ import android.widget.TextView;
|
|||||||
|
|
||||||
import com.blankj.utilcode.util.NetworkUtils;
|
import com.blankj.utilcode.util.NetworkUtils;
|
||||||
import com.bumptech.glide.Glide;
|
import com.bumptech.glide.Glide;
|
||||||
|
import com.shehuan.niv.NiceImageView;
|
||||||
import com.trello.rxlifecycle4.RxLifecycle;
|
import com.trello.rxlifecycle4.RxLifecycle;
|
||||||
import com.trello.rxlifecycle4.android.FragmentEvent;
|
import com.trello.rxlifecycle4.android.FragmentEvent;
|
||||||
import com.uiui.aios.R;
|
import com.uiui.aios.R;
|
||||||
@@ -113,6 +114,12 @@ public class SecondFragment extends BaseFragment implements NetworkUtils.OnNetwo
|
|||||||
@BindView(R.id.cl4)
|
@BindView(R.id.cl4)
|
||||||
ConstraintLayout cl4;
|
ConstraintLayout cl4;
|
||||||
|
|
||||||
|
@BindView(R.id.nv_pic)
|
||||||
|
NiceImageView nv_pic;
|
||||||
|
@BindView(R.id.tv_like)
|
||||||
|
TextView tv_like;
|
||||||
|
@BindView(R.id.tv_comment)
|
||||||
|
TextView tv_comment;
|
||||||
|
|
||||||
private View rootView;
|
private View rootView;
|
||||||
private Context mContext;
|
private Context mContext;
|
||||||
@@ -265,12 +272,15 @@ public class SecondFragment extends BaseFragment implements NetworkUtils.OnNetwo
|
|||||||
tv_title_a.setText(activity.getName());
|
tv_title_a.setText(activity.getName());
|
||||||
tc_joined_num_a.setText(activity.getJoin_num() + "人参加");
|
tc_joined_num_a.setText(activity.getJoin_num() + "人参加");
|
||||||
tv_time_a.setText(getTime(activity.getAdd_time()));
|
tv_time_a.setText(getTime(activity.getAdd_time()));
|
||||||
tv_address_a.setText(activity.getAddress());
|
tv_address_a.setText(activity.getLocation());
|
||||||
|
Glide.with(nv_pic).load(activity.getFile()).centerCrop().into(nv_pic);
|
||||||
|
tv_like.setText(activity.getLike_count() + "");
|
||||||
|
tv_comment.setText(activity.getComment_count() + "");
|
||||||
}
|
}
|
||||||
|
|
||||||
private String getTime(long second) {
|
private String getTime(long second) {
|
||||||
long ms = second * 1000L;
|
long ms = second * 1000L;
|
||||||
SimpleDateFormat sdf = new SimpleDateFormat("MM月dd日 HH:mm");
|
SimpleDateFormat sdf = new SimpleDateFormat("MM月dd日");
|
||||||
Date date = new Date(ms);
|
Date date = new Date(ms);
|
||||||
String time = sdf.format(date);
|
String time = sdf.format(date);
|
||||||
Log.e(TAG, "getTime: " + time);
|
Log.e(TAG, "getTime: " + time);
|
||||||
|
|||||||
BIN
app/src/main/res/drawable-hdpi/location.png
Normal file
BIN
app/src/main/res/drawable-hdpi/location.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.8 KiB |
BIN
app/src/main/res/drawable-hdpi/shafa.png
Normal file
BIN
app/src/main/res/drawable-hdpi/shafa.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.6 KiB |
BIN
app/src/main/res/drawable-hdpi/zan.png
Normal file
BIN
app/src/main/res/drawable-hdpi/zan.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.1 KiB |
@@ -175,8 +175,8 @@
|
|||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="vertical"
|
android:layout_weight="1"
|
||||||
android:layout_weight="1">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
@@ -315,21 +315,22 @@
|
|||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/cl3"
|
android:id="@+id/cl3"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="0dp"
|
||||||
android:visibility="gone"
|
android:visibility="visible"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent">
|
app:layout_constraintTop_toBottomOf="@+id/textView18">
|
||||||
|
|
||||||
<com.shehuan.niv.NiceImageView
|
<com.shehuan.niv.NiceImageView
|
||||||
android:id="@+id/iv_avatar_a"
|
android:id="@+id/iv_avatar_a"
|
||||||
android:layout_width="92dp"
|
android:layout_width="@dimen/dp_36"
|
||||||
android:layout_height="92dp"
|
android:layout_height="@dimen/dp_36"
|
||||||
|
android:layout_marginStart="@dimen/dp_16"
|
||||||
|
android:layout_marginTop="@dimen/dp_16"
|
||||||
android:src="@drawable/default_head"
|
android:src="@drawable/default_head"
|
||||||
app:is_circle="true"
|
app:is_circle="true"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
@@ -341,10 +342,10 @@
|
|||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:text="活动名称"
|
android:text="活动名称"
|
||||||
android:textColor="@color/black"
|
android:textColor="@color/black"
|
||||||
android:textSize="22sp"
|
android:textSize="@dimen/sp_12"
|
||||||
android:textStyle="bold"
|
android:textStyle="bold"
|
||||||
app:layout_constraintStart_toEndOf="@+id/iv_avatar_a"
|
app:layout_constraintStart_toEndOf="@+id/iv_avatar_a"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="@+id/iv_avatar_a" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tc_joined_num_a"
|
android:id="@+id/tc_joined_num_a"
|
||||||
@@ -354,6 +355,7 @@
|
|||||||
android:background="@drawable/join_background"
|
android:background="@drawable/join_background"
|
||||||
android:text="0人参加"
|
android:text="0人参加"
|
||||||
android:textColor="@color/white"
|
android:textColor="@color/white"
|
||||||
|
android:visibility="gone"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/tv_title_a"
|
app:layout_constraintBottom_toBottomOf="@+id/tv_title_a"
|
||||||
app:layout_constraintStart_toEndOf="@+id/tv_title_a"
|
app:layout_constraintStart_toEndOf="@+id/tv_title_a"
|
||||||
app:layout_constraintTop_toTopOf="@+id/tv_title_a" />
|
app:layout_constraintTop_toTopOf="@+id/tv_title_a" />
|
||||||
@@ -366,38 +368,129 @@
|
|||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:text="时间"
|
android:text="时间"
|
||||||
android:textColor="@color/black"
|
android:textColor="@color/black"
|
||||||
android:textSize="20sp"
|
android:textSize="@dimen/sp_11"
|
||||||
app:layout_constraintStart_toStartOf="@+id/tv_title_a"
|
app:layout_constraintStart_toStartOf="@+id/tv_title_a"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tv_title_a" />
|
app:layout_constraintTop_toBottomOf="@+id/tv_title_a" />
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="@dimen/dp_4"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="@+id/iv_avatar_a">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/imageView2"
|
||||||
|
android:layout_width="@dimen/dp_10"
|
||||||
|
android:layout_height="@dimen/dp_10"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
android:scaleType="centerInside"
|
||||||
|
android:src="@drawable/location"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_address_a"
|
android:id="@+id/tv_address_a"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="2dp"
|
|
||||||
android:gravity="start"
|
android:gravity="start"
|
||||||
android:maxEms="12"
|
android:maxEms="12"
|
||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:text="地点"
|
android:text="地点"
|
||||||
android:textColor="@color/black"
|
android:textColor="@color/black"
|
||||||
android:textSize="20sp"
|
android:textSize="@dimen/sp_10"
|
||||||
app:layout_constraintStart_toStartOf="@+id/tv_time_a"
|
app:layout_constraintBottom_toBottomOf="@+id/imageView2"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tv_time_a" />
|
app:layout_constraintStart_toEndOf="@+id/imageView2"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/imageView2" />
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<com.shehuan.niv.NiceImageView
|
||||||
|
android:id="@+id/nv_pic"
|
||||||
|
android:layout_width="@dimen/dp_100"
|
||||||
|
android:layout_height="@dimen/dp_100"
|
||||||
|
android:layout_marginEnd="@dimen/dp_16"
|
||||||
|
app:corner_radius="@dimen/dp_4"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:id="@+id/cl_comment"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="@dimen/dp_4"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="@+id/nv_pic">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/imageView3"
|
||||||
|
android:layout_width="@dimen/dp_10"
|
||||||
|
android:layout_height="@dimen/dp_10"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
android:scaleType="fitCenter"
|
||||||
|
android:src="@drawable/shafa"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comment"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="@dimen/dp_4"
|
||||||
|
android:text="0"
|
||||||
|
android:textSize="@dimen/sp_10"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@+id/imageView3"
|
||||||
|
app:layout_constraintStart_toEndOf="@+id/imageView3"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/imageView3" />
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:id="@+id/cl_like"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginEnd="@dimen/dp_24"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@+id/cl_comment"
|
||||||
|
app:layout_constraintEnd_toStartOf="@+id/cl_comment"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/cl_comment">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_like"
|
||||||
|
android:layout_width="@dimen/dp_10"
|
||||||
|
android:layout_height="@dimen/dp_10"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
android:scaleType="fitCenter"
|
||||||
|
android:src="@drawable/zan"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_like"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="@dimen/dp_4"
|
||||||
|
android:text="0"
|
||||||
|
android:textSize="@dimen/sp_10"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@+id/iv_like"
|
||||||
|
app:layout_constraintStart_toEndOf="@+id/iv_like"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/iv_like" />
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/cl_demand"
|
android:id="@+id/cl_demand"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_marginStart="4dp"
|
android:layout_marginStart="4dp"
|
||||||
android:layout_marginTop="4dp"
|
android:layout_marginTop="4dp"
|
||||||
android:layout_marginEnd="8dp"
|
android:layout_marginEnd="8dp"
|
||||||
android:layout_marginBottom="8dp"
|
android:layout_marginBottom="8dp"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:background="@drawable/custom_background">
|
android:background="@drawable/custom_background"
|
||||||
|
android:visibility="gone">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/iv4"
|
android:id="@+id/iv4"
|
||||||
@@ -470,7 +563,6 @@
|
|||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tc_joined_num_d"
|
android:id="@+id/tc_joined_num_d"
|
||||||
app:layout_goneMarginStart="4dp"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginStart="6dp"
|
android:layout_marginStart="6dp"
|
||||||
@@ -479,7 +571,8 @@
|
|||||||
android:textColor="@color/white"
|
android:textColor="@color/white"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/tv_title_d"
|
app:layout_constraintBottom_toBottomOf="@+id/tv_title_d"
|
||||||
app:layout_constraintStart_toEndOf="@+id/tv_title_d"
|
app:layout_constraintStart_toEndOf="@+id/tv_title_d"
|
||||||
app:layout_constraintTop_toTopOf="@+id/tv_title_d" />
|
app:layout_constraintTop_toTopOf="@+id/tv_title_d"
|
||||||
|
app:layout_goneMarginStart="4dp" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_time_d"
|
android:id="@+id/tv_time_d"
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
android:layout_marginTop="8dp"
|
android:layout_marginTop="8dp"
|
||||||
android:layout_marginEnd="8dp"
|
android:layout_marginEnd="8dp"
|
||||||
android:layout_marginBottom="4dp"
|
android:layout_marginBottom="4dp"
|
||||||
android:layout_weight="1"
|
android:layout_weight="3"
|
||||||
android:background="@drawable/custom_background">
|
android:background="@drawable/custom_background">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
@@ -262,7 +262,7 @@
|
|||||||
android:layout_marginTop="4dp"
|
android:layout_marginTop="4dp"
|
||||||
android:layout_marginEnd="8dp"
|
android:layout_marginEnd="8dp"
|
||||||
android:layout_marginBottom="8dp"
|
android:layout_marginBottom="8dp"
|
||||||
android:layout_weight="3"
|
android:layout_weight="2"
|
||||||
android:background="@drawable/custom_background">
|
android:background="@drawable/custom_background">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
@@ -303,21 +303,22 @@
|
|||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/cl3"
|
android:id="@+id/cl3"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="0dp"
|
||||||
android:visibility="gone"
|
android:visibility="visible"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent">
|
app:layout_constraintTop_toBottomOf="@+id/textView18">
|
||||||
|
|
||||||
<com.shehuan.niv.NiceImageView
|
<com.shehuan.niv.NiceImageView
|
||||||
android:id="@+id/iv_avatar_a"
|
android:id="@+id/iv_avatar_a"
|
||||||
android:layout_width="92dp"
|
android:layout_width="@dimen/dp_36"
|
||||||
android:layout_height="92dp"
|
android:layout_height="@dimen/dp_36"
|
||||||
|
android:layout_marginStart="@dimen/dp_16"
|
||||||
|
android:layout_marginTop="@dimen/dp_16"
|
||||||
android:src="@drawable/default_head"
|
android:src="@drawable/default_head"
|
||||||
app:is_circle="true"
|
app:is_circle="true"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
@@ -329,10 +330,10 @@
|
|||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:text="活动名称"
|
android:text="活动名称"
|
||||||
android:textColor="@color/black"
|
android:textColor="@color/black"
|
||||||
android:textSize="22sp"
|
android:textSize="@dimen/sp_12"
|
||||||
android:textStyle="bold"
|
android:textStyle="bold"
|
||||||
app:layout_constraintStart_toEndOf="@+id/iv_avatar_a"
|
app:layout_constraintStart_toEndOf="@+id/iv_avatar_a"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="@+id/iv_avatar_a" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tc_joined_num_a"
|
android:id="@+id/tc_joined_num_a"
|
||||||
@@ -342,6 +343,7 @@
|
|||||||
android:background="@drawable/join_background"
|
android:background="@drawable/join_background"
|
||||||
android:text="0人参加"
|
android:text="0人参加"
|
||||||
android:textColor="@color/white"
|
android:textColor="@color/white"
|
||||||
|
android:visibility="gone"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/tv_title_a"
|
app:layout_constraintBottom_toBottomOf="@+id/tv_title_a"
|
||||||
app:layout_constraintStart_toEndOf="@+id/tv_title_a"
|
app:layout_constraintStart_toEndOf="@+id/tv_title_a"
|
||||||
app:layout_constraintTop_toTopOf="@+id/tv_title_a" />
|
app:layout_constraintTop_toTopOf="@+id/tv_title_a" />
|
||||||
@@ -354,25 +356,117 @@
|
|||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:text="时间"
|
android:text="时间"
|
||||||
android:textColor="@color/black"
|
android:textColor="@color/black"
|
||||||
android:textSize="20sp"
|
android:textSize="@dimen/sp_11"
|
||||||
app:layout_constraintStart_toStartOf="@+id/tv_title_a"
|
app:layout_constraintStart_toStartOf="@+id/tv_title_a"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tv_title_a" />
|
app:layout_constraintTop_toBottomOf="@+id/tv_title_a" />
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="@dimen/dp_4"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="@+id/iv_avatar_a">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/imageView2"
|
||||||
|
android:layout_width="@dimen/dp_16"
|
||||||
|
android:layout_height="@dimen/dp_16"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
android:scaleType="centerInside"
|
||||||
|
android:src="@drawable/location"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_address_a"
|
android:id="@+id/tv_address_a"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="2dp"
|
|
||||||
android:gravity="start"
|
android:gravity="start"
|
||||||
android:maxEms="12"
|
android:maxEms="12"
|
||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:text="地点"
|
android:text="地点"
|
||||||
android:textColor="@color/black"
|
android:textColor="@color/black"
|
||||||
android:textSize="20sp"
|
android:textSize="@dimen/sp_11"
|
||||||
app:layout_constraintStart_toStartOf="@+id/tv_time_a"
|
app:layout_constraintBottom_toBottomOf="@+id/imageView2"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tv_time_a" />
|
app:layout_constraintStart_toEndOf="@+id/imageView2"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/imageView2" />
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<com.shehuan.niv.NiceImageView
|
||||||
|
android:id="@+id/nv_pic"
|
||||||
|
android:layout_width="@dimen/dp_100"
|
||||||
|
android:layout_height="@dimen/dp_100"
|
||||||
|
android:layout_marginEnd="@dimen/dp_16"
|
||||||
|
app:corner_radius="@dimen/dp_4"
|
||||||
|
app:layout_constraintBottom_toTopOf="@+id/cl_like"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:id="@+id/cl_comment"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="@dimen/dp_4"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="@+id/nv_pic">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/imageView3"
|
||||||
|
android:layout_width="@dimen/dp_16"
|
||||||
|
android:layout_height="@dimen/dp_16"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
android:scaleType="fitCenter"
|
||||||
|
android:src="@drawable/shafa"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comment"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="0"
|
||||||
|
android:textSize="@dimen/sp_11"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@+id/imageView3"
|
||||||
|
app:layout_constraintStart_toEndOf="@+id/imageView3"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/imageView3" />
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:id="@+id/cl_like"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginEnd="@dimen/dp_24"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@+id/cl_comment"
|
||||||
|
app:layout_constraintEnd_toStartOf="@+id/cl_comment"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/cl_comment">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_like"
|
||||||
|
android:layout_width="@dimen/dp_16"
|
||||||
|
android:layout_height="@dimen/dp_16"
|
||||||
|
android:adjustViewBounds="true"
|
||||||
|
android:scaleType="fitCenter"
|
||||||
|
android:src="@drawable/zan"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_like"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="@dimen/dp_4"
|
||||||
|
android:text="0"
|
||||||
|
android:textSize="@dimen/sp_11"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@+id/iv_like"
|
||||||
|
app:layout_constraintStart_toEndOf="@+id/iv_like"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/iv_like" />
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
|||||||
Reference in New Issue
Block a user