头像显示 and 爵位内页 优化
This commit is contained in:
@@ -67,6 +67,8 @@ dependencies {
|
|||||||
implementation project(':moduletablayout')
|
implementation project(':moduletablayout')
|
||||||
implementation libs.activity
|
implementation libs.activity
|
||||||
implementation libs.constraintlayout
|
implementation libs.constraintlayout
|
||||||
|
api 'androidx.activity:activity-compose:1.8.2'
|
||||||
|
|
||||||
testImplementation libs.junit
|
testImplementation libs.junit
|
||||||
androidTestImplementation libs.ext.junit
|
androidTestImplementation libs.ext.junit
|
||||||
androidTestImplementation libs.espresso.core
|
androidTestImplementation libs.espresso.core
|
||||||
|
|||||||
@@ -209,8 +209,21 @@ public class ImageUtils {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Glide.with(mImageView).load(path).error(R.mipmap.default_avatar).placeholder(R.mipmap.default_avatar).diskCacheStrategy(DiskCacheStrategy.ALL).into(mImageView);
|
Glide.with(mImageView).load(path).error(R.mipmap.default_avatar).placeholder(R.mipmap.default_avatar).centerCrop().diskCacheStrategy(DiskCacheStrategy.ALL).into(mImageView);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void loadHead(String path, ImageView mImageView) {
|
||||||
|
if (mImageView == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
Context context = mImageView.getContext();
|
||||||
|
if (context instanceof android.app.Activity) {
|
||||||
|
android.app.Activity activity = (android.app.Activity) context;
|
||||||
|
if (activity.isFinishing() || (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR1 && activity.isDestroyed())) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Glide.with(mImageView).load(path).error(R.mipmap.default_avatar).placeholder(R.mipmap.default_avatar).diskCacheStrategy(DiskCacheStrategy.ALL).into(mImageView);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void loadHeadCC(String path, ImageView mImageView, LinearLayout.LayoutParams params) {
|
public static void loadHeadCC(String path, ImageView mImageView, LinearLayout.LayoutParams params) {
|
||||||
|
|||||||
@@ -49,11 +49,10 @@ public class MeHeadView extends ConstraintLayout {
|
|||||||
public void setData(String headPicture, String framePicture, String nobilityImage) {
|
public void setData(String headPicture, String framePicture, String nobilityImage) {
|
||||||
Logger.e(headPicture, framePicture, nobilityImage);
|
Logger.e(headPicture, framePicture, nobilityImage);
|
||||||
if (!TextUtils.isEmpty(headPicture)) {
|
if (!TextUtils.isEmpty(headPicture)) {
|
||||||
ImageUtils.loadHeadCC(headPicture, mRiv);
|
ImageUtils.loadHead(headPicture, mRiv);
|
||||||
}
|
}
|
||||||
if (TextUtils.isEmpty(framePicture)) {
|
if (TextUtils.isEmpty(framePicture)) {
|
||||||
mIvFrame.setVisibility(GONE);
|
mIvFrame.setVisibility(GONE);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
mIvFrame.setVisibility(VISIBLE);
|
mIvFrame.setVisibility(VISIBLE);
|
||||||
mIvFrame.setSource(framePicture, 1);
|
mIvFrame.setSource(framePicture, 1);
|
||||||
@@ -73,7 +72,7 @@ public class MeHeadView extends ConstraintLayout {
|
|||||||
|
|
||||||
if (nobilityImage!=null && !TextUtils.isEmpty(nobilityImage)){
|
if (nobilityImage!=null && !TextUtils.isEmpty(nobilityImage)){
|
||||||
iv_frame_bg.setVisibility(VISIBLE);
|
iv_frame_bg.setVisibility(VISIBLE);
|
||||||
ImageUtils.loadHeadCC(nobilityImage, iv_frame_bg);
|
ImageUtils.loadHead(nobilityImage, iv_frame_bg);
|
||||||
}else {
|
}else {
|
||||||
iv_frame_bg.setVisibility(GONE);
|
iv_frame_bg.setVisibility(GONE);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -185,7 +185,7 @@ public abstract class BaseWheatView extends ConstraintLayout implements IBaseWhe
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
parser.decodeFromAssets("ripple3695.svga", new SVGAParser.ParseCompletion() {
|
parser.decodeFromAssets("mic.svga", new SVGAParser.ParseCompletion() {
|
||||||
@Override
|
@Override
|
||||||
public void onComplete(@Nullable SVGAVideoEntity videoItem) {
|
public void onComplete(@Nullable SVGAVideoEntity videoItem) {
|
||||||
if (videoItem != null) {
|
if (videoItem != null) {
|
||||||
|
|||||||
@@ -114,7 +114,7 @@ public class RoomSingWheatView extends LinearLayout {
|
|||||||
|
|
||||||
if (isOn()) {
|
if (isOn()) {
|
||||||
//开启声浪
|
//开启声浪
|
||||||
mIvRipple.startLoopingSvga("ripple3695.svga");
|
mIvRipple.startLoopingSvga("mic.svga");
|
||||||
mIvRipple.setVisibility(VISIBLE);
|
mIvRipple.setVisibility(VISIBLE);
|
||||||
mTvName.setText(bean.getNickname());
|
mTvName.setText(bean.getNickname());
|
||||||
ImageUtils.loadHeadCC(bean.getAvatar(), mRiv);
|
ImageUtils.loadHeadCC(bean.getAvatar(), mRiv);
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
<!-- app:layout_constraintEnd_toEndOf="parent"/>-->
|
<!-- app:layout_constraintEnd_toEndOf="parent"/>-->
|
||||||
|
|
||||||
<!-- 用户头像 -->
|
<!-- 用户头像 -->
|
||||||
<com.xscm.moduleutil.widget.GifAvatarOvalView
|
<com.xscm.moduleutil.utils.MeHeadView
|
||||||
android:id="@+id/avatar"
|
android:id="@+id/avatar"
|
||||||
android:layout_width="@dimen/dp_28"
|
android:layout_width="@dimen/dp_28"
|
||||||
android:layout_height="@dimen/dp_28"
|
android:layout_height="@dimen/dp_28"
|
||||||
|
|||||||
@@ -1,80 +1,78 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:layout_width="wrap_content"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:layout_height="wrap_content"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:clipChildren="false"
|
android:layout_width="match_parent"
|
||||||
android:clipToPadding="false"
|
android:layout_height="wrap_content"
|
||||||
xmlns:tools="http://schemas.android.com/tools">
|
android:clipChildren="false"
|
||||||
|
android:clipToPadding="false">
|
||||||
|
|
||||||
<com.xscm.moduleutil.widget.GifAvatarOvalView
|
<com.xscm.moduleutil.widget.CircularImage
|
||||||
android:id="@+id/riv"
|
android:id="@+id/riv"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
android:background="@drawable/me_avatar_bg"
|
android:background="@drawable/me_avatar_bg"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
android:src="@mipmap/default_avatar"
|
||||||
app:layout_constraintDimensionRatio="1:1"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintDimensionRatio="1:1"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintWidth_percent="0.90154"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
android:src="@mipmap/default_avatar"
|
app:layout_constraintWidth_percent="0.8"
|
||||||
app:riv_oval="true"/>
|
app:riv_oval="true" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/iv_sex"
|
android:id="@+id/iv_sex"
|
||||||
android:layout_width="@dimen/dp_16"
|
android:layout_width="@dimen/dp_16"
|
||||||
android:layout_height="@dimen/dp_16"
|
android:layout_height="@dimen/dp_16"
|
||||||
android:background="@mipmap/nan"
|
android:background="@mipmap/nan"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
tools:visibility="visible"
|
app:layout_constraintBottom_toBottomOf="@id/riv"
|
||||||
app:layout_constraintBottom_toBottomOf="@id/riv"
|
app:layout_constraintEnd_toEndOf="@id/riv"
|
||||||
app:layout_constraintEnd_toEndOf="@id/riv"
|
tools:visibility="visible" />
|
||||||
/>
|
|
||||||
|
|
||||||
<com.xscm.moduleutil.widget.AvatarFrameView
|
<com.xscm.moduleutil.widget.AvatarFrameView
|
||||||
android:id="@+id/iv_frame"
|
android:id="@+id/iv_frame"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
android:contentDescription="@null"
|
android:contentDescription="@null"
|
||||||
android:scaleType="fitXY"
|
android:scaleType="fitXY"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintDimensionRatio="1:1"
|
app:layout_constraintDimensionRatio="1:1"
|
||||||
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_toTopOf="parent" />
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.Guideline
|
<androidx.constraintlayout.widget.Guideline
|
||||||
android:id="@+id/guideline"
|
android:id="@+id/guideline"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="@dimen/dp_1"
|
android:layout_height="@dimen/dp_1"
|
||||||
android:orientation="horizontal"
|
android:orientation="horizontal"
|
||||||
app:layout_constraintGuide_percent="0.58"
|
app:layout_constraintGuide_percent="0.5" />
|
||||||
/>
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/iv_frame_bg"
|
android:id="@+id/iv_frame_bg"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
android:contentDescription="@null"
|
android:contentDescription="@null"
|
||||||
android:scaleType="fitXY"
|
android:scaleType="fitXY"
|
||||||
tools:src="@mipmap/me_sj"
|
app:layout_constraintHeight_default="spread"
|
||||||
app:layout_constraintTop_toTopOf="@+id/guideline"
|
app:layout_constraintTop_toTopOf="@+id/guideline"
|
||||||
app:layout_constraintWidth_default="spread"
|
app:layout_constraintWidth_default="spread"
|
||||||
app:layout_constraintHeight_default="spread"
|
tools:src="@mipmap/me_sj" />
|
||||||
/>
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/iv_online"
|
android:id="@+id/iv_online"
|
||||||
android:layout_width="@dimen/dp_13"
|
android:layout_width="@dimen/dp_13"
|
||||||
android:layout_height="@dimen/dp_13"
|
android:layout_height="@dimen/dp_13"
|
||||||
android:src="@mipmap/me_online_icon"
|
android:src="@mipmap/me_online_icon"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
app:layout_constraintBottom_toBottomOf="@id/riv"
|
app:layout_constraintBottom_toBottomOf="@id/riv"
|
||||||
app:layout_constraintEnd_toEndOf="@id/riv"
|
app:layout_constraintEnd_toEndOf="@id/riv"
|
||||||
app:layout_constraintHorizontal_bias="0.9"
|
app:layout_constraintHorizontal_bias="0.9"
|
||||||
app:layout_constraintStart_toStartOf="@id/riv"
|
app:layout_constraintStart_toStartOf="@id/riv"
|
||||||
app:layout_constraintTop_toTopOf="@id/riv"
|
app:layout_constraintTop_toTopOf="@id/riv"
|
||||||
app:layout_constraintVertical_bias="0.9"/>
|
app:layout_constraintVertical_bias="0.9" />
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
@@ -41,7 +41,7 @@
|
|||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
app:loopCount="0"
|
app:loopCount="0"
|
||||||
app:source="ripple3695.svga" />
|
app:source="mic.svga" />
|
||||||
|
|
||||||
<!-- <com.xscm.moduleutil.widget.AvatarFrameView-->
|
<!-- <com.xscm.moduleutil.widget.AvatarFrameView-->
|
||||||
<!-- android:id="@+id/iv_ripple"-->
|
<!-- android:id="@+id/iv_ripple"-->
|
||||||
|
|||||||
@@ -53,7 +53,7 @@
|
|||||||
app:layout_constraintStart_toStartOf="@id/iv_frame"
|
app:layout_constraintStart_toStartOf="@id/iv_frame"
|
||||||
app:layout_constraintTop_toTopOf="@id/iv_frame"
|
app:layout_constraintTop_toTopOf="@id/iv_frame"
|
||||||
app:loopCount="0"
|
app:loopCount="0"
|
||||||
app:source="ripple3695.svga" />
|
app:source="mic.svga" />
|
||||||
|
|
||||||
<!-- <com.xscm.moduleutil.widget.AvatarFrameView-->
|
<!-- <com.xscm.moduleutil.widget.AvatarFrameView-->
|
||||||
<!-- android:id="@+id/iv_ripple"-->
|
<!-- android:id="@+id/iv_ripple"-->
|
||||||
|
|||||||
@@ -77,7 +77,7 @@
|
|||||||
app:layout_constraintHeight_default="percent"
|
app:layout_constraintHeight_default="percent"
|
||||||
app:layout_constraintHeight_percent="0.52"
|
app:layout_constraintHeight_percent="0.52"
|
||||||
app:loopCount="0"
|
app:loopCount="0"
|
||||||
app:source="ripple3695.svga" />
|
app:source="mic.svga" />
|
||||||
|
|
||||||
|
|
||||||
<!--离线状态 - 和头像框一样大,在标签下面-->
|
<!--离线状态 - 和头像框一样大,在标签下面-->
|
||||||
|
|||||||
@@ -55,7 +55,7 @@
|
|||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
app:layout_constraintWidth_percent="0.8"
|
app:layout_constraintWidth_percent="0.8"
|
||||||
app:loopCount="0"
|
app:loopCount="0"
|
||||||
app:source="ripple3695.svga"
|
app:source="mic.svga"
|
||||||
tools:visibility="visible" />
|
tools:visibility="visible" />
|
||||||
|
|
||||||
<!-- <com.xscm.moduleutil.widget.AvatarFrameView-->
|
<!-- <com.xscm.moduleutil.widget.AvatarFrameView-->
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ open class Application : CommonAppContext() {
|
|||||||
|
|
||||||
private fun initLogUtils() {
|
private fun initLogUtils() {
|
||||||
LogUtils.getConfig()
|
LogUtils.getConfig()
|
||||||
.setLogSwitch(false) // 全局开关
|
.setLogSwitch(true) // 全局开关
|
||||||
.setLog2FileSwitch(true) // 必须设为 true!
|
.setLog2FileSwitch(true) // 必须设为 true!
|
||||||
.setDir(LOGUTILS_SAVE_PATH) // 设置有效路径
|
.setDir(LOGUTILS_SAVE_PATH) // 设置有效路径
|
||||||
.setFileFilter(LogUtils.V); // 允许所有级别
|
.setFileFilter(LogUtils.V); // 允许所有级别
|
||||||
|
|||||||
@@ -107,6 +107,7 @@ public class NobleDetailsActivity extends BaseMvpActivity<NobleTitlePresenter, A
|
|||||||
|
|
||||||
mAdapter = new NobliityBannerAdapter();
|
mAdapter = new NobliityBannerAdapter();
|
||||||
mBinding.banner
|
mBinding.banner
|
||||||
|
.setOffScreenPageLimit(nobilitLists.size()-1)
|
||||||
.setAdapter(mAdapter)
|
.setAdapter(mAdapter)
|
||||||
.setAutoPlay(false)
|
.setAutoPlay(false)
|
||||||
.setIndicatorVisibility(GONE)
|
.setIndicatorVisibility(GONE)
|
||||||
|
|||||||
@@ -214,9 +214,9 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
|||||||
|
|
||||||
MeHeadView avatar = helper.getView(com.xscm.moduleutil.R.id.avatar);
|
MeHeadView avatar = helper.getView(com.xscm.moduleutil.R.id.avatar);
|
||||||
avatar.setData(emMessage.getText().getFromUserInfo().getAvatar(), "", emMessage.getText().getFromUserInfo().getNobility_image());
|
avatar.setData(emMessage.getText().getFromUserInfo().getAvatar(), "", emMessage.getText().getFromUserInfo().getNobility_image());
|
||||||
ImageUtils.loadHeadCC(emMessage.getText().getFromUserInfo().getAvatar(), helper.getView(com.xscm.moduleutil.R.id.avatar));
|
// ImageUtils.loadHeadCC(emMessage.getText().getFromUserInfo().getAvatar(), helper.getView(com.xscm.moduleutil.R.id.avatar));
|
||||||
// helper.setText(com.xscm.moduleutil.R.id.tv_name, emMessage.getText().getFromUserInfo().getNickname());
|
helper.setText(com.xscm.moduleutil.R.id.tv_name, emMessage.getText().getFromUserInfo().getNickname());
|
||||||
helper.setTextColor(com.xscm.moduleutil.R.id.tv_name, emMessage.getText().getFromUserInfo().getNickname_color()!=null && !emMessage.getText().getFromUserInfo().getNickname_color().isEmpty()? Color.parseColor(emMessage.getText().getFromUserInfo().getNickname_color()):Color.parseColor("#CCA882"));
|
helper.setTextColor(com.xscm.moduleutil.R.id.tv_name, emMessage.getText().getFromUserInfo().getNickname_color() != null && !emMessage.getText().getFromUserInfo().getNickname_color().isEmpty() ? Color.parseColor(emMessage.getText().getFromUserInfo().getNickname_color()) : Color.parseColor("#CCA882"));
|
||||||
if (emMessage.getText().getText() != null) {
|
if (emMessage.getText().getText() != null) {
|
||||||
helper.setText(com.xscm.moduleutil.R.id.tv_content, getSpannable(emMessage));
|
helper.setText(com.xscm.moduleutil.R.id.tv_content, getSpannable(emMessage));
|
||||||
}
|
}
|
||||||
@@ -268,7 +268,7 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
|||||||
} else {
|
} else {
|
||||||
helper.getView(com.xscm.moduleutil.R.id.bubble).setBackgroundResource(com.xscm.moduleutil.R.drawable.ease_row_pubilc_user_bg);
|
helper.getView(com.xscm.moduleutil.R.id.bubble).setBackgroundResource(com.xscm.moduleutil.R.drawable.ease_row_pubilc_user_bg);
|
||||||
}
|
}
|
||||||
if (emMessage.getText().getEmoji() != null) {
|
if (emMessage.getText().getEmoji() != null && emMessage.getText().getEmoji().getAnimate_image() != null) {
|
||||||
|
|
||||||
|
|
||||||
// 为每个加载任务设置唯一标识
|
// 为每个加载任务设置唯一标识
|
||||||
@@ -284,7 +284,7 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
|||||||
|
|
||||||
// if (Objects.equals(emMessage.getText().getEmoji().getAnimate_image(), "") ||
|
// if (Objects.equals(emMessage.getText().getEmoji().getAnimate_image(), "") ||
|
||||||
// emMessage.getText().getEmoji().getAnimate_image().isEmpty()) {
|
// emMessage.getText().getEmoji().getAnimate_image().isEmpty()) {
|
||||||
if (!animateImage.isEmpty()){
|
if (!animateImage.isEmpty()) {
|
||||||
// 检查视图是否仍属于当前数据项
|
// 检查视图是否仍属于当前数据项
|
||||||
if (uniqueId.equals(emojiImageView.getTag())) {
|
if (uniqueId.equals(emojiImageView.getTag())) {
|
||||||
ImageUtils.loadHeadCC(emMessage.getText().getEmoji().getImage(), emojiImageView);
|
ImageUtils.loadHeadCC(emMessage.getText().getEmoji().getImage(), emojiImageView);
|
||||||
@@ -323,7 +323,7 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
.into(emojiImageView);
|
.into(emojiImageView);
|
||||||
}else {
|
} else {
|
||||||
Glide.with(mContext)
|
Glide.with(mContext)
|
||||||
.load(emMessage.getText().getEmoji().getImage())
|
.load(emMessage.getText().getEmoji().getImage())
|
||||||
.into(emojiImageView);
|
.into(emojiImageView);
|
||||||
|
|||||||
@@ -246,7 +246,6 @@
|
|||||||
android:layout_alignParentEnd="true"
|
android:layout_alignParentEnd="true"
|
||||||
android:layout_alignParentBottom="true"
|
android:layout_alignParentBottom="true"
|
||||||
android:layout_marginEnd="@dimen/dp_20"
|
android:layout_marginEnd="@dimen/dp_20"
|
||||||
android:layout_marginBottom="@dimen/dp_100"
|
|
||||||
android:clickable="true"
|
android:clickable="true"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:scaleType="fitCenter"
|
android:scaleType="fitCenter"
|
||||||
|
|||||||
@@ -1,135 +1,128 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<layout
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
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:tools="http://schemas.android.com/tools"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
android:id="@+id/main"
|
||||||
android:id="@+id/main"
|
tools:context=".activity.NobleDetailsActivity">
|
||||||
tools:context=".activity.NobleDetailsActivity">
|
|
||||||
|
|
||||||
<data>
|
<data>
|
||||||
|
|
||||||
</data>
|
</data>
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="@mipmap/noble_details_bj"
|
android:background="@mipmap/noble_details_bj">
|
||||||
>
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/top_bar"
|
android:id="@+id/top_bar"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="45dp"
|
android:layout_height="45dp"
|
||||||
android:layout_marginTop="@dimen/dp_40"
|
android:layout_marginTop="@dimen/dp_40"
|
||||||
app:layout_constraintTop_toTopOf="parent">
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/iv_back"
|
android:id="@+id/iv_back"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
android:contentDescription="@null"
|
android:contentDescription="@null"
|
||||||
android:scaleType="centerInside"
|
android:scaleType="centerInside"
|
||||||
android:src="@mipmap/ic_topbar_back_dark"
|
android:src="@mipmap/ic_topbar_back_dark"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintDimensionRatio="1:1"
|
app:layout_constraintDimensionRatio="1:1"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
/>
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/tv_title"
|
android:id="@+id/tv_title"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:src="@mipmap/icon_noble_title"
|
android:src="@mipmap/icon_noble_title"
|
||||||
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_toTopOf="parent" />
|
||||||
/>
|
|
||||||
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/iv_intent"
|
android:id="@+id/iv_intent"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
android:layout_marginEnd="@dimen/dp_16"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
android:src="@mipmap/icon_noble_gz"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
android:src="@mipmap/icon_noble_gz"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
android:layout_marginEnd="@dimen/dp_16"
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
/>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_noble_lv"
|
android:id="@+id/tv_noble_lv"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="@dimen/dp_44"
|
android:layout_height="@dimen/dp_44"
|
||||||
tools:text="骑士"
|
android:layout_marginTop="@dimen/dp_8"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/top_bar"
|
android:textSize="@dimen/dp_34"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
android:layout_marginTop="@dimen/dp_8"
|
app:layout_constraintTop_toBottomOf="@+id/top_bar"
|
||||||
android:textSize="@dimen/dp_34"/>
|
tools:text="骑士" />
|
||||||
|
|
||||||
|
|
||||||
<com.zhpan.bannerview.BannerViewPager
|
<com.zhpan.bannerview.BannerViewPager
|
||||||
android:id="@+id/banner"
|
android:id="@+id/banner"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="@dimen/dp_200"
|
android:layout_height="@dimen/dp_200"
|
||||||
app:layout_constraintTop_toBottomOf="@id/tv_noble_lv"
|
android:layout_marginTop="@dimen/dp_8"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
android:layout_marginTop="@dimen/dp_8"
|
app:layout_constraintTop_toBottomOf="@id/tv_noble_lv" />
|
||||||
/>
|
|
||||||
|
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/im_noble_tq"
|
android:id="@+id/im_noble_tq"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/banner"
|
android:scaleType="fitXY"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
android:src="@mipmap/noble_details_tq"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
android:src="@mipmap/noble_details_tq"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
android:scaleType="fitXY"
|
app:layout_constraintTop_toBottomOf="@+id/banner" />
|
||||||
/>
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_tq"
|
android:id="@+id/tv_tq"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textSize="@dimen/sp_16"
|
android:textColor="#FFEDBD"
|
||||||
tools:text="专属特权"
|
android:textSize="@dimen/sp_16"
|
||||||
android:textColor="#FFEDBD"
|
app:layout_constraintBottom_toBottomOf="@+id/im_noble_tq"
|
||||||
app:layout_constraintStart_toStartOf="@+id/im_noble_tq"
|
app:layout_constraintEnd_toEndOf="@+id/im_noble_tq"
|
||||||
app:layout_constraintEnd_toEndOf="@+id/im_noble_tq"
|
app:layout_constraintStart_toStartOf="@+id/im_noble_tq"
|
||||||
app:layout_constraintTop_toTopOf="@+id/im_noble_tq"
|
app:layout_constraintTop_toTopOf="@+id/im_noble_tq"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/im_noble_tq"/>
|
tools:text="专属特权" />
|
||||||
|
|
||||||
<ScrollView
|
<ScrollView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tv_tq"
|
android:layout_marginTop="@dimen/dp_8"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
android:paddingTop="@dimen/dp_8"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintBottom_toTopOf="@+id/im_kt"
|
||||||
android:layout_marginTop="@dimen/dp_8"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
android:paddingTop="@dimen/dp_8"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintBottom_toTopOf="@+id/im_kt">
|
app:layout_constraintTop_toBottomOf="@+id/tv_tq">
|
||||||
|
|
||||||
<com.xscm.moduleutil.widget.MyGridView
|
<com.xscm.moduleutil.widget.MyGridView
|
||||||
android:id="@+id/gridView"
|
android:id="@+id/gridView"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
tools:listitem="@layout/item_noble_tq"
|
android:clipToPadding="false"
|
||||||
android:horizontalSpacing="8dp"
|
android:numColumns="3"
|
||||||
android:verticalSpacing="8dp"
|
android:horizontalSpacing="@dimen/dp_8"
|
||||||
android:paddingStart="@dimen/dp_15"
|
android:paddingStart="@dimen/dp_14"
|
||||||
android:paddingEnd="@dimen/dp_15"
|
android:paddingEnd="@dimen/dp_15"
|
||||||
android:paddingBottom="@dimen/dp_8"
|
android:paddingBottom="@dimen/dp_8"
|
||||||
android:clipToPadding="false"
|
android:verticalSpacing="4.5dp"
|
||||||
android:numColumns="3"/>
|
tools:listitem="@layout/item_noble_tq" />
|
||||||
|
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
|
|
||||||
@@ -155,49 +148,47 @@
|
|||||||
<!-- />-->
|
<!-- />-->
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/im_kt"
|
android:id="@+id/im_kt"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
android:scaleType="fitXY"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
android:src="@mipmap/noble_kt"
|
||||||
android:src="@mipmap/noble_kt"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
android:scaleType="fitXY"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintStart_toStartOf="parent" />
|
||||||
/>
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_lv_tis"
|
android:id="@+id/tv_lv_tis"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textSize="@dimen/sp_16"
|
android:layout_marginStart="@dimen/dp_16"
|
||||||
tools:text="骑士开通"
|
android:textColor="#F7EAC9"
|
||||||
android:textColor="#F7EAC9"
|
android:textSize="@dimen/sp_16"
|
||||||
android:layout_marginStart="@dimen/dp_16"
|
app:layout_constraintBottom_toBottomOf="@+id/im_kt"
|
||||||
app:layout_constraintStart_toStartOf="@+id/im_kt"
|
app:layout_constraintStart_toStartOf="@+id/im_kt"
|
||||||
app:layout_constraintTop_toTopOf="@+id/im_kt"
|
app:layout_constraintTop_toTopOf="@+id/im_kt"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/im_kt"/>
|
tools:text="骑士开通" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_noble_mob"
|
android:id="@+id/tv_noble_mob"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textSize="@dimen/sp_16"
|
android:textColor="#F7EAC9"
|
||||||
tools:text="¥30/月"
|
android:textSize="@dimen/sp_16"
|
||||||
android:textColor="#F7EAC9"
|
app:layout_constraintBottom_toBottomOf="@+id/tv_lv_tis"
|
||||||
app:layout_constraintStart_toEndOf="@+id/tv_lv_tis"
|
app:layout_constraintStart_toEndOf="@+id/tv_lv_tis"
|
||||||
app:layout_constraintTop_toTopOf="@+id/tv_lv_tis"
|
app:layout_constraintTop_toTopOf="@+id/tv_lv_tis"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/tv_lv_tis"/>
|
tools:text="¥30/月" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/im_ljkt"
|
android:id="@+id/im_ljkt"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:src="@mipmap/noble_ljkt"
|
android:layout_marginEnd="@dimen/dp_16"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
android:src="@mipmap/noble_ljkt"
|
||||||
app:layout_constraintTop_toTopOf="@+id/im_kt"
|
app:layout_constraintBottom_toBottomOf="@+id/im_kt"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/im_kt"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
android:layout_marginEnd="@dimen/dp_16"
|
app:layout_constraintTop_toTopOf="@+id/im_kt" />
|
||||||
/>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
</layout>
|
</layout>
|
||||||
@@ -83,8 +83,7 @@
|
|||||||
android:layout_marginLeft="@dimen/dp_5"
|
android:layout_marginLeft="@dimen/dp_5"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
app:riv_oval="true"
|
app:riv_oval="true"/>
|
||||||
/>
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tv_nick_name"
|
android:id="@+id/tv_nick_name"
|
||||||
|
|||||||
Reference in New Issue
Block a user