fix bugs. add 字体流光 自定义view,cos上传报错信息。
This commit is contained in:
@@ -224,5 +224,6 @@ dependencies {
|
||||
|
||||
api project(':Loadinglibrary')
|
||||
api project(':moduletablayout')
|
||||
implementation "org.jetbrains.kotlin:kotlin-reflect:2.0.21"
|
||||
}
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ import static android.view.View.GONE;
|
||||
import static android.view.View.VISIBLE;
|
||||
import static com.blankj.utilcode.util.ActivityUtils.startActivity;
|
||||
|
||||
import android.graphics.Color;
|
||||
import android.os.Bundle;
|
||||
import android.text.SpannableStringBuilder;
|
||||
import android.text.Spanned;
|
||||
@@ -30,6 +31,7 @@ import com.xscm.moduleutil.utils.MeHeadView;
|
||||
import com.xscm.moduleutil.utils.NumberFormatUtils;
|
||||
import com.xscm.moduleutil.utils.SpUtil;
|
||||
import com.xscm.moduleutil.widget.MyGridView;
|
||||
import com.xscm.moduleutil.widget.ShineTextView;
|
||||
import com.xscm.moduleutil.widget.img.FullScreenUtil;
|
||||
|
||||
import java.util.List;
|
||||
@@ -46,13 +48,13 @@ public class CirleListAdapter extends BaseQuickAdapter<CircleListBean, BaseViewH
|
||||
}
|
||||
|
||||
public interface OnItemClickListener {
|
||||
void onDianzanClick(int index,CircleListBean item);
|
||||
void onDianzanClick(int index, CircleListBean item);
|
||||
|
||||
void onHeadImageClick(CircleListBean item);
|
||||
|
||||
void onZsClick(int idx,CircleListBean item);
|
||||
void onZsClick(int idx, CircleListBean item);
|
||||
|
||||
void onMoreClick(int idx,CircleListBean item);
|
||||
void onMoreClick(int idx, CircleListBean item);
|
||||
|
||||
void onPinglunClick(CircleListBean item);
|
||||
|
||||
@@ -86,7 +88,7 @@ public class CirleListAdapter extends BaseQuickAdapter<CircleListBean, BaseViewH
|
||||
Bundle diff = (Bundle) payload;
|
||||
if (diff.containsKey("like_num")) {
|
||||
helper.setText(R.id.dy_fabulous, diff.getString("like_num"));
|
||||
if (diff.containsKey("is_like")){
|
||||
if (diff.containsKey("is_like")) {
|
||||
if (diff.getInt("is_like") == 1) {
|
||||
helper.setImageResource(R.id.dianzan_image, R.mipmap.dongtai_hudong_yidianzan);
|
||||
} else {
|
||||
@@ -130,7 +132,7 @@ public class CirleListAdapter extends BaseQuickAdapter<CircleListBean, BaseViewH
|
||||
// 设置点击回调
|
||||
helper.getView(com.xscm.moduleutil.R.id.dianzan).setOnClickListener(v -> {
|
||||
if (mListener != null) {
|
||||
mListener.onDianzanClick(helper.getPosition(),item);
|
||||
mListener.onDianzanClick(helper.getPosition(), item);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -139,11 +141,11 @@ public class CirleListAdapter extends BaseQuickAdapter<CircleListBean, BaseViewH
|
||||
});
|
||||
|
||||
helper.getView(com.xscm.moduleutil.R.id.zs).setOnClickListener(v -> {
|
||||
if (mListener != null) mListener.onZsClick(helper.getPosition(),item);
|
||||
if (mListener != null) mListener.onZsClick(helper.getPosition(), item);
|
||||
});
|
||||
|
||||
helper.getView(R.id.diandian).setOnClickListener(v -> {
|
||||
if (mListener != null) mListener.onMoreClick(helper.getPosition(),item);
|
||||
if (mListener != null) mListener.onMoreClick(helper.getPosition(), item);
|
||||
});
|
||||
|
||||
helper.getView(R.id.pinglun).setOnClickListener(v -> {
|
||||
@@ -164,6 +166,15 @@ public class CirleListAdapter extends BaseQuickAdapter<CircleListBean, BaseViewH
|
||||
});
|
||||
//昵称
|
||||
helper.setText(R.id.dy_name_text, item.getNickname());
|
||||
ShineTextView tvName = helper.getView(R.id.dy_name_text);
|
||||
if (!item.getNickname_color().isEmpty()) {
|
||||
tvName.setStartColor(Color.parseColor(item.getNickname_color()));
|
||||
tvName.setShineColor(Color.parseColor(item.getNickname_color()));
|
||||
tvName.setEndColor(Color.parseColor(item.getNickname_color()));
|
||||
tvName.setShine(true);
|
||||
tvName.setShineType(0);
|
||||
}
|
||||
|
||||
|
||||
//头像
|
||||
// ImageUtils.loadHeadCC(item.getAvatar(), helper.getView(R.id.dy_head_image));
|
||||
|
||||
@@ -132,7 +132,7 @@ public class BaseRoomPresenter<V extends IView> extends BasePresenter<V> impleme
|
||||
|
||||
@Override
|
||||
public void putOnWheat(String roomId, String userId,String pitNum) {
|
||||
MvpRef.get().showLoadings();
|
||||
// MvpRef.get().showLoadings();
|
||||
// ApiClient.getInstance().putOnWheat(roomId, userId,pitNum, new BaseObserver<PutOnWheatResp>() {
|
||||
// @Override
|
||||
// public void onSubscribe(Disposable d) {
|
||||
|
||||
@@ -446,8 +446,8 @@ public class CommonAppContext extends MultiDexApplication implements Applicatio
|
||||
// startService(mqttServiceIntent);
|
||||
// }
|
||||
|
||||
// mqttConnect=MqttConnect.getInstance(this,"tcp://1.13.181.248","android-"+ MqttClient.generateClientId());
|
||||
mqttConnect=MqttConnect.getInstance(this,"tcp://1.13.101.98","android-"+ MqttClient.generateClientId());
|
||||
mqttConnect=MqttConnect.getInstance(this,"tcp://1.13.181.248","android-"+ MqttClient.generateClientId());
|
||||
// mqttConnect=MqttConnect.getInstance(this,"tcp://1.13.101.98","android-"+ MqttClient.generateClientId());
|
||||
mqttConnect.mqttClient();
|
||||
|
||||
// 每次启动应用时重置状态
|
||||
@@ -526,8 +526,8 @@ public class CommonAppContext extends MultiDexApplication implements Applicatio
|
||||
|
||||
public void upMqtt(){
|
||||
if (mqttConnect==null){
|
||||
// mqttConnect=MqttConnect.getInstance(this,"tcp://1.13.181.248","android-"+ MqttClient.generateClientId());
|
||||
mqttConnect=MqttConnect.getInstance(this,"tcp://1.13.101.98","android-"+ MqttClient.generateClientId());
|
||||
mqttConnect=MqttConnect.getInstance(this,"tcp://1.13.181.248","android-"+ MqttClient.generateClientId());
|
||||
// mqttConnect=MqttConnect.getInstance(this,"tcp://1.13.101.98","android-"+ MqttClient.generateClientId());
|
||||
mqttConnect.mqttClient();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ public class CircleListBean {
|
||||
public List<HeatedBean> title;//话题列表
|
||||
|
||||
public String nobility_image;//贵族图标
|
||||
public String nickname_color;//昵称颜色
|
||||
public String nickname_color = "";//昵称颜色
|
||||
public String mic_cycle;//麦圈
|
||||
|
||||
public String read_num;//阅读数
|
||||
|
||||
@@ -21,5 +21,5 @@ public class ExpandColumnBean {
|
||||
private String agree;
|
||||
private List<String> icon;
|
||||
private String nobility_image;//贵族图标
|
||||
private String nickname_color;//昵称颜色
|
||||
private String nickname_color = "";//昵称颜色
|
||||
}
|
||||
|
||||
@@ -23,7 +23,7 @@ public class RoonGiftModel {
|
||||
private String all_room_push;
|
||||
private String special;
|
||||
private String sort;
|
||||
private String type;
|
||||
private String type = "";
|
||||
private String child_type;
|
||||
private String sold;
|
||||
private String cardiac;
|
||||
|
||||
@@ -1,19 +1,23 @@
|
||||
package com.xscm.moduleutil.bean;
|
||||
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
import com.xscm.moduleutil.BaseEvent;
|
||||
import com.xscm.moduleutil.bean.room.FriendInfo;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
/**
|
||||
*@author qx
|
||||
*@data 2025/6/3
|
||||
*@description: 个人信息,点击我的获取
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
public class UserInfo implements Serializable {
|
||||
public class UserInfo extends BaseEvent implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
public static final String FEMALE = "2";
|
||||
public static final String MALE = "1";
|
||||
@@ -69,7 +73,7 @@ public class UserInfo implements Serializable {
|
||||
private String ta;
|
||||
|
||||
private String nobility_image;//贵族图标
|
||||
private String nickname_color;//昵称颜色
|
||||
private String nickname_color = "";//昵称颜色
|
||||
private String mic_cycle;//麦圈
|
||||
private String is_hide;//0不能设置,1:可以设置
|
||||
private String hide_status;//0-取消隐身,1-设置隐身
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
package com.xscm.moduleutil.bean.room;
|
||||
|
||||
import com.xscm.moduleutil.BaseEvent;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.util.List;
|
||||
/**
|
||||
@@ -8,13 +11,15 @@ import java.util.List;
|
||||
*@data 2025/9/29
|
||||
*@description:小时榜实体类
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
public class RoomHourBean {
|
||||
public class RoomHourBean extends BaseEvent {
|
||||
private String time_range;
|
||||
private List<RoomListBean> lists;
|
||||
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
public class RoomListBean {
|
||||
public class RoomListBean extends BaseEvent{
|
||||
private String room_id;
|
||||
private String room_name;
|
||||
private int label_id;
|
||||
|
||||
@@ -29,7 +29,7 @@ public class RoomPitBean implements Serializable {
|
||||
*/
|
||||
|
||||
private String id;//id
|
||||
private String pit_number;//麦位号
|
||||
private String pit_number = "";//麦位号
|
||||
private String state;//麦位状态 正常 ,1封麦;3禁麦
|
||||
private int is_lock;//0未锁麦 1锁麦
|
||||
private int is_mute;//0未禁麦 1禁麦
|
||||
|
||||
@@ -766,6 +766,9 @@ public interface ApiServer {
|
||||
@GET(Constants.GET_NOBILITY_PRICE)
|
||||
Call<BaseModel<NobilityPrice>> getNobilityPrice(@Query("id") String id);
|
||||
|
||||
@POST(Constants.POST_SEND_LOG)
|
||||
Call<BaseModel<String>> postSendAppLog(@Query("log_name") String logName,@Query("log_url") String logUrl);
|
||||
|
||||
@GET(Constants.GET_BOX_GIFT_LIST_XLH)
|
||||
Call<BaseModel<BlindBoxBean>> getBoxGiftListXLH( @Query("room_id") String room_id);
|
||||
|
||||
|
||||
@@ -3814,6 +3814,35 @@ public class RetrofitClient {
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
public void sendAppLog(String logName,String logPath,BaseObserver<String> observer) {
|
||||
sApiServer.postSendAppLog(logName,logPath).enqueue(new Callback<BaseModel<String>>() {
|
||||
@Override
|
||||
public void onResponse(Call<BaseModel<String>> call, Response<BaseModel<String>> response) {
|
||||
if (response.code() == 200) {
|
||||
int code = response.body().getCode();
|
||||
if (code == 1) {
|
||||
observer.onNext("成功");
|
||||
}else if (code == 301){
|
||||
try {
|
||||
ToastUtils.showShort(response.body().getMsg());
|
||||
CommonAppContext.getInstance().clearLoginInfo();
|
||||
} catch (ClassNotFoundException e) {
|
||||
LogUtils.e( e.toString());
|
||||
}
|
||||
}else {
|
||||
observer.onNext("失败");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFailure(Call<BaseModel<String>> call, Throwable t) {
|
||||
observer.onNext("失败");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/// 巡乐会抽奖
|
||||
public void xlhChou(String roomId, String
|
||||
num, BaseObserver<List<XlhDrawBean>> observer) {
|
||||
|
||||
@@ -217,7 +217,7 @@ public class MessageListenerSingleton {
|
||||
try {
|
||||
// 先退出当前群组(如果需要)
|
||||
if (groupId != null && !groupId.equals(roomId)) {
|
||||
LogUtils.d("MessageListener", "开始退出群组: " + groupId);
|
||||
LogUtils.d("MessageListener", "开始退出群组: " + groupId +"____room:"+ roomId);
|
||||
CountDownLatch quitLatch = new CountDownLatch(1);
|
||||
boolean[] quitSuccess = {false};
|
||||
|
||||
@@ -225,14 +225,14 @@ public class MessageListenerSingleton {
|
||||
V2TIMManager.getInstance().quitGroup("room" + groupId, new V2TIMCallback() {
|
||||
@Override
|
||||
public void onSuccess() {
|
||||
LogUtils.d("MessageListener", "退出群组成功: " + groupId);
|
||||
LogUtils.d("MessageListener", "退出群组成功: " + groupId+"____room:"+ roomId);
|
||||
quitSuccess[0] = true;
|
||||
quitLatch.countDown();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(int code, String desc) {
|
||||
LogUtils.e("MessageListener", "退出群组失败: " + groupId + ", code=" + code + ", desc=" + desc);
|
||||
LogUtils.e("MessageListener", "退出群组失败: " + groupId +"____room:"+ roomId + ", code=" + code + ", desc=" + desc);
|
||||
quitSuccess[0] = false;
|
||||
quitLatch.countDown();
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ import io.reactivex.disposables.Disposable;
|
||||
public abstract class BasePresenter<V extends IView> implements IPresenter {
|
||||
protected CompositeDisposable mDisposables = new CompositeDisposable();
|
||||
protected RetrofitClient api = RetrofitClient.getInstance();
|
||||
protected Reference<V> MvpRef;
|
||||
protected Reference<V> MvpRef;
|
||||
protected Context mContext;
|
||||
|
||||
@Deprecated
|
||||
|
||||
@@ -863,7 +863,7 @@ public class AgoraManager {
|
||||
//打开对方支持的推流
|
||||
public void muteAllRemoteAudioStreamsExUserId(boolean enabled){
|
||||
if (rtcEngine != null){
|
||||
// rtcEngine.muteRemoteAudioStreamEx(pkUserId,enabled,connection);
|
||||
rtcEngine.muteRemoteAudioStreamEx(pkUserId,enabled,connection);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,19 +1,35 @@
|
||||
package com.xscm.moduleutil.utils;
|
||||
|
||||
import android.os.SystemClock;
|
||||
import android.util.SparseArray;
|
||||
import android.view.View;
|
||||
|
||||
/**
|
||||
*@author qx
|
||||
*@data 2025/9/10
|
||||
*@description: 防止重复点击的工具类
|
||||
*/
|
||||
public class ClickUtils {
|
||||
private static final long CLICK_INTERVAL = 1000; // 1000ms内不允许重复点击
|
||||
private static long lastClickTime = 0;
|
||||
private static final long DEFAULT_CLICK_INTERVAL = 500;
|
||||
private static final SparseArray<Long> lastClickTimes = new SparseArray<>();
|
||||
|
||||
public static boolean isFastDoubleClick() {
|
||||
long currentTime = System.currentTimeMillis();
|
||||
if (currentTime - lastClickTime < CLICK_INTERVAL) {
|
||||
public static boolean isFastDoubleClick(View view) {
|
||||
return isFastDoubleClick(view, DEFAULT_CLICK_INTERVAL);
|
||||
}
|
||||
|
||||
public static boolean isFastDoubleClick(View view, long interval) {
|
||||
long currentTime = SystemClock.elapsedRealtime();
|
||||
int viewId = view.getId();
|
||||
Long lastClickTime = lastClickTimes.get(viewId);
|
||||
if (lastClickTime != null && currentTime - lastClickTime < interval) {
|
||||
return true;
|
||||
}
|
||||
lastClickTime = currentTime;
|
||||
lastClickTimes.put(viewId, currentTime);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// 新增:清理所有点击记录
|
||||
public static void clearAllClickRecords() {
|
||||
lastClickTimes.clear();
|
||||
}
|
||||
}
|
||||
@@ -196,7 +196,19 @@ public class ImageUtils {
|
||||
}
|
||||
|
||||
|
||||
|
||||
public static void loadRoomItem(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).diskCacheStrategy(DiskCacheStrategy.ALL).into(mImageView);
|
||||
}
|
||||
|
||||
public static void loadHeadCC(String path, ImageView mImageView) {
|
||||
if (mImageView == null) {
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.widget.ImageView;
|
||||
|
||||
import androidx.constraintlayout.widget.ConstraintLayout;
|
||||
|
||||
import com.blankj.utilcode.util.LogUtils;
|
||||
import com.xscm.moduleutil.R;
|
||||
import com.xscm.moduleutil.utils.logger.Logger;
|
||||
import com.xscm.moduleutil.widget.AvatarFrameView;
|
||||
@@ -47,7 +48,7 @@ public class MeHeadView extends ConstraintLayout {
|
||||
}
|
||||
|
||||
public void setData(String headPicture, String framePicture, String nobilityImage) {
|
||||
Logger.e(headPicture, framePicture, nobilityImage);
|
||||
LogUtils.e(headPicture, framePicture, nobilityImage);
|
||||
if (!TextUtils.isEmpty(headPicture)) {
|
||||
ImageUtils.loadHead(headPicture, mRiv);
|
||||
}
|
||||
|
||||
@@ -207,7 +207,7 @@ public class TimeUtils {
|
||||
//获取当前日期
|
||||
public static String getCurrentDate2() {
|
||||
Date d = new Date();
|
||||
SimpleDateFormat sf = new SimpleDateFormat("yyyy-MM-dd hh:mm:ss SSS");
|
||||
SimpleDateFormat sf = new SimpleDateFormat("yyyy_MM_dd_hh_mm_ss_SSS");
|
||||
return sf.format(d);
|
||||
}
|
||||
/**
|
||||
|
||||
@@ -80,7 +80,7 @@ public class CosUploadManager {
|
||||
String tmpSecretKey = tempKeyBean.getCredentials().getTmpSecretKey(); // 临时密钥 SecretKey
|
||||
String sessionToken = tempKeyBean.getCredentials().getSessionToken(); // 临时密钥 Token
|
||||
long expiredTime = tempKeyBean.getExpiredTime();//临时密钥有效截止时间戳,单位是秒
|
||||
// 建议返回服务器时间作为签名的开始时间,避免由于用户手机本地时间偏差过大导致请求过期
|
||||
// 建议返回服务器时间作为签名的开始时间,避免由于用户手机本地时间偏差过大导致请求过期
|
||||
long startTime = tempKeyBean.getStartTime(); //临时密钥有效起始时间,单位是秒
|
||||
// 存储桶所在地域简称,例如广州地区是 ap-guangzhou
|
||||
String region = tempKeyBean.getRegion();
|
||||
@@ -95,13 +95,13 @@ public class CosUploadManager {
|
||||
CosXmlService cosXmlService = new CosXmlService(mContext, serviceConfig);
|
||||
|
||||
// 任何 CosXmlRequest 都支持这种方式,例如上传 PutObjectRequest、下载 GetObjectRequest、删除 DeleteObjectRequest 等
|
||||
// 以下用上传进行示例
|
||||
// 以下用上传进行示例
|
||||
PutObjectRequest putRequest = new PutObjectRequest(bucketName, objectKey, localFilePath);
|
||||
// sessionQCloudCredentials 为第一步“初始化密钥”中获取到的单次临时密钥
|
||||
// sessionQCloudCredentials 为第一步“初始化密钥”中获取到的单次临时密钥
|
||||
putRequest.setCredential(sessionQCloudCredentials);
|
||||
// 初始化 TransferConfig,这里使用默认配置,如果需要定制,请参考 SDK 接口文档
|
||||
// 初始化 TransferConfig,这里使用默认配置,如果需要定制,请参考 SDK 接口文档
|
||||
TransferConfig transferConfig = new TransferConfig.Builder().build();
|
||||
// 初始化 TransferManager
|
||||
// 初始化 TransferManager
|
||||
TransferManager transferManager = new TransferManager(cosXmlService, transferConfig);
|
||||
COSXMLUploadTask uploadTask = transferManager.upload(putRequest, null);
|
||||
uploadTask.setCosXmlResultListener(new CosXmlResultListener() {
|
||||
|
||||
@@ -63,7 +63,7 @@ public final class DataLogger implements DataLoggingInterceptor.Logger {
|
||||
}
|
||||
// 响应结束,打印整条日志
|
||||
if (message.startsWith(DataLoggingInterceptor.sLogEndFlag)) {
|
||||
if (mMessage.toString().contains("https://test.vespa.xscmmidi.site/api/Xintiao/keep_xintiao"))
|
||||
if (mMessage.toString().contains("Xintiao/keep_xintiao"))
|
||||
return;
|
||||
LogUtils.d(mMessage.toString());
|
||||
return;
|
||||
|
||||
@@ -17,6 +17,7 @@ import com.blankj.utilcode.util.FileUtils;
|
||||
import com.blankj.utilcode.util.ThreadUtils;
|
||||
import com.xscm.moduleutil.base.CommonAppContext;
|
||||
import com.xscm.moduleutil.utils.Md5Utils;
|
||||
import com.xscm.moduleutil.utils.TimeUtils;
|
||||
import com.xscm.moduleutil.utils.logger.Logger;
|
||||
|
||||
import java.io.File;
|
||||
@@ -53,6 +54,7 @@ public class OSSOperUtils {
|
||||
public static final String img = "images/android_images/";
|
||||
public static final String video = "video/";
|
||||
public static final String audio = "audio/";
|
||||
public static final String AppLog = "applog/";
|
||||
|
||||
|
||||
/**
|
||||
@@ -77,6 +79,15 @@ public class OSSOperUtils {
|
||||
// }
|
||||
}
|
||||
|
||||
public static String getAppLogPath(File file) {
|
||||
String fileMD5 = Md5Utils.getFileMD5(file);
|
||||
String suffix = "";
|
||||
if (file.getName().contains(".")) {
|
||||
suffix = file.getName().substring(file.getName().lastIndexOf("."));
|
||||
}
|
||||
return AppLog + fileMD5 + TimeUtils.getCurrentDate2() + suffix;
|
||||
}
|
||||
|
||||
public static OSSOperUtils newInstance() {
|
||||
if (null == utils) {
|
||||
utils = new OSSOperUtils();
|
||||
|
||||
@@ -411,6 +411,7 @@ public class Constants {
|
||||
public static final String GET_NOBILITY_DETAIL = "/api/Nobility/get_nobility_detail";//爵位详情
|
||||
public static final String GET_NOBILITY_LIST = "/api/Nobility/get_nobility_list";//爵位列表
|
||||
public static final String GET_NOBILITY_PRICE = "/api/Nobility/get_nobility_price";//爵位购买价格
|
||||
public static final String POST_SEND_LOG = "api/Report/android_log_report";//上传log信息
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,125 @@
|
||||
package com.xscm.moduleutil.widget
|
||||
|
||||
|
||||
import android.content.Context
|
||||
import android.graphics.Canvas
|
||||
import android.graphics.Color
|
||||
import android.graphics.LinearGradient
|
||||
import android.graphics.Matrix
|
||||
import android.graphics.Shader
|
||||
import android.util.AttributeSet
|
||||
import androidx.appcompat.widget.AppCompatTextView
|
||||
import com.xscm.moduleutil.R
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
* 流光字体
|
||||
* @author TXZ
|
||||
* @version 1.0
|
||||
* created by 2024/5/23 9:32
|
||||
*/
|
||||
class ShineTextView : AppCompatTextView {
|
||||
|
||||
//是否开启流光,默认开启
|
||||
var isShine = true
|
||||
|
||||
//默认是流光效果 0 流光 1 注入效果
|
||||
var shineType = 0
|
||||
//流光效果下字体流动次数
|
||||
var shineCount: Int = Int.MAX_VALUE
|
||||
//注入效果 开始,中间,结束
|
||||
var startColor: Int = Color.WHITE
|
||||
var shineColor: Int = Color.WHITE
|
||||
var endColor: Int = Color.WHITE
|
||||
//一次动效时长
|
||||
var shineDuration: Int = 400
|
||||
|
||||
var _count: Int = 0 //自行运行动画次数
|
||||
|
||||
private lateinit var mLinearGradient: LinearGradient
|
||||
private var mGradientMatrix: Matrix = Matrix()
|
||||
private var mViewWidth = 0
|
||||
private var mTranslate = 0
|
||||
|
||||
constructor(context: Context) : this(context, null)
|
||||
constructor(context: Context, attrs: AttributeSet?) : this(context, attrs, 0)
|
||||
constructor(context: Context, attrs: AttributeSet?, defStyleAttr: Int) : super(
|
||||
context, attrs, defStyleAttr
|
||||
) {
|
||||
obtainAttributes(attrs!!)
|
||||
}
|
||||
|
||||
|
||||
private fun obtainAttributes(attrs: AttributeSet) {
|
||||
val typedArray = context.obtainStyledAttributes(attrs, R.styleable.ShineTextView)
|
||||
typedArray.apply {
|
||||
isShine = typedArray.getBoolean(R.styleable.ShineTextView_isShine, isShine)
|
||||
shineType = typedArray.getInt(R.styleable.ShineTextView_shineType, shineType)
|
||||
startColor = typedArray.getColor(R.styleable.ShineTextView_startColor, startColor)
|
||||
shineColor = typedArray.getColor(R.styleable.ShineTextView_midColor, shineColor)
|
||||
endColor = typedArray.getColor(R.styleable.ShineTextView_endColor, endColor)
|
||||
shineCount = typedArray.getInt(R.styleable.ShineTextView_shineCount, shineCount)
|
||||
shineDuration =
|
||||
typedArray.getInt(R.styleable.ShineTextView_shineDuration, shineDuration)
|
||||
}
|
||||
typedArray.recycle()
|
||||
}
|
||||
|
||||
|
||||
override fun onSizeChanged(w: Int, h: Int, oldw: Int, oldh: Int) {
|
||||
super.onSizeChanged(w, h, oldw, oldh)
|
||||
if (isShine) {
|
||||
mViewWidth = measuredWidth
|
||||
when (shineType) {
|
||||
0 -> {
|
||||
//流光效果
|
||||
mLinearGradient = LinearGradient(
|
||||
0f,
|
||||
0f,
|
||||
(mViewWidth / 4).toFloat(),
|
||||
0f,
|
||||
intArrayOf(currentTextColor, shineColor, currentTextColor),
|
||||
null,
|
||||
Shader.TileMode.CLAMP
|
||||
)
|
||||
}
|
||||
|
||||
1 -> {
|
||||
mLinearGradient = LinearGradient(
|
||||
0f,
|
||||
0f,
|
||||
(mViewWidth / 6).toFloat(),
|
||||
0f,
|
||||
intArrayOf(endColor, shineColor, startColor),
|
||||
null,
|
||||
Shader.TileMode.CLAMP
|
||||
)
|
||||
}
|
||||
}
|
||||
paint.shader = mLinearGradient
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
override fun onDraw(canvas: Canvas) {
|
||||
super.onDraw(canvas)
|
||||
if (!isShine || !::mLinearGradient.isLateinit) return
|
||||
mTranslate += mViewWidth / (shineDuration / 50)
|
||||
if (mTranslate > 1.2 * mViewWidth) {
|
||||
mTranslate = -mViewWidth / 5
|
||||
_count++
|
||||
}
|
||||
mGradientMatrix.setTranslate(mTranslate.toFloat(), 0f)
|
||||
mLinearGradient.setLocalMatrix(mGradientMatrix)
|
||||
when {
|
||||
shineType == 0 && _count < shineCount -> postInvalidateDelayed(50)
|
||||
shineType == 1 && _count < 1 -> postInvalidateDelayed(50)
|
||||
else -> {
|
||||
mGradientMatrix.setTranslate((1.2 * mViewWidth).toFloat(), 0f)
|
||||
mLinearGradient.setLocalMatrix(mGradientMatrix)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,16 +1,14 @@
|
||||
<?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:id="@+id/bubble"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:minWidth="@dimen/dp_256"
|
||||
android:maxWidth="@dimen/dp_256"
|
||||
android:padding="@dimen/dp_8"
|
||||
android:background="@drawable/ease_row_pubilc_user_bg"
|
||||
>
|
||||
<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:id="@+id/bubble"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/ease_row_pubilc_user_bg"
|
||||
android:maxWidth="@dimen/dp_256"
|
||||
android:minWidth="@dimen/dp_256"
|
||||
android:padding="@dimen/dp_8">
|
||||
|
||||
<!-- 网络背景图片 -->
|
||||
<!-- <ImageView-->
|
||||
@@ -25,104 +23,105 @@
|
||||
|
||||
<!-- 用户头像 -->
|
||||
<com.xscm.moduleutil.utils.MeHeadView
|
||||
android:id="@+id/avatar"
|
||||
android:layout_width="@dimen/dp_28"
|
||||
android:layout_height="@dimen/dp_28"
|
||||
android:layout_marginEnd="@dimen/dp_3"
|
||||
android:layout_marginTop="@dimen/dp_3"
|
||||
android:layout_marginBottom="@dimen/dp_3"
|
||||
android:layout_marginStart="@dimen/dp_8"
|
||||
app:riv_oval="true"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"/>
|
||||
android:id="@+id/avatar"
|
||||
android:layout_width="@dimen/dp_28"
|
||||
android:layout_height="@dimen/dp_28"
|
||||
android:layout_marginStart="@dimen/dp_8"
|
||||
android:layout_marginTop="@dimen/dp_3"
|
||||
android:layout_marginEnd="@dimen/dp_3"
|
||||
android:layout_marginBottom="@dimen/dp_3"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:riv_oval="true" />
|
||||
|
||||
<!-- 用户名称 -->
|
||||
<TextView
|
||||
android:id="@+id/tv_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="#CCA882"
|
||||
android:textSize="@dimen/sp_12"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
tools:text="饶利"
|
||||
app:layout_constraintStart_toEndOf="@+id/avatar"
|
||||
app:layout_constraintTop_toTopOf="@+id/avatar"/>
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
android:id="@+id/tv_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
android:textColor="#CCA882"
|
||||
android:textSize="@dimen/sp_12"
|
||||
app:isShine="false"
|
||||
app:layout_constraintStart_toEndOf="@+id/avatar"
|
||||
app:layout_constraintTop_toTopOf="@+id/avatar"
|
||||
tools:text="饶利" />
|
||||
|
||||
<!-- 用户标签容器 -->
|
||||
<LinearLayout
|
||||
android:id="@+id/line"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
android:layout_marginTop="@dimen/dp_5"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintStart_toEndOf="@+id/avatar"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tv_name"/>
|
||||
android:id="@+id/line"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
android:layout_marginTop="@dimen/dp_5"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintStart_toEndOf="@+id/avatar"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tv_name" />
|
||||
|
||||
<!-- 消息内容 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="left|center_vertical"
|
||||
android:layout_marginStart="4dp"
|
||||
android:layout_marginTop="2dp"
|
||||
android:padding="@dimen/dp_3"
|
||||
android:paddingEnd="@dimen/dp_10"
|
||||
app:layout_constraintStart_toEndOf="@+id/avatar"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/line">
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="4dp"
|
||||
android:layout_marginTop="2dp"
|
||||
android:gravity="left|center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:padding="@dimen/dp_3"
|
||||
android:paddingEnd="@dimen/dp_10"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/avatar"
|
||||
app:layout_constraintTop_toBottomOf="@+id/line">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:lineHeight="@dimen/dp_20"
|
||||
android:lineSpacingExtra="@dimen/dp_2"
|
||||
android:paddingStart="@dimen/dp_8"
|
||||
android:paddingEnd="@dimen/dp_8"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_14"
|
||||
tools:text="饶利: 潇洒亼◇生2.0:"
|
||||
tools:visibility="gone"/>
|
||||
android:id="@+id/tv_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:lineHeight="@dimen/dp_20"
|
||||
android:lineSpacingExtra="@dimen/dp_2"
|
||||
android:paddingStart="@dimen/dp_8"
|
||||
android:paddingEnd="@dimen/dp_8"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_14"
|
||||
tools:text="饶利: 潇洒亼◇生2.0:"
|
||||
tools:visibility="gone" />
|
||||
|
||||
<com.xscm.moduleutil.widget.AdaptiveImageView
|
||||
android:id="@+id/im_emj"
|
||||
android:layout_width="@dimen/dp_40"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
android:id="@+id/im_emj"
|
||||
android:layout_width="@dimen/dp_40"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
|
||||
tools:src="@mipmap/ic_launcher"
|
||||
android:scaleType="fitXY"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible"/>
|
||||
android:adjustViewBounds="true"
|
||||
android:scaleType="fitXY"
|
||||
android:visibility="gone"
|
||||
tools:src="@mipmap/ic_launcher"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/im_emj"-->
|
||||
<!-- android:layout_width="0dp"-->
|
||||
<!-- android:layout_height="0dp"-->
|
||||
<!-- android:layout_marginStart="@dimen/dp_2"-->
|
||||
<!-- android:paddingStart="@dimen/dp_8"-->
|
||||
<!-- android:paddingEnd="@dimen/dp_8"-->
|
||||
<!-- tools:src="@mipmap/ic_launcher"-->
|
||||
<!-- android:maxHeight="@dimen/dp_50"-->
|
||||
<!-- android:maxWidth="@dimen/dp_50"-->
|
||||
<!-- android:minWidth="@dimen/dp_40"-->
|
||||
<!-- android:minHeight="@dimen/dp_40"-->
|
||||
<!-- android:scaleType="centerCrop"-->
|
||||
<!-- android:adjustViewBounds="true"-->
|
||||
<!-- android:visibility="gone"-->
|
||||
<!-- tools:visibility="visible"-->
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/im_emj"-->
|
||||
<!-- android:layout_width="0dp"-->
|
||||
<!-- android:layout_height="0dp"-->
|
||||
<!-- android:layout_marginStart="@dimen/dp_2"-->
|
||||
<!-- android:paddingStart="@dimen/dp_8"-->
|
||||
<!-- android:paddingEnd="@dimen/dp_8"-->
|
||||
<!-- tools:src="@mipmap/ic_launcher"-->
|
||||
<!-- android:maxHeight="@dimen/dp_50"-->
|
||||
<!-- android:maxWidth="@dimen/dp_50"-->
|
||||
<!-- android:minWidth="@dimen/dp_40"-->
|
||||
<!-- android:minHeight="@dimen/dp_40"-->
|
||||
<!-- android:scaleType="centerCrop"-->
|
||||
<!-- android:adjustViewBounds="true"-->
|
||||
<!-- android:visibility="gone"-->
|
||||
<!-- tools:visibility="visible"-->
|
||||
|
||||
<!-- app:layout_constraintWidth_default="wrap"-->
|
||||
<!-- app:layout_constraintHeight_default="wrap"-->
|
||||
<!-- app:layout_constraintWidth_min="@dimen/dp_40"-->
|
||||
<!-- app:layout_constraintHeight_min="@dimen/dp_40"-->
|
||||
<!-- app:layout_constraintWidth_max="@dimen/dp_50"-->
|
||||
<!-- app:layout_constraintHeight_max="@dimen/dp_50"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="parent"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="parent"/>-->
|
||||
<!-- app:layout_constraintWidth_default="wrap"-->
|
||||
<!-- app:layout_constraintHeight_default="wrap"-->
|
||||
<!-- app:layout_constraintWidth_min="@dimen/dp_40"-->
|
||||
<!-- app:layout_constraintHeight_min="@dimen/dp_40"-->
|
||||
<!-- app:layout_constraintWidth_max="@dimen/dp_50"-->
|
||||
<!-- app:layout_constraintHeight_max="@dimen/dp_50"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="parent"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="parent"/>-->
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
@@ -44,11 +44,12 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
android:id="@+id/dy_name_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="萌新驾到"
|
||||
app:isShine="false"
|
||||
android:textColor="#212121"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:background="@color/transparent">
|
||||
android:background="@drawable/shape_dialog">
|
||||
|
||||
<app.dinus.com.loadingdrawable.LoadingView
|
||||
android:id="@+id/cool_wait_view"
|
||||
@@ -25,6 +25,8 @@
|
||||
android:text="加载中..."
|
||||
android:textColor="#333333"
|
||||
android:textSize="16sp"
|
||||
android:paddingBottom="@dimen/dp_10"
|
||||
android:layout_marginHorizontal="@dimen/dp_50"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/cool_wait_view" />
|
||||
|
||||
@@ -302,4 +302,29 @@
|
||||
<item name="android:windowIsFloating">true</item>
|
||||
<item name="android:windowContentOverlay">@null</item>
|
||||
</style>
|
||||
|
||||
|
||||
<declare-styleable name="ShineTextView">
|
||||
<!-- 闪光方式-->
|
||||
<attr name="shineType">
|
||||
<!-- 流光效果-->
|
||||
<enum name="shine" value="0" />
|
||||
<!-- 颜色替换效果,原先是一个颜色,经过流光替换成另一种颜色,必须设置开始颜色,跟结束颜色-->
|
||||
<enum name="replace" value="1" />
|
||||
</attr>
|
||||
<!-- 开始颜色-->
|
||||
<attr name="startColor" format="color" />
|
||||
<!-- 中间颜色-->
|
||||
<attr name="midColor" format="color" />
|
||||
<!-- 结束颜色-->
|
||||
<attr name="endColor" format="color" />
|
||||
<!-- 是否开启流光效果-->
|
||||
<attr name="isShine" format="boolean" />
|
||||
<!-- 设置流光时间-->
|
||||
<attr name="shineDuration" format="integer" />
|
||||
<!-- 流光次数-->
|
||||
<attr name="shineCount" format="integer" />
|
||||
</declare-styleable>
|
||||
|
||||
|
||||
</resources>
|
||||
@@ -50,6 +50,7 @@ import com.xscm.moduleutil.event.MqttBean;
|
||||
import com.xscm.moduleutil.event.RedBean;
|
||||
import com.xscm.moduleutil.event.UnreadCountEvent;
|
||||
import com.xscm.moduleutil.http.RetrofitClient;
|
||||
import com.xscm.moduleutil.utils.ClickUtils;
|
||||
import com.xscm.moduleutil.utils.ImageUtils;
|
||||
import com.xscm.moduleutil.utils.LanguageUtil;
|
||||
import com.tencent.imsdk.v2.V2TIMManager;
|
||||
@@ -87,22 +88,22 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
|
||||
@Override
|
||||
public void showLoadings() {
|
||||
// showLoading("加载中");
|
||||
showLoading();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void showLoadings(String content) {
|
||||
// showLoading(content);
|
||||
showLoading(content);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void disLoadings() {
|
||||
// disLoading();
|
||||
disLoading();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDestroy() {
|
||||
|
||||
ClickUtils.clearAllClickRecords();
|
||||
// 清理MQTT相关资源
|
||||
synchronized (mqttQueueLock) {
|
||||
mqttMessageQueue.clear();
|
||||
@@ -135,7 +136,7 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
if (MvpPre != null) {
|
||||
try {
|
||||
MvpPre.detachView();
|
||||
}catch (Exception e){
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
@@ -168,9 +169,9 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
@Override
|
||||
public void onSuccess(Long aLong) {
|
||||
// 通知未读数变化
|
||||
UnreadCountEvent event =CommonAppContext.getInstance().unreadCountEvent;
|
||||
if (event==null){
|
||||
event=new UnreadCountEvent();
|
||||
UnreadCountEvent event = CommonAppContext.getInstance().unreadCountEvent;
|
||||
if (event == null) {
|
||||
event = new UnreadCountEvent();
|
||||
}
|
||||
event.setALong(aLong);
|
||||
// 使用EventBus通知
|
||||
@@ -197,9 +198,9 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
|
||||
@Override
|
||||
public void onConnectSuccess() {//重连成功
|
||||
if (CommonAppContext.getInstance().playId!=null){
|
||||
if (CommonAppContext.getInstance().playId != null) {
|
||||
LogUtils.e("@@@", "重连成功");
|
||||
LogUtils.e("@@@", ""+CommonAppContext.getInstance().playId);
|
||||
LogUtils.e("@@@", "" + CommonAppContext.getInstance().playId);
|
||||
RetrofitClient.getInstance().roomUserReconnect(CommonAppContext.getInstance().playId);
|
||||
}
|
||||
}
|
||||
@@ -207,13 +208,13 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
@Override
|
||||
public void onConnectFailed(int code, String error) {
|
||||
LogUtils.e("@@@", "断开连接");
|
||||
CommonAppContext.getInstance().onConnectFailed=true;
|
||||
CommonAppContext.getInstance().onConnectFailed = true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onKickedOffline() {
|
||||
// queren1();
|
||||
if (CommonAppContext.getInstance().playId!=null){
|
||||
if (CommonAppContext.getInstance().playId != null) {
|
||||
ToastUtils.showShort("您的账号已被挤下线");
|
||||
try {
|
||||
CommonAppContext.getInstance().clearLoginInfo();
|
||||
@@ -243,7 +244,7 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
v -> {
|
||||
// 点击“确认”按钮时执行删除操作
|
||||
|
||||
if (CommonAppContext.getInstance().playId!=null){
|
||||
if (CommonAppContext.getInstance().playId != null) {
|
||||
RoomManager.getInstance().exitRoom(CommonAppContext.getInstance().playId);
|
||||
}
|
||||
try {
|
||||
@@ -260,7 +261,6 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public Resources getResources() {
|
||||
Resources resources = super.getResources();
|
||||
@@ -537,7 +537,7 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
public void onEvent(XLHBean event) {
|
||||
LogUtils.e("收到XLH", event);
|
||||
if (event == null) return;
|
||||
if (event.getText()==null || event.getText().isEmpty()) return;
|
||||
if (event.getText() == null || event.getText().isEmpty()) return;
|
||||
if (SpUtil.getFloatingScreen() == 1) {
|
||||
synchronized (xlhQueueLock) {
|
||||
xlhMessageQueue.add(event);
|
||||
@@ -552,10 +552,10 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
}
|
||||
|
||||
@Subscribe(threadMode = ThreadMode.MAIN)
|
||||
public void onEvent(RedBean event){
|
||||
public void onEvent(RedBean event) {
|
||||
LogUtils.e("收到红包", event);
|
||||
if (event==null) return;
|
||||
if (SpUtil.getFloatingScreen()==1){
|
||||
if (event == null) return;
|
||||
if (SpUtil.getFloatingScreen() == 1) {
|
||||
|
||||
synchronized (RedQueueLock) {
|
||||
redMessageQueue.add(event);
|
||||
@@ -581,7 +581,7 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
showPiaoPingMessageRed(redBean);
|
||||
}
|
||||
|
||||
private void showPiaoPingMessageRed(RedBean redBean){
|
||||
private void showPiaoPingMessageRed(RedBean redBean) {
|
||||
try {
|
||||
// 清理之前的视图(如果存在)
|
||||
if (currentRedView != null && currentRedView.getParent() != null) {
|
||||
@@ -628,9 +628,11 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 在类中添加成员变量
|
||||
private MediaPlayer redPacketMediaPlayer = null;
|
||||
private boolean isRedPacketMediaPrepared = false;
|
||||
|
||||
// 添加播放红包音效的方法
|
||||
private void playRedPacketSound() {
|
||||
try {
|
||||
@@ -664,11 +666,11 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
}
|
||||
} catch (Exception e) {
|
||||
LogUtils.e("播放红包音效失败", e);
|
||||
isRedPacketMediaPrepared=false;
|
||||
isRedPacketMediaPrepared = false;
|
||||
}
|
||||
}
|
||||
|
||||
private void updateRedFloatingViewData(View view, RedBean redBean){
|
||||
private void updateRedFloatingViewData(View view, RedBean redBean) {
|
||||
TextView textView = view.findViewById(R.id.tv_name);
|
||||
|
||||
if (redBean != null) {
|
||||
@@ -989,7 +991,7 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
// 这里可以根据实际需求实现跳转逻辑
|
||||
// 例如:跳转到礼物详情页面、用户主页等
|
||||
// 使用缓存数据进入房间
|
||||
RoomManager.getInstance().fetchRoomDataAndEnter(getApplicationContext(), xlhBean.getRoom_id(), "",null);
|
||||
RoomManager.getInstance().fetchRoomDataAndEnter(getApplicationContext(), xlhBean.getRoom_id(), "", null);
|
||||
|
||||
}
|
||||
|
||||
@@ -997,7 +999,7 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
// 这里可以根据实际需求实现跳转逻辑
|
||||
// 例如:跳转到礼物详情页面、用户主页等
|
||||
// 使用缓存数据进入房间
|
||||
RoomManager.getInstance().fetchRoomDataAndEnter(getApplicationContext(), redBean.getRoom_id(), "",null);
|
||||
RoomManager.getInstance().fetchRoomDataAndEnter(getApplicationContext(), redBean.getRoom_id(), "", null);
|
||||
}
|
||||
|
||||
|
||||
@@ -1010,13 +1012,13 @@ public abstract class BaseMvpActivity<P extends IPresenter, VDB extends ViewData
|
||||
}
|
||||
|
||||
|
||||
public void singleTaskToActivity(Class<?> clazz){
|
||||
public void singleTaskToActivity(Class<?> clazz) {
|
||||
Intent intent = new Intent(this, clazz);
|
||||
intent.addFlags(Intent.FLAG_ACTIVITY_REORDER_TO_FRONT);
|
||||
startActivity( intent);
|
||||
startActivity(intent);
|
||||
}
|
||||
|
||||
public void toActivity(Class<?> clazz, Bundle bundle){
|
||||
public void toActivity(Class<?> clazz, Bundle bundle) {
|
||||
Intent intent = new Intent(this, clazz);
|
||||
intent.putExtras(bundle);
|
||||
startActivity(intent);
|
||||
|
||||
@@ -234,7 +234,7 @@ public class ImproveInfoActivity extends BaseMvpActivity<ImproveInfoPresenter, A
|
||||
List<LocalMedia> localMedia1 = PictureSelector.obtainSelectorList(data);
|
||||
if (localMedia1 != null && localMedia1.size() != 0) {
|
||||
LocalMedia imgMedia = localMedia1.get(0);
|
||||
MvpPre.uploadFile(new File(imgMedia.getRealPath()), 3);
|
||||
MvpPre.uploadFile(new File(imgMedia.getRealPath()), 0);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -24,7 +24,10 @@ public class ImproveInfoPresenter extends BasePresenter<ImproveInfoContacts.View
|
||||
|
||||
@Override
|
||||
public void uploadFile(File file, int type) {
|
||||
MvpRef.get().showLoadings("上传中...");
|
||||
if (MvpRef==null){
|
||||
MvpRef=new WeakReference<>(mView);
|
||||
}
|
||||
// MvpRef.get().showLoadings("上传中...");
|
||||
String url = OSSOperUtils.getPath(file, type);
|
||||
CosUploadManager.getInstance(CommonAppContext.getInstance()).upParameters(url,file.getPath(), new CosUploadManager.UploadCallback() {
|
||||
@Override
|
||||
@@ -100,6 +103,9 @@ public class ImproveInfoPresenter extends BasePresenter<ImproveInfoContacts.View
|
||||
|
||||
@Override
|
||||
public void onNext(String s) {
|
||||
if (MvpRef==null){
|
||||
MvpRef=new WeakReference<>(mView);
|
||||
}
|
||||
MvpRef.get().updateNicknameSuccess(s);
|
||||
}
|
||||
|
||||
@@ -121,6 +127,9 @@ public class ImproveInfoPresenter extends BasePresenter<ImproveInfoContacts.View
|
||||
|
||||
@Override
|
||||
public void onNext(String userPictrue) {
|
||||
if (MvpRef==null){
|
||||
MvpRef=new WeakReference<>(mView);
|
||||
}
|
||||
MvpRef.get().updateSexTrue(userPictrue);
|
||||
}
|
||||
|
||||
@@ -141,6 +150,9 @@ public class ImproveInfoPresenter extends BasePresenter<ImproveInfoContacts.View
|
||||
|
||||
@Override
|
||||
public void onNext(UserBean userBean) {
|
||||
if (MvpRef==null){
|
||||
MvpRef=new WeakReference<>(mView);
|
||||
}
|
||||
MvpRef.get().updateSuccess(userBean);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -23,6 +23,7 @@ import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.blankj.utilcode.util.ActivityUtils;
|
||||
import com.blankj.utilcode.util.LogUtils;
|
||||
import com.blankj.utilcode.util.ToastUtils;
|
||||
import com.xscm.modulemain.R;
|
||||
import com.xscm.modulemain.databinding.ActivityDynamicDetailBinding;
|
||||
@@ -274,6 +275,8 @@ public class DynamicDetailActivity extends BaseMvpActivity<CirclePresenter, Acti
|
||||
public void setCircleDetail(CircleListBean bean) {
|
||||
circleList.add(bean);
|
||||
cirleListAdapter.setNewData(circleList);
|
||||
|
||||
LogUtils.e("setCircleDetail",zone_id+"==============");
|
||||
MvpPre.getCommentList(zone_id, "1", "30");
|
||||
}
|
||||
|
||||
|
||||
@@ -79,7 +79,7 @@ public class PopularRoomActivity extends BaseMvpActivity<VoiceCategoryPresenter,
|
||||
});
|
||||
|
||||
mAdapter.setOnRoomClickListener((room, position) -> {
|
||||
if ( ClickUtils.isFastDoubleClick()){
|
||||
if ( ClickUtils.isFastDoubleClick(mBinding.rvPopularRoom)){
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -122,6 +122,7 @@ import com.xscm.moduleutil.bean.room.FriendUserBean
|
||||
import com.xscm.moduleutil.bean.room.RoomAuction
|
||||
import com.xscm.moduleutil.bean.room.RoomAuction.AuctionListBean
|
||||
import com.xscm.moduleutil.bean.room.RoomBean
|
||||
import com.xscm.moduleutil.bean.room.RoomHourBean
|
||||
import com.xscm.moduleutil.bean.room.RoomInfoResp
|
||||
import com.xscm.moduleutil.bean.room.RoomOnline
|
||||
import com.xscm.moduleutil.bean.room.RoomOnlineBean
|
||||
@@ -155,6 +156,7 @@ import com.xscm.moduleutil.rtc.AgoraManagerEx
|
||||
import com.xscm.moduleutil.rtc.MusicPlayBean
|
||||
import com.xscm.moduleutil.service.MyRoomSingleton
|
||||
import com.xscm.moduleutil.utils.ARouteConstants
|
||||
import com.xscm.moduleutil.utils.ClickUtils
|
||||
import com.xscm.moduleutil.utils.ColorManager
|
||||
import com.xscm.moduleutil.utils.ImageUtils
|
||||
import com.xscm.moduleutil.utils.PermissionDescriptionHelper
|
||||
@@ -251,7 +253,6 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
|
||||
|
||||
override fun doDone() {
|
||||
Log.e("AAAAAAAAAAA", "C " + com.xscm.moduleutil.utils.TimeUtils.getCurrentDate2())
|
||||
isOnline = intent.getBooleanExtra("isOnline", false)
|
||||
password = intent.getStringExtra("password")
|
||||
roomId = intent.getStringExtra("roomId")
|
||||
@@ -271,12 +272,14 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
}
|
||||
}
|
||||
//重新进入无需传参
|
||||
// isOnline = intent.getBooleanExtra("isOnline", false)
|
||||
// password = intent.getStringExtra("password")
|
||||
// roomId = intent.getStringExtra("roomId")
|
||||
// mRoomInfoResp = intent.getSerializableExtra("roomInfo") as RoomInfoResp?
|
||||
// taskId = intent.getStringExtra("taskId")
|
||||
|
||||
val roomInfoResp = intent.getSerializableExtra("roomInfo") as RoomInfoResp?
|
||||
if (!roomInfoResp?.room_info?.room_id.equals(mRoomInfoResp?.room_info?.room_id)) {
|
||||
isOnline = intent.getBooleanExtra("isOnline", false)
|
||||
password = intent.getStringExtra("password")
|
||||
roomId = intent.getStringExtra("roomId")
|
||||
taskId = intent.getStringExtra("taskId")
|
||||
mRoomInfoResp = roomInfoResp
|
||||
}
|
||||
LogUtils.e("RoomActivity", "onNewIntent")
|
||||
}
|
||||
|
||||
@@ -439,7 +442,11 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
|
||||
override fun initData() {
|
||||
if (!EasyPermissions.hasPermissions(this, *permissions)) {
|
||||
PermissionDescriptionHelper.addPermissionDescription(false, mBinding?.root as ViewGroup, permissions)
|
||||
PermissionDescriptionHelper.addPermissionDescription(
|
||||
false,
|
||||
mBinding?.root as ViewGroup,
|
||||
permissions
|
||||
)
|
||||
EasyPermissions.requestPermissions(
|
||||
this, "请开启录音使用权限",
|
||||
1, *permissions
|
||||
@@ -585,6 +592,8 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
|
||||
mBinding!!.roomTop.root.isClickable = false
|
||||
setView(mRoomInfoResp)
|
||||
|
||||
MvpPre?.getRoomOnline(roomId, "1", "10")
|
||||
}
|
||||
|
||||
// 添加弹框到管理列表
|
||||
@@ -693,10 +702,10 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置顶部操作按钮的可见性和点击事件
|
||||
* 包括结束按钮和延时按钮的初始化和事件绑定
|
||||
*/
|
||||
/**
|
||||
* 设置顶部操作按钮的可见性和点击事件
|
||||
* 包括结束按钮和延时按钮的初始化和事件绑定
|
||||
*/
|
||||
fun tob() {
|
||||
// 获取并显示stubButtons2布局
|
||||
val stub = mBinding!!.roomTop.stubButtons2
|
||||
@@ -708,7 +717,7 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
imActionJs.setOnClickListener { dialogEnd() }
|
||||
// 设置结束按钮点击事件,调用dialogEnd()方法
|
||||
imActionYs.setOnClickListener {
|
||||
// 设置延时按钮点击事件,调用MvpPre的auctionDelay方法,传入当前拍卖ID
|
||||
// 设置延时按钮点击事件,调用MvpPre的auctionDelay方法,传入当前拍卖ID
|
||||
MvpPre!!.auctionDelay(
|
||||
SpUtil.getauctionId()
|
||||
)
|
||||
@@ -755,8 +764,8 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
if (visible) View.VISIBLE else View.INVISIBLE
|
||||
}
|
||||
|
||||
// 根据传入的visible参数设置JS按钮的可见性
|
||||
// 使用View.VISIBLE显示按钮,使用View.INVISIBLE隐藏按钮
|
||||
// 根据传入的visible参数设置JS按钮的可见性
|
||||
// 使用View.VISIBLE显示按钮,使用View.INVISIBLE隐藏按钮
|
||||
fun upYs(visible: Boolean) {
|
||||
mBinding!!.roomTop.imActionYs.visibility =
|
||||
if (visible) View.VISIBLE else View.INVISIBLE
|
||||
@@ -1688,7 +1697,7 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
when (typeId) {
|
||||
RoomType.AUCTION -> {
|
||||
if ("9" == pitNumber) {
|
||||
mRoomInfoResp!!.room_info.pit_list[0] = getPitBean(messageEvent,1)
|
||||
mRoomInfoResp!!.room_info.pit_list[0] = getPitBean(messageEvent, 1)
|
||||
if (mRoomInfoResp!!.user_info != null) {
|
||||
mRoomInfoResp!!.user_info.pit_number = pitNumber.toInt()
|
||||
}
|
||||
@@ -1696,6 +1705,7 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
roomFragment!!.upRoomInfoData(mRoomInfoResp)
|
||||
roomFragment!!.handleRoomMessage(messageEvent)
|
||||
}
|
||||
|
||||
RoomType.DATING -> {
|
||||
val labelId = mRoomInfoResp!!.room_info.label_id
|
||||
if ("2" == labelId) {
|
||||
@@ -1707,16 +1717,18 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
roomFragment!!.handleRoomMessage(messageEvent)
|
||||
}
|
||||
}
|
||||
|
||||
RoomType.MUTUAL_ENTERTAINMENT -> {
|
||||
mBinding!!.rlMore.visibility = View.GONE
|
||||
mBinding!!.rlMisc.visibility = View.GONE
|
||||
|
||||
roomFragment!!.handleRoomMessage(messageEvent)
|
||||
}
|
||||
else ->{
|
||||
|
||||
else -> {
|
||||
roomFragment!!.updateSeatViewExchangedWithPitArray(mRoomInfoResp)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1742,6 +1754,7 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
aBoolean = true
|
||||
ivWheatFeeding(com.xscm.moduleutil.R.mipmap.room_wheat_feeding)
|
||||
setBoolean(aBoolean)
|
||||
mRoomInfoResp?.user_info?.pit_number = 0
|
||||
setRoleType(0, 0)
|
||||
switchMic(2)
|
||||
}
|
||||
@@ -1869,16 +1882,19 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
|
||||
|
||||
private fun handleMsgType1001(roomMessageEvent: RoomMessageEvent) {
|
||||
if (roomMessageEvent.text.fromUserInfo.enter_image?.isNotEmpty() == true){
|
||||
if (roomMessageEvent.text.fromUserInfo.enter_image?.isNotEmpty() == true) {
|
||||
showFloatingMessage(roomMessageEvent.text.fromUserInfo)
|
||||
}
|
||||
MvpPre?.getRoomOnline(roomId, "1", "10")
|
||||
|
||||
// number++
|
||||
// mBinding!!.roomTop.tvNum.text = number.toString() + ""
|
||||
}
|
||||
|
||||
private fun showFloatingMessage(userInfo: UserInfo) {
|
||||
try {
|
||||
// 清理之前的视图(如果存在)
|
||||
if ( currentMqttView?.getParent() != null) {
|
||||
if (currentMqttView?.getParent() != null) {
|
||||
val parent = currentMqttView?.getParent() as ViewGroup
|
||||
parent.removeView(currentMqttView)
|
||||
}
|
||||
@@ -1913,6 +1929,7 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
private fun resetAndStartMqttAnimation(view: View, onAnimationEnd: Runnable) {
|
||||
try {
|
||||
val screenWidth = getScreenWidth()
|
||||
@@ -1936,10 +1953,14 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
// 停留后退出
|
||||
CommonAppContext.postDelayed(Runnable {
|
||||
val exitAnim = TranslateAnimation(
|
||||
Animation.ABSOLUTE, ((screenWidth - SystemUtils.getWidth(316)) / 2).toFloat(),
|
||||
Animation.ABSOLUTE, -screenWidth.toFloat(),
|
||||
Animation.ABSOLUTE, 0f,
|
||||
Animation.ABSOLUTE, 0f
|
||||
Animation.ABSOLUTE,
|
||||
((screenWidth - SystemUtils.getWidth(316)) / 2).toFloat(),
|
||||
Animation.ABSOLUTE,
|
||||
-screenWidth.toFloat(),
|
||||
Animation.ABSOLUTE,
|
||||
0f,
|
||||
Animation.ABSOLUTE,
|
||||
0f
|
||||
)
|
||||
exitAnim.setDuration(3000)
|
||||
exitAnim.setInterpolator(DecelerateInterpolator(2f))
|
||||
@@ -1968,6 +1989,7 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
onAnimationEnd.run()
|
||||
}
|
||||
}
|
||||
|
||||
private fun getScreenWidth(): Int {
|
||||
val displayMetrics = DisplayMetrics()
|
||||
if (getWindowManager() != null) {
|
||||
@@ -1993,11 +2015,13 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
}
|
||||
mBinding!!.roomTop.tvNum.text = number.toString()
|
||||
if (text == null || text.fromUserInfo == null) return
|
||||
if (text.fromUserInfo.user_id == SpUtil.getUserId()) {
|
||||
MessageListenerSingleton.quitGroup(roomId);
|
||||
quit();
|
||||
performExitRoom(1);
|
||||
}
|
||||
// if (text.fromUserInfo.user_id == SpUtil.getUserId()) {
|
||||
// MessageListenerSingleton.quitGroup(roomId);
|
||||
// quit()
|
||||
// performExitRoom(1)
|
||||
// }
|
||||
MvpPre?.getRoomOnline(roomId, "1", "10")
|
||||
|
||||
}
|
||||
|
||||
private fun handleMsgType1029(messageEvent: RoomMessageEvent, text: T?) {
|
||||
@@ -2353,6 +2377,9 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
private var mCountDownTimer2: CountDownTimer? = null
|
||||
|
||||
private fun onClick(view: View) {
|
||||
if (ClickUtils.isFastDoubleClick(view)) {
|
||||
return
|
||||
}
|
||||
val id = view.id
|
||||
if (id == R.id.btn_follow) {
|
||||
MvpPre!!.userGuanz(mRoomInfoResp!!.room_info.room_id, "2")
|
||||
@@ -2513,7 +2540,7 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
return 0
|
||||
}
|
||||
|
||||
private fun getHostUser(): Int {
|
||||
fun getHostUser(): Int {
|
||||
if (mRoomInfoResp?.getUser_info()?.getPit_number() == 9) {
|
||||
return if (mRoomInfoResp?.getUser_info()?.getIs_room_owner() == 1) {
|
||||
1
|
||||
@@ -2556,7 +2583,6 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
RoomManager.getInstance().exitRoom(roomId)
|
||||
// 清理资源
|
||||
cleanupResources()
|
||||
|
||||
finish()
|
||||
}
|
||||
|
||||
@@ -2879,6 +2905,7 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
// 设置对话框在底部显示
|
||||
val window = dialog.window
|
||||
if (window != null) {
|
||||
window.decorView.setPadding(0, 0, 0, 0)
|
||||
window.setGravity(Gravity.BOTTOM)
|
||||
// 修复宽度问题
|
||||
window.setLayout(
|
||||
@@ -3006,121 +3033,19 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
}
|
||||
}
|
||||
|
||||
private var isSwitchRoom: Boolean = false
|
||||
|
||||
// TODO:不进入 2025/8/26 加入房间
|
||||
override fun roomInfo(resp: RoomInfoResp) {
|
||||
if (true)
|
||||
if (!isSwitchRoom)
|
||||
return
|
||||
AppStateManager.getInstance().roomInfo = resp
|
||||
val roomBean = resp.room_info
|
||||
this.mRoomBean = roomBean
|
||||
this.mRoomUserBean = resp.user_info
|
||||
this.mRoomOwnerBean = resp.room_owner
|
||||
this.roomId = roomBean.room_id
|
||||
MessageListenerSingleton.getInstance().joinGroup(roomId) //加入房间im
|
||||
ImageUtils.loadHeadCC(resp.room_info.room_cover, mBinding!!.roomTop.avatar)
|
||||
mBinding!!.roomTop.name.text = roomBean.room_name
|
||||
mBinding!!.roomTop.idVal.text = "ID:" + roomBean.room_number
|
||||
if (mRoomUserBean?.getIs_room_owner() == 1) {
|
||||
mBinding!!.roomTop.btnFollow.visibility = View.GONE
|
||||
} else {
|
||||
mBinding!!.roomTop.btnFollow.visibility = View.VISIBLE
|
||||
if (resp.isCollect) {
|
||||
mBinding!!.roomTop.btnFollow.background =
|
||||
resources.getDrawable(com.xscm.moduleutil.R.mipmap.collected)
|
||||
mBinding!!.roomTop.btnFollow.text = ""
|
||||
}
|
||||
}
|
||||
number = roomBean.online_number
|
||||
mBinding!!.roomTop.tvNum.text = number.toString() + ""
|
||||
|
||||
val userIds = StringBuilder()
|
||||
for (i in mRoomInfoResp!!.room_info.pit_list.indices) {
|
||||
val userId = mRoomInfoResp!!.room_info.pit_list[i].user_id
|
||||
if (userId != null && userId != "0" && !userId.isEmpty()) {
|
||||
if (userIds.length > 0) {
|
||||
userIds.append(",")
|
||||
}
|
||||
userIds.append(userId)
|
||||
}
|
||||
}
|
||||
if (!isFinishing && !isDestroyed) {
|
||||
resetFragment()
|
||||
upHeight()
|
||||
} else {
|
||||
Log.e("Fragment", "Fragment transaction skipped due to state loss.")
|
||||
}
|
||||
LogUtils.e("加入", roomId)
|
||||
|
||||
CommonAppContext.getInstance().isPlaying = true
|
||||
CommonAppContext.getInstance().playId = roomId
|
||||
CommonAppContext.getInstance().playName = mRoomBean!!.room_name
|
||||
|
||||
CommonAppContext.getInstance().playCover = resp.room_info.room_cover
|
||||
CommonAppContext.getInstance().showSelf = resp.is_show_self == 1
|
||||
|
||||
if (mRoomUserBean?.getIs_collect() == 1) {
|
||||
mBinding!!.roomTop.btnFollow.background =
|
||||
resources.getDrawable(com.xscm.moduleutil.R.mipmap.yishouc)
|
||||
mBinding!!.roomTop.btnFollow.text = ""
|
||||
} else {
|
||||
ThemeableDrawableUtils.setThemeableRoundedBackground(
|
||||
mBinding!!.roomTop.btnFollow,
|
||||
ColorManager.getInstance().primaryColorInt,
|
||||
53
|
||||
)
|
||||
mBinding!!.roomTop.btnFollow.setTextColor(ColorManager.getInstance().buttonColorInt)
|
||||
mBinding!!.roomTop.btnFollow.text = "收藏"
|
||||
// mBinding.roomTop.btnFollow.setBackground(getResources().getDrawable(com.xscm.moduleutil.R.mipmap.collect));
|
||||
}
|
||||
if ((roomBean.type_id == "3" || roomBean.type_id == "1" || roomBean.type_id == "4") && roomBean.label_id == "2") {
|
||||
AgoraManager.getInstance().isBjMusic = false
|
||||
} else {
|
||||
AgoraManager.getInstance().isBjMusic = true
|
||||
}
|
||||
|
||||
AgoraManager.stopMuisc()
|
||||
initializeAudio()
|
||||
|
||||
|
||||
toutiao()
|
||||
upRoomInfo(resp)
|
||||
|
||||
|
||||
if (userIds.length > 0 && roomId != null) {
|
||||
// MvpPre.userOnlineStatus(userIds.toString(), roomId);
|
||||
}
|
||||
if (publicScreenFragment != null) {
|
||||
publicScreenFragment!!.upRoomInfo(resp)
|
||||
}
|
||||
instView()
|
||||
|
||||
if (mRoomInfoResp!!.user_info.pit_number == 9 && mRoomInfoResp!!.user_info.user_id == SpUtil.getUserId()) {
|
||||
mBinding!!.roomTop.rl.visibility = View.VISIBLE
|
||||
ivSoundEffects(true)
|
||||
} else {
|
||||
mBinding!!.roomTop.rl.visibility = View.GONE
|
||||
ivSoundEffects(false)
|
||||
}
|
||||
|
||||
if (resp.room_info.type_id == "7" || resp.room_info.type_id == "2") {
|
||||
mBinding!!.rlMore.visibility = View.GONE
|
||||
mBinding!!.rlMisc.visibility = View.GONE
|
||||
}
|
||||
setupEffectView()
|
||||
|
||||
if (mRoomInfoResp!!.gift_cycle != null && mRoomInfoResp!!.gift_cycle.xlh_info != null && mRoomInfoResp!!.gift_cycle.xlh_info.xlh_status != null && mRoomInfoResp!!.gift_cycle.xlh_info.xlh_status == "1") {
|
||||
mBinding?.xlhRk?.visibility = View.VISIBLE
|
||||
xlhDjs(mRoomInfoResp!!.gift_cycle.xlh_info.end_time)
|
||||
} else {
|
||||
mBinding?.xlhRk?.visibility = View.INVISIBLE
|
||||
releaseCountDownTimer1()
|
||||
}
|
||||
|
||||
if (mRoomInfoResp!!.hour_ranking_open == 1) {
|
||||
mBinding!!.clXsb.visibility = View.VISIBLE
|
||||
} else {
|
||||
mBinding!!.clXsb.visibility = View.GONE
|
||||
}
|
||||
mRoomInfoResp = resp
|
||||
isOnline = true
|
||||
password = ""
|
||||
roomId = mRoomInfoResp?.room_info?.room_id
|
||||
taskId = null
|
||||
initPublicScreenFragment()
|
||||
setView(resp)
|
||||
}
|
||||
|
||||
//隐藏视图
|
||||
@@ -3466,6 +3391,18 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
performExitRoom(2)
|
||||
}
|
||||
|
||||
is RoomHourBean.RoomListBean -> {
|
||||
AgoraManager.getInstance().cleanup()
|
||||
roomId = event.room_id
|
||||
isSwitchRoom = true
|
||||
// 重新连接房间相关服务
|
||||
resumeRoomState()
|
||||
publicScreenFragment?.onDestroy()
|
||||
publicScreenFragment = null
|
||||
|
||||
MvpPre?.getRoomIn(event.room_id, "")
|
||||
}
|
||||
|
||||
is HeadlineBean -> {
|
||||
mRoomInfoResp!!.room_info.head_line = event
|
||||
toutiao()
|
||||
@@ -3565,45 +3502,45 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
|
||||
override fun onResume() {
|
||||
super.onResume()
|
||||
GiftDisplayManager.getInstance().setupDisplayView(mBinding?.giftContainer)
|
||||
CommonAppContext.getInstance().isShow = true
|
||||
CommonAppContext.getInstance().isPlaying = true
|
||||
CommonAppContext.getInstance().isRoomJoininj = false
|
||||
// 当Activity恢复时,重置标记
|
||||
userLeaving = true
|
||||
|
||||
MvpPre!!.roomRedPackets(roomId);
|
||||
LogUtils.e("RoomActivity", "onResume")
|
||||
|
||||
if ((mRoomInfoResp?.room_info?.type_id.equals("1") || mRoomInfoResp?.room_info?.type_id.equals(
|
||||
"8"
|
||||
) || mRoomInfoResp?.room_info?.type_id.equals(
|
||||
"3"
|
||||
)
|
||||
|| mRoomInfoResp?.room_info?.type_id.equals("4")) && mRoomInfoResp?.room_info?.label_id.equals(
|
||||
"2"
|
||||
)
|
||||
) {
|
||||
return
|
||||
}
|
||||
if (isInBackground) {
|
||||
isInBackground = false
|
||||
MvpPre!!.postRoomInfo(CommonAppContext.getInstance().playId)
|
||||
}
|
||||
|
||||
// 检查是否从最小化状态恢复
|
||||
if (isMinimized) {
|
||||
isMinimized = false
|
||||
clearMinimizeState()
|
||||
// 恢复房间状态
|
||||
resumeRoomState()
|
||||
setupEffectView()
|
||||
|
||||
MvpPre?.postRoomInfo(CommonAppContext.getInstance().playId)
|
||||
}
|
||||
|
||||
// 延迟调整布局,确保视图已经完全加载
|
||||
mBinding?.mainContentContainer?.post { this.adjustLayoutHeights() }
|
||||
// GiftDisplayManager.getInstance().setupDisplayView(mBinding?.giftContainer)
|
||||
// CommonAppContext.getInstance().isShow = true
|
||||
// CommonAppContext.getInstance().isPlaying = true
|
||||
// CommonAppContext.getInstance().isRoomJoininj = false
|
||||
// // 当Activity恢复时,重置标记
|
||||
// userLeaving = true
|
||||
//
|
||||
// MvpPre!!.roomRedPackets(roomId);
|
||||
// LogUtils.e("RoomActivity", "onResume")
|
||||
//
|
||||
// if ((mRoomInfoResp?.room_info?.type_id.equals("1") || mRoomInfoResp?.room_info?.type_id.equals(
|
||||
// "8"
|
||||
// ) || mRoomInfoResp?.room_info?.type_id.equals(
|
||||
// "3"
|
||||
// )
|
||||
// || mRoomInfoResp?.room_info?.type_id.equals("4")) && mRoomInfoResp?.room_info?.label_id.equals(
|
||||
// "2"
|
||||
// )
|
||||
// ) {
|
||||
// return
|
||||
// }
|
||||
// if (isInBackground) {
|
||||
// isInBackground = false
|
||||
// MvpPre!!.postRoomInfo(CommonAppContext.getInstance().playId)
|
||||
// }
|
||||
//
|
||||
// // 检查是否从最小化状态恢复
|
||||
// if (isMinimized) {
|
||||
// isMinimized = false
|
||||
// clearMinimizeState()
|
||||
// // 恢复房间状态
|
||||
// resumeRoomState()
|
||||
// setupEffectView()
|
||||
//
|
||||
// MvpPre?.postRoomInfo(CommonAppContext.getInstance().playId)
|
||||
// }
|
||||
//
|
||||
// // 延迟调整布局,确保视图已经完全加载
|
||||
// mBinding?.mainContentContainer?.post { this.adjustLayoutHeights() }
|
||||
}
|
||||
|
||||
// 添加检查房间连接状态的方法
|
||||
@@ -4388,4 +4325,25 @@ class RoomActivity : BaseMvpActivity<RoomPresenter?, ActivityRoomBinding?>(),
|
||||
}
|
||||
|
||||
|
||||
private val CLICK_INTERVAL: Long = 500 // 500ms内不允许重复点击
|
||||
private var lastClickTime: Long = 0
|
||||
private var lastClickedUserId = "" // 记录上次点击的用户ID
|
||||
private var lastClickedPitNumber = "" // 记录上次点击的麦位号
|
||||
|
||||
fun isFastDoubleClick(userId: String, pitNumber: String): Boolean {
|
||||
val currentTime = System.currentTimeMillis()
|
||||
if (currentTime - lastClickTime < CLICK_INTERVAL &&
|
||||
userId == lastClickedUserId &&
|
||||
pitNumber == lastClickedPitNumber
|
||||
) {
|
||||
return true // 是快速重复点击
|
||||
}
|
||||
|
||||
// 更新上次点击信息
|
||||
lastClickTime = currentTime
|
||||
lastClickedUserId = userId
|
||||
lastClickedPitNumber = pitNumber
|
||||
return false // 不是快速重复点击
|
||||
}
|
||||
|
||||
}
|
||||
@@ -216,6 +216,7 @@ public class ChatRoomFragment extends BaseMvpFragment<ChatRoomPresenter, RoomFra
|
||||
if (resp == null)
|
||||
return;
|
||||
roomInfoResp = resp;
|
||||
roomId = roomInfoResp.getRoom_info().getRoom_id();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -3,6 +3,7 @@ package com.xscm.modulemain.activity.room.fragment;
|
||||
import static android.view.View.GONE;
|
||||
import static android.view.View.VISIBLE;
|
||||
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.graphics.Color;
|
||||
import android.os.Bundle;
|
||||
@@ -15,6 +16,7 @@ import android.widget.PopupWindow;
|
||||
import android.widget.Switch;
|
||||
import android.widget.TextView;
|
||||
|
||||
import com.blankj.utilcode.util.ActivityUtils;
|
||||
import com.orhanobut.logger.Logger;
|
||||
import com.xscm.modulemain.R;
|
||||
import com.xscm.modulemain.activity.room.activity.RoomActivity;
|
||||
@@ -189,7 +191,7 @@ public class FriendshipRoomFragment extends BaseRoomFragment<FriendshipRoomPrese
|
||||
wheatView.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(wheatView)) {
|
||||
return; // 快速重复点击,直接返回
|
||||
}
|
||||
onWheatViewClick(position, wheatView);
|
||||
@@ -201,7 +203,7 @@ public class FriendshipRoomFragment extends BaseRoomFragment<FriendshipRoomPrese
|
||||
public void onZhulClick(RoomFriendshipWheatView view, RoomPitBean pitBean) {
|
||||
|
||||
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(wheatView)) {
|
||||
return; // 快速重复点击,直接返回
|
||||
}
|
||||
// configPower(pitBean);
|
||||
@@ -218,7 +220,7 @@ public class FriendshipRoomFragment extends BaseRoomFragment<FriendshipRoomPrese
|
||||
wheatView.setmOnCharmClickListener(new RoomFriendshipWheatView.onCharmClickListener() {
|
||||
@Override
|
||||
public void onCharmClick(RoomFriendshipWheatView view, RoomPitBean pitBean) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(wheatView)) {
|
||||
return; // 快速重复点击,直接返回
|
||||
}
|
||||
if (pitBean.getUser_id() != null && !pitBean.getUser_id().isEmpty() && !pitBean.getUser_id().equals("0")) {
|
||||
@@ -357,7 +359,16 @@ public class FriendshipRoomFragment extends BaseRoomFragment<FriendshipRoomPrese
|
||||
if (checkWeather(pitBean.getPit_number())) {
|
||||
showPopupMenu(wheatView); // v 是点击的按钮视图
|
||||
} else if (pitBean.getPit_number().equals("10")) {
|
||||
RoomOnlineDialogFragment.show(roomId, "10", roomInfoResp.getUser_info(), roomInfoResp, getChildFragmentManager());
|
||||
if (ActivityUtils.getTopActivity() instanceof RoomActivity){
|
||||
if (((RoomActivity) ActivityUtils.getTopActivity()).getHostUser() < 4){
|
||||
if (((RoomActivity) ActivityUtils.getTopActivity()).isFastDoubleClick(roomInfoResp.getUser_info().getUser_id()+"", pitBean.getPit_number())) {
|
||||
return;
|
||||
}
|
||||
RoomOnlineDialogFragment.show(roomId, "10", roomInfoResp.getUser_info(), roomInfoResp, getChildFragmentManager());
|
||||
}else {
|
||||
com.hjq.toast.ToastUtils.show("请等待主持抱麦");
|
||||
}
|
||||
}
|
||||
} else {
|
||||
MvpPre.applyPit(roomId, pitBean.getPit_number());
|
||||
}
|
||||
|
||||
@@ -8,7 +8,9 @@ import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.GridLayoutManager;
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.blankj.utilcode.util.ActivityUtils;
|
||||
import com.xscm.modulemain.R;
|
||||
import com.xscm.modulemain.activity.main.activity.MainActivity;
|
||||
import com.xscm.modulemain.adapter.HotAdapter;
|
||||
import com.xscm.modulemain.activity.room.contacts.HotListContacts;
|
||||
import com.xscm.modulemain.databinding.FragmentHotListBinding;
|
||||
@@ -115,12 +117,17 @@ public class HotListFragment extends BaseMvpFragment<HotListPresenter, FragmentH
|
||||
});
|
||||
|
||||
mAdapter.setOnRoomClickListener((room, position) -> {
|
||||
if ( ClickUtils.isFastDoubleClick()){
|
||||
if ( ClickUtils.isFastDoubleClick(mBinding.recycleView)){
|
||||
return;
|
||||
}
|
||||
voiceCategoryFragment.showLoading();
|
||||
if (ActivityUtils.getTopActivity() instanceof MainActivity){
|
||||
((MainActivity) ActivityUtils.getTopActivity()).isShowLoading(true);
|
||||
}
|
||||
// 添加索引有效性检查
|
||||
if (position < 0 || position >= mAdapter.getData().size()) {
|
||||
if (ActivityUtils.getTopActivity() instanceof MainActivity){
|
||||
((MainActivity) ActivityUtils.getTopActivity()).isShowLoading(false);
|
||||
}
|
||||
return;
|
||||
}
|
||||
TopRoom item = mAdapter.getItem(position);
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package com.xscm.modulemain.activity.room.fragment;
|
||||
|
||||
import android.graphics.Color;
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
@@ -166,6 +167,15 @@ public class RankingChildFragment extends BaseMvpFragment<DataListPresenter, Roo
|
||||
public void setNo1(CharmRankingResp listsBean) {
|
||||
ImageUtils.loadHeadCC(listsBean.getAvatar(), mBinding.roomRankTop1HeadIcon);
|
||||
mBinding.roomTop1Name.setText(listsBean.getNickname());
|
||||
|
||||
// if (!CharmRankingResp.getNickname_color().isEmpty()){
|
||||
// mBinding.roomTop1Name.setStartColor(Color.parseColor(CharmRankingResp.getNickname_color()));
|
||||
// mBinding.roomTop1Name.setShineColor(Color.parseColor(CharmRankingResp.getNickname_color()));
|
||||
// mBinding.roomTop1Name.setEndColor(Color.parseColor(CharmRankingResp.getNickname_color()));
|
||||
// mBinding.roomTop1Name.setShine(true);
|
||||
// mBinding.roomTop1Name.setShineType(0);
|
||||
// }
|
||||
|
||||
mBinding.roomHeadTop1Label.setText(StringUtil.toWan2(listsBean.getTotal(), 2));
|
||||
setview(listsBean.getIcon(), mBinding.llVip1);
|
||||
mBinding.roomRankTop1HeadIcon.setOnClickListener(new View.OnClickListener() {
|
||||
@@ -180,6 +190,16 @@ public class RankingChildFragment extends BaseMvpFragment<DataListPresenter, Roo
|
||||
public void setNo2(CharmRankingResp listsBean) {
|
||||
ImageUtils.loadHeadCC(listsBean.getAvatar(), mBinding.roomRankTop2HeadIcon);
|
||||
mBinding.roomTop2Name.setText(listsBean.getNickname());
|
||||
|
||||
// if (!CharmRankingResp.getNickname_color().isEmpty()){
|
||||
// mBinding.roomTop2Name.setStartColor(Color.parseColor(CharmRankingResp.getNickname_color()));
|
||||
// mBinding.roomTop2Name.setShineColor(Color.parseColor(CharmRankingResp.getNickname_color()));
|
||||
// mBinding.roomTop2Name.setEndColor(Color.parseColor(CharmRankingResp.getNickname_color()));
|
||||
// mBinding.roomTop2Name.setShine(true);
|
||||
// mBinding.roomTop2Name.setShineType(0);
|
||||
// }
|
||||
|
||||
|
||||
mBinding.roomHeadTop2Label.setText(StringUtil.toWan2(listsBean.getTotal(), 2));
|
||||
setview(listsBean.getIcon(), mBinding.llVip2);
|
||||
mBinding.roomRankTop2HeadIcon.setOnClickListener(new View.OnClickListener() {
|
||||
@@ -216,6 +236,16 @@ public class RankingChildFragment extends BaseMvpFragment<DataListPresenter, Roo
|
||||
public void setNo3(CharmRankingResp listsBean) {
|
||||
ImageUtils.loadHeadCC(listsBean.getAvatar(), mBinding.roomRankTop3HeadIcon);
|
||||
mBinding.roomTop3Name.setText(listsBean.getNickname());
|
||||
|
||||
|
||||
// if (!CharmRankingResp.getNickname_color().isEmpty()){
|
||||
// mBinding.roomTop3Name.setStartColor(Color.parseColor(CharmRankingResp.getNickname_color()));
|
||||
// mBinding.roomTop3Name.setShineColor(Color.parseColor(CharmRankingResp.getNickname_color()));
|
||||
// mBinding.roomTop3Name.setEndColor(Color.parseColor(CharmRankingResp.getNickname_color()));
|
||||
// mBinding.roomTop3Name.setShine(true);
|
||||
// mBinding.roomTop3Name.setShineType(0);
|
||||
// }
|
||||
|
||||
mBinding.roomHeadTop3Label.setText(StringUtil.toWan2(listsBean.getTotal(), 2));
|
||||
setview(listsBean.getIcon(), mBinding.llVip3);
|
||||
mBinding.roomRankTop3HeadIcon.setOnClickListener(new View.OnClickListener() {
|
||||
|
||||
@@ -293,7 +293,7 @@ public class RoomAuctionFragment extends BaseMvpFragment<RoomAuctionPresenterTow
|
||||
mBinding.qinmi.setTextColor(ColorManager.getInstance().getPrimaryColorInt());
|
||||
|
||||
mBinding.ivAuction1.setOnClickListener(view -> {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(mBinding.ivAuction1)) {
|
||||
return;
|
||||
}
|
||||
if (mBinding.ivAuction1.getUserId() != null && !mBinding.ivAuction1.getUserId().equals("")) {
|
||||
@@ -302,7 +302,7 @@ public class RoomAuctionFragment extends BaseMvpFragment<RoomAuctionPresenterTow
|
||||
});
|
||||
|
||||
mBinding.ivAuction1.setmOnCharmClickListener((view, pitBean) -> {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(mBinding.ivAuction1)) {
|
||||
return;
|
||||
}
|
||||
if (pitBean.getUser_id() != null && !pitBean.getUser_id().isEmpty() && !pitBean.getUser_id().equals("0")) {
|
||||
@@ -311,7 +311,7 @@ public class RoomAuctionFragment extends BaseMvpFragment<RoomAuctionPresenterTow
|
||||
});
|
||||
|
||||
mBinding.ivAuction2.setOnClickListener(view -> {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(mBinding.ivAuction2)) {
|
||||
return;
|
||||
}
|
||||
if (mBinding.ivAuction2.getUserId() != null && !mBinding.ivAuction2.getUserId().equals("")) {
|
||||
@@ -319,7 +319,7 @@ public class RoomAuctionFragment extends BaseMvpFragment<RoomAuctionPresenterTow
|
||||
}
|
||||
});
|
||||
mBinding.ivAuction2.setmOnCharmClickListener((view, pitBean) -> {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(mBinding.ivAuction2)) {
|
||||
return;
|
||||
}
|
||||
if (pitBean.getUser_id() != null && !pitBean.getUser_id().isEmpty() && !pitBean.getUser_id().equals("0")) {
|
||||
@@ -327,7 +327,7 @@ public class RoomAuctionFragment extends BaseMvpFragment<RoomAuctionPresenterTow
|
||||
}
|
||||
});
|
||||
mBinding.ivAuction3.setOnClickListener(view -> {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(mBinding.ivAuction3)) {
|
||||
return;
|
||||
}
|
||||
if (mBinding.ivAuction3.getUserId() != null && !mBinding.ivAuction3.getUserId().equals("")) {
|
||||
@@ -338,7 +338,7 @@ public class RoomAuctionFragment extends BaseMvpFragment<RoomAuctionPresenterTow
|
||||
|
||||
@Override
|
||||
public void onCharmClick(RoomMakeWheatView view, RoomPitBean pitBean) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(mBinding.ivAuction3)) {
|
||||
return;
|
||||
}
|
||||
if (pitBean.getUser_id() != null && !pitBean.getUser_id().isEmpty() && !pitBean.getUser_id().equals("0")) {
|
||||
@@ -349,7 +349,7 @@ public class RoomAuctionFragment extends BaseMvpFragment<RoomAuctionPresenterTow
|
||||
}
|
||||
|
||||
private void onChock(View view) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(view)) {
|
||||
return;
|
||||
}
|
||||
int id = view.getId();
|
||||
|
||||
@@ -332,28 +332,7 @@ public class RoomCabinFragment extends BaseRoomFragment<RoomCabinPresenter, Room
|
||||
bottomSheet.setOnOptionSelectedListener(new ExitRoomBottomSheet.OnOptionSelectedListener() {
|
||||
@Override
|
||||
public void onMinimize() {
|
||||
// 处理最小化逻辑,比如不销毁 Activity,仅移至后台
|
||||
// CommonAppContext.getInstance().isShow = false;
|
||||
// ARouter.getInstance().build(ARouteConstants.ME).navigation();//栈顶复用
|
||||
// if (getActivity() instanceof RoomActivity) {
|
||||
// ((RoomActivity) getActivity()).moveTaskToBack(true);
|
||||
// }
|
||||
|
||||
// 在Activity中
|
||||
// Intent serviceIntent = new Intent(getContext(), FloatingWindowService.class);
|
||||
|
||||
// 判断是否已有浮窗正在显示
|
||||
// if (!EasyFloat.isShow("testFloat")) {
|
||||
// // 启动前台服务以维持浮窗
|
||||
// Context context = requireContext();
|
||||
// if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
||||
// // Android 12+ 需要指定 foregroundServiceType
|
||||
// Intent serviceIntent = new Intent(context, FloatingWindowService.class);
|
||||
// serviceIntent.setAction("ACTION_START_FLOAT");
|
||||
// context.startForegroundService(serviceIntent);
|
||||
// }
|
||||
//
|
||||
// }
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.animation.LinearInterpolator;
|
||||
|
||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
|
||||
import com.blankj.utilcode.util.ActivityUtils;
|
||||
import com.blankj.utilcode.util.LogUtils;
|
||||
import com.blankj.utilcode.util.ToastUtils;
|
||||
import com.chad.library.adapter.base.BaseQuickAdapter;
|
||||
@@ -338,7 +339,7 @@ public class RoomKtvFragment extends BaseMvpFragment<RoomPresenter, FragmentRoom
|
||||
mu_rank.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(mu_rank)) {
|
||||
return;
|
||||
}
|
||||
RoomKtvWheatView roomDefaultWheatView = (RoomKtvWheatView) v;
|
||||
@@ -349,7 +350,7 @@ public class RoomKtvFragment extends BaseMvpFragment<RoomPresenter, FragmentRoom
|
||||
|
||||
@Override
|
||||
public void onCharmClick(RoomKtvWheatView view, RoomPitBean pitBean) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(mu_rank)) {
|
||||
return;
|
||||
}
|
||||
if (pitBean.getUser_id() != null && !pitBean.getUser_id().isEmpty() && !pitBean.getUser_id().equals("0")) {
|
||||
@@ -366,7 +367,7 @@ public class RoomKtvFragment extends BaseMvpFragment<RoomPresenter, FragmentRoom
|
||||
muYc.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(muYc)) {
|
||||
return;
|
||||
}
|
||||
if (!muYc.getUserId().equals("")) {
|
||||
@@ -377,7 +378,7 @@ public class RoomKtvFragment extends BaseMvpFragment<RoomPresenter, FragmentRoom
|
||||
muYc.setmOnCharmClickListener(new RoomKtvWheatView.onCharmClickListener() {
|
||||
@Override
|
||||
public void onCharmClick(RoomKtvWheatView view, RoomPitBean pitBean) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(muYc)) {
|
||||
return;
|
||||
}
|
||||
if (pitBean.getUser_id() != null && !pitBean.getUser_id().isEmpty() && !pitBean.getUser_id().equals("0")) {
|
||||
@@ -390,7 +391,7 @@ public class RoomKtvFragment extends BaseMvpFragment<RoomPresenter, FragmentRoom
|
||||
muZc.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(muZc)) {
|
||||
return;
|
||||
}
|
||||
if (!muZc.getUserId().equals("")) {
|
||||
@@ -403,7 +404,7 @@ public class RoomKtvFragment extends BaseMvpFragment<RoomPresenter, FragmentRoom
|
||||
muYc.setmOnCharmClickListener(new RoomKtvWheatView.onCharmClickListener() {
|
||||
@Override
|
||||
public void onCharmClick(RoomKtvWheatView view, RoomPitBean pitBean) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(muZc)) {
|
||||
return;
|
||||
}
|
||||
if (pitBean.getUser_id() != null && !pitBean.getUser_id().isEmpty() && !pitBean.getUser_id().equals("0")) {
|
||||
@@ -415,19 +416,30 @@ public class RoomKtvFragment extends BaseMvpFragment<RoomPresenter, FragmentRoom
|
||||
muJb.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(muJb)) {
|
||||
return;
|
||||
}
|
||||
if (!muJb.getUserId().equals("")) {
|
||||
RoomUserInfoFragment.show(roomInfoResp.getRoom_info().getRoom_id(), muJb.getUserId(), muJb.pitNumber, getHostUser(), false, 2, isNumberWhether(), getChildFragmentManager());
|
||||
} else {
|
||||
RoomOnlineDialogFragment.show(roomInfoResp.getRoom_info().getRoom_id(), "10", roomInfoResp.getUser_info(), roomInfoResp, getChildFragmentManager());
|
||||
if (ActivityUtils.getTopActivity() instanceof RoomActivity){
|
||||
if (((RoomActivity) ActivityUtils.getTopActivity()).getHostUser() < 4){
|
||||
if (ClickUtils.isFastDoubleClick(v)) {
|
||||
return;
|
||||
}
|
||||
RoomOnlineDialogFragment.show(roomInfoResp.getRoom_info().getRoom_id(), "10", roomInfoResp.getUser_info(), roomInfoResp, getChildFragmentManager());
|
||||
}else {
|
||||
com.hjq.toast.ToastUtils.show("请等待主持抱麦");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
muJb.setmOnCharmClickListener((view, pitBean) -> {
|
||||
if (ClickUtils.isFastDoubleClick()) {
|
||||
if (ClickUtils.isFastDoubleClick(muJb)) {
|
||||
return;
|
||||
}
|
||||
if (pitBean.getUser_id() != null && !pitBean.getUser_id().isEmpty() && !pitBean.getUser_id().equals("0")) {
|
||||
|
||||
@@ -29,8 +29,10 @@ import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.constraintlayout.widget.ConstraintLayout;
|
||||
|
||||
import com.blankj.utilcode.util.ActivityUtils;
|
||||
import com.blankj.utilcode.util.LogUtils;
|
||||
import com.blankj.utilcode.util.ObjectUtils;
|
||||
import com.blankj.utilcode.util.ToastUtils;
|
||||
import com.google.android.flexbox.FlexboxLayout;
|
||||
import com.xscm.modulemain.R;
|
||||
import com.xscm.modulemain.activity.room.activity.RoomActivity;
|
||||
@@ -59,6 +61,7 @@ import com.xscm.moduleutil.event.RoomWheatEvent;
|
||||
import com.xscm.moduleutil.listener.MessageListenerSingleton;
|
||||
import com.xscm.moduleutil.rtc.AgoraManager;
|
||||
import com.xscm.moduleutil.rtc.AgoraManagerEx;
|
||||
import com.xscm.moduleutil.utils.ClickUtils;
|
||||
import com.xscm.moduleutil.utils.GsonUtils;
|
||||
import com.xscm.moduleutil.utils.ImageUtils;
|
||||
import com.xscm.moduleutil.utils.SpUtil;
|
||||
@@ -150,6 +153,9 @@ public class SingSongFragment extends BaseRoomFragment<SingSongPresenter, Fragme
|
||||
|
||||
@Override
|
||||
public void onMeilingClick(@NonNull RoomSingSongWheatView view, int pitNumber) {
|
||||
if (ClickUtils.isFastDoubleClick(view)){
|
||||
return;
|
||||
}
|
||||
if (view.pitBean != null && !view.pitBean.getUser_id().isEmpty() && !view.pitBean.getUser_id().equals("0")) {
|
||||
RoomCharmDialog.newInstance(roomId, view.pitBean.getUser_id()).show(getChildFragmentManager(), "RoomCharmDialog");
|
||||
}
|
||||
@@ -162,13 +168,15 @@ public class SingSongFragment extends BaseRoomFragment<SingSongPresenter, Fragme
|
||||
|
||||
@Override
|
||||
public void onWheatClick(@NonNull RoomSingSongWheatView view, int pitNumber1) {
|
||||
|
||||
if (ClickUtils.isFastDoubleClick(view)){
|
||||
return;
|
||||
}
|
||||
|
||||
RoomPitBean pitBean = view.pitBean;
|
||||
// 可选:点击事件处理
|
||||
Log.d("Wheat", "Clicked pit: " + pitNumber1);
|
||||
if (!pitBean.getUser_id().equals("0") && !pitBean.getUser_id().isEmpty()) {
|
||||
if (isFastDoubleClick(pitBean.getUser_id(), pitBean.getPit_number())) {
|
||||
return; // 快速重复点击,直接返回
|
||||
}
|
||||
RoomUserInfoFragment.show(roomId, pitBean.getUser_id(), pitBean.getPit_number(), getHostUser(), false, 3, isNumberWhether(), getChildFragmentManager());
|
||||
} else {
|
||||
if (cheackWether(pitBean.getPit_number())) {
|
||||
@@ -176,9 +184,17 @@ public class SingSongFragment extends BaseRoomFragment<SingSongPresenter, Fragme
|
||||
roomPitBean = pitBean;
|
||||
showPopupMenu(view); // v 是点击的按钮视图
|
||||
} else if (pitNumber1 == 10) {
|
||||
if (!isFastDoubleClick("online_dialog", pitNumber1 + "")) {
|
||||
RoomOnlineDialogFragment.show(roomId, pitNumber1 + "", roomInfoResp.getUser_info(), roomInfoResp, getChildFragmentManager());
|
||||
if (ActivityUtils.getTopActivity() instanceof RoomActivity){
|
||||
if (((RoomActivity) ActivityUtils.getTopActivity()).getHostUser() < 4){
|
||||
if (!isFastDoubleClick("online_dialog", pitNumber1 + "")) {
|
||||
RoomOnlineDialogFragment.show(roomId, pitNumber1 + "", roomInfoResp.getUser_info(), roomInfoResp, getChildFragmentManager());
|
||||
}
|
||||
}else {
|
||||
com.hjq.toast.ToastUtils.show("请等待主持抱麦");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
} else {
|
||||
MvpPre.applyPit(roomId, pitNumber1 + "");
|
||||
}
|
||||
@@ -343,7 +359,9 @@ public class SingSongFragment extends BaseRoomFragment<SingSongPresenter, Fragme
|
||||
|
||||
private boolean cheackWether(String pitNumber) {
|
||||
if (roomInfoResp.getRoom_info().getRoom_up_pit_type().equals("1")) {//排麦模式
|
||||
if (roomInfoResp.getUser_info().getIs_management() == 1 || roomInfoResp.getUser_info().getIs_host() == 1 || roomInfoResp.getUser_info().getIs_room_owner() == 1) {
|
||||
if (roomInfoResp.getUser_info().getIs_management() == 1
|
||||
|| roomInfoResp.getUser_info().getIs_host() == 1
|
||||
|| roomInfoResp.getUser_info().getIs_room_owner() == 1) {
|
||||
if (pitNumber.equals("9")) {
|
||||
return false;
|
||||
}
|
||||
@@ -1454,10 +1472,6 @@ public class SingSongFragment extends BaseRoomFragment<SingSongPresenter, Fragme
|
||||
mBinding.flexboxLayout2.removeAllViews();
|
||||
}
|
||||
}
|
||||
|
||||
if (MvpPre != null) {
|
||||
MvpPre.detachView();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -20,11 +20,13 @@ import androidx.fragment.app.FragmentActivity;
|
||||
import androidx.viewpager2.adapter.FragmentStateAdapter;
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.blankj.utilcode.util.ActivityUtils;
|
||||
import com.blankj.utilcode.util.ToastUtils;
|
||||
import com.google.android.material.tabs.TabLayout;
|
||||
import com.google.android.material.tabs.TabLayoutMediator;
|
||||
import com.stx.xhb.xbanner.XBanner;
|
||||
import com.xscm.modulemain.R;
|
||||
import com.xscm.modulemain.activity.main.activity.MainActivity;
|
||||
import com.xscm.modulemain.activity.msg.OfficialNoticeActivity;
|
||||
import com.xscm.modulemain.activity.room.activity.PopularRoomActivity;
|
||||
import com.xscm.modulemain.activity.room.activity.RankingListActivity;
|
||||
@@ -79,9 +81,6 @@ public class VoiceCategoryFragment extends BaseMvpFragment<VoiceCategoryPresente
|
||||
return new VoiceCategoryFragment(voiceFragment);
|
||||
}
|
||||
|
||||
public void showLoading() {
|
||||
voiceFragment.isShowLoading(true);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
@Override
|
||||
@@ -147,7 +146,9 @@ public class VoiceCategoryFragment extends BaseMvpFragment<VoiceCategoryPresente
|
||||
carouselBannerAdapter.setOnItemClickListener((view, data, position) -> {
|
||||
// 示例:跳转到房间 详情页
|
||||
if (data != null) {
|
||||
showLoading();
|
||||
if (ActivityUtils.getTopActivity() instanceof MainActivity){
|
||||
((MainActivity) ActivityUtils.getTopActivity()).isShowLoading(true);
|
||||
}
|
||||
RoomManager.getInstance().fetchRoomDataAndEnter(getActivity(), data.getRoom_id(), "", null);
|
||||
}
|
||||
});
|
||||
@@ -170,7 +171,9 @@ public class VoiceCategoryFragment extends BaseMvpFragment<VoiceCategoryPresente
|
||||
if (item != null) { // 再次检查 item 是否为 null
|
||||
String roomId = item.getRoom_id(); // 或者 item.getRoomId(); 确保方法名正确
|
||||
if (roomId != null && !roomId.isEmpty()) { // 检查 roomId 是否有效
|
||||
showLoading();
|
||||
if (ActivityUtils.getTopActivity() instanceof MainActivity){
|
||||
((MainActivity) ActivityUtils.getTopActivity()).isShowLoading(true);
|
||||
}
|
||||
RoomManager.getInstance().fetchRoomDataAndEnter(getActivity(), roomId, "", null);
|
||||
} else {
|
||||
// Log.d(TAG, "Room ID is null or empty for item at position: " + position);
|
||||
|
||||
@@ -52,23 +52,6 @@ public class VoiceFragment extends BaseMvpFragment<VoicePresenter, FragmentVoice
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onPause() {
|
||||
super.onPause();
|
||||
isShowLoading(false);
|
||||
}
|
||||
|
||||
@SuppressLint("CheckResult")
|
||||
public void isShowLoading(boolean isShowLoading){
|
||||
if (isShowLoading) {
|
||||
mBinding.coolWaitView.setVisibility(View.VISIBLE);
|
||||
} else {
|
||||
Observable.timer(5, TimeUnit.MILLISECONDS).observeOn(AndroidSchedulers.mainThread()).subscribe(aLong -> {
|
||||
mBinding.coolWaitView.setVisibility(View.GONE);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void initView () {
|
||||
|
||||
|
||||
@@ -56,14 +56,8 @@ public class RoomPresenter extends BasePresenter<RoomContacts.View> implements R
|
||||
}
|
||||
LogUtils.e("token",token);
|
||||
LogUtils.e("roomId:",roomId);
|
||||
|
||||
if (getView()!= null && getView().getSelfActivity()!=null){
|
||||
AgoraManager.getInstance()
|
||||
.joinRoom(token, roomId, uid, enableMic,enableJs);
|
||||
}else {
|
||||
AgoraManager.getInstance()
|
||||
.joinRoom(token, roomId, uid, enableMic,enableJs);
|
||||
}
|
||||
AgoraManager.getInstance()
|
||||
.joinRoom(token, roomId, uid, enableMic,enableJs);
|
||||
if (MvpRef==null){
|
||||
MvpRef=new WeakReference<>(mView);
|
||||
}
|
||||
|
||||
@@ -44,6 +44,7 @@ public class NobleDetailsActivity extends BaseMvpActivity<NobleTitlePresenter, A
|
||||
GridNobleAdapter mGiftWallAdapter;
|
||||
|
||||
private String lid="";
|
||||
private String xlid="";
|
||||
|
||||
@Override
|
||||
protected void initView() {
|
||||
@@ -61,7 +62,7 @@ public class NobleDetailsActivity extends BaseMvpActivity<NobleTitlePresenter, A
|
||||
mBinding.imLjkt.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(this, NoblePaymentActivity.class);
|
||||
Bundle bundle = new Bundle();
|
||||
bundle.putString("lid",lid);
|
||||
bundle.putString("lid",xlid);
|
||||
intent.putExtras( bundle);
|
||||
startActivity(intent);
|
||||
});
|
||||
@@ -166,10 +167,14 @@ public class NobleDetailsActivity extends BaseMvpActivity<NobleTitlePresenter, A
|
||||
// 观察数据变化并更新 GridView
|
||||
mGiftWallAdapter.updateData(nobilitLists.getPower().getList());
|
||||
if (position>=index){
|
||||
if (position==index){
|
||||
mBinding.imLjkt.setImageResource(com.xscm.moduleutil.R.mipmap.noble_xf);
|
||||
if (!lid.isEmpty()) {
|
||||
if (position == index) {
|
||||
mBinding.imLjkt.setImageResource(com.xscm.moduleutil.R.mipmap.noble_xf);
|
||||
} else {
|
||||
mBinding.imLjkt.setImageResource(com.xscm.moduleutil.R.mipmap.noble_ljsj);
|
||||
}
|
||||
}else {
|
||||
mBinding.imLjkt.setImageResource(com.xscm.moduleutil.R.mipmap.noble_ljsj);
|
||||
mBinding.imLjkt.setImageResource(com.xscm.moduleutil.R.mipmap.noble_ljkt);
|
||||
}
|
||||
mBinding.imLjkt.setClickable( true);
|
||||
}else {
|
||||
|
||||
@@ -26,14 +26,19 @@ import com.xscm.moduleutil.base.CommonAppContext;
|
||||
import com.xscm.moduleutil.bean.UserInfo;
|
||||
import com.xscm.moduleutil.dialog.RealNameDialog;
|
||||
import com.xscm.moduleutil.utils.ARouteConstants;
|
||||
import com.xscm.moduleutil.utils.Md5Utils;
|
||||
import com.xscm.moduleutil.utils.SpUtil;
|
||||
import com.xscm.moduleutil.utils.TimeUtils;
|
||||
import com.xscm.moduleutil.utils.config.ConfigManager;
|
||||
import com.xscm.moduleutil.utils.config.EnvironmentEnum;
|
||||
import com.xscm.moduleutil.utils.config.EnvironmentPrefs;
|
||||
import com.xscm.moduleutil.utils.cos.CosUploadManager;
|
||||
import com.xscm.moduleutil.widget.CommonAppConfig;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.Objects;
|
||||
import java.util.Set;
|
||||
import java.util.UUID;
|
||||
|
||||
import io.reactivex.Observable;
|
||||
import io.reactivex.ObservableEmitter;
|
||||
@@ -101,6 +106,7 @@ public class SettingActivity extends BaseMvpActivity<SettingPresenter, ActivityS
|
||||
mBinding.llGywm.setOnClickListener(this::onClick);
|
||||
mBinding.llBbh.setOnClickListener(this::onClick);
|
||||
mBinding.tvShare.setOnClickListener(this::onClick);
|
||||
mBinding.llSendLog.setOnClickListener(this::onClick);
|
||||
}
|
||||
|
||||
@SuppressLint("CheckResult")
|
||||
@@ -229,7 +235,9 @@ public class SettingActivity extends BaseMvpActivity<SettingPresenter, ActivityS
|
||||
handler.postDelayed(resetRunnable, RESET_DELAY);
|
||||
}
|
||||
}
|
||||
} else if (view.getId() == R.id.tv_share) {
|
||||
}else if (view.getId() == R.id.ll_send_log){
|
||||
MvpPre.sendAppLog();
|
||||
}else if (view.getId() == R.id.tv_share) {
|
||||
showLoading("正在生成分享文件...");
|
||||
Observable.create(new ObservableOnSubscribe<Boolean>() {
|
||||
@SuppressLint("CheckResult")
|
||||
|
||||
@@ -17,5 +17,7 @@ public class SettingConacts {
|
||||
void cancel();
|
||||
|
||||
void getModifyHideStatus(String hide_status);
|
||||
|
||||
void sendAppLog();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -119,7 +119,14 @@ public class UserHomepageFragment extends BaseMvpFragment<UserHomepagePresenter,
|
||||
mBinding.headerInfo.tvUserId.setText(sex+" | ID:"+userInfo.getUser_code());
|
||||
|
||||
mBinding.headerInfo.tvNickName.setText(userInfo.getNickname());
|
||||
mBinding.headerInfo.tvNickName.setTextColor( (userInfo.getNickname_color()!=null && !userInfo.getNickname_color().equals(""))?Color.parseColor(userInfo.getNickname_color()):Color.parseColor("#333333"));
|
||||
if (!userInfo.getNickname_color().isEmpty()){
|
||||
mBinding.headerInfo.tvNickName.setStartColor(Color.parseColor(userInfo.getNickname_color()));
|
||||
mBinding.headerInfo.tvNickName.setShineColor(Color.parseColor(userInfo.getNickname_color()));
|
||||
mBinding.headerInfo.tvNickName.setEndColor(Color.parseColor(userInfo.getNickname_color()));
|
||||
mBinding.headerInfo.tvNickName.setShine(true);
|
||||
mBinding.headerInfo.tvNickName.setShineType(0);
|
||||
}
|
||||
// mBinding.headerInfo.tvNickName.setTextColor( (userInfo.getNickname_color()!=null && !userInfo.getNickname_color().equals(""))?Color.parseColor(userInfo.getNickname_color()):Color.parseColor("#333333"));
|
||||
// mBinding.headerInfo.tvUserId.setText(userInfo.getUser_code());
|
||||
mBinding.headerInfo.tvAge.setText(userInfo.getAge() + "岁");
|
||||
mBinding.headerInfo.tvJj.setText(userInfo.getProfile());
|
||||
|
||||
@@ -37,6 +37,7 @@ import com.xscm.modulemain.activity.user.activity.UserHomepageActivity;
|
||||
import com.xscm.modulemain.activity.user.conacts.MeConacts;
|
||||
import com.xscm.modulemain.activity.user.presenter.MePresenter;
|
||||
import com.xscm.modulemain.activity.WebViewActivity;
|
||||
import com.xscm.moduleutil.widget.ShineTextView;
|
||||
import com.xscm.moduleutil.base.BaseMvpFragment;
|
||||
import com.xscm.moduleutil.base.CommonAppContext;
|
||||
import com.xscm.moduleutil.bean.BannerModel;
|
||||
@@ -145,6 +146,8 @@ public class VocalRangeFragment extends BaseMvpFragment<MePresenter, FragmentVoc
|
||||
// ARouter.getInstance().build(ARouteConstants.H5).withString("url", bannerModel.getUrl()).withString("title", "首页横幅").navigation();
|
||||
}
|
||||
});
|
||||
ShineTextView tvNickName = mBinding.tvNickName;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -312,7 +315,17 @@ public class VocalRangeFragment extends BaseMvpFragment<MePresenter, FragmentVoc
|
||||
this.userInfo = data;
|
||||
mBinding.rivUserHead.setData(data.getAvatar(), data.getDress(),data.getNobility_image());
|
||||
mBinding.tvNickName.setText(data.getNickname());
|
||||
mBinding.tvNickName.setTextColor( (data.getNickname_color()!=null&& !data.getNickname_color().equals(""))? Color.parseColor(data.getNickname_color()): Color.parseColor("#ffffff"));
|
||||
|
||||
|
||||
if (!data.getNickname_color().isEmpty()){
|
||||
mBinding.tvNickName.setStartColor(Color.parseColor(data.getNickname_color()));
|
||||
mBinding.tvNickName.setShineColor(Color.parseColor(data.getNickname_color()));
|
||||
mBinding.tvNickName.setEndColor(Color.parseColor(data.getNickname_color()));
|
||||
mBinding.tvNickName.setShine(true);
|
||||
mBinding.tvNickName.setShineType(0);
|
||||
}
|
||||
|
||||
// mBinding.tvNickName.setTextColor( (data.getNickname_color()!=null&& !data.getNickname_color().equals(""))? Color.parseColor(data.getNickname_color()): Color.parseColor("#ffffff"));
|
||||
String sex = data.getSex()==1?"男":"女";
|
||||
mBinding.beautifulView.setText(sex+" | ID:"+data.getUser_code());
|
||||
mBinding.tvFollow.setText(data.getFollow_num()+"");
|
||||
|
||||
@@ -48,7 +48,7 @@ public class AlbumDetailPresenter extends BasePresenter<AlbumDetailConacts.View>
|
||||
|
||||
@Override
|
||||
public void uploadFile(File file, int type, int index, int size) {
|
||||
MvpRef.get().showLoadings("上传中...");
|
||||
// MvpRef.get().showLoadings("上传中...");
|
||||
String url = OSSOperUtils.getPath(file, type);
|
||||
CosUploadManager.getInstance(CommonAppContext.getInstance()).upParameters(url,file.getPath(), new CosUploadManager.UploadCallback() {
|
||||
@Override
|
||||
|
||||
@@ -30,7 +30,7 @@ public class EditUserPresenter extends BasePresenter<EditUserConactos.View> impl
|
||||
|
||||
@Override
|
||||
public void uploadFile(File file, int type, int index, int size) {
|
||||
MvpRef.get().showLoadings("上传中...");
|
||||
// MvpRef.get().showLoadings("上传中...");
|
||||
String url = OSSOperUtils.getPath(file, type);
|
||||
CosUploadManager.getInstance(CommonAppContext.getInstance()).upParameters(url,file.getPath(), new CosUploadManager.UploadCallback() {
|
||||
@Override
|
||||
@@ -105,6 +105,9 @@ public class EditUserPresenter extends BasePresenter<EditUserConactos.View> impl
|
||||
|
||||
@Override
|
||||
public void onNext(String s) {
|
||||
if (MvpRef==null){
|
||||
MvpRef=new WeakReference<>(mView);
|
||||
}
|
||||
MvpRef.get().editUserInfoSuccess(s);
|
||||
}
|
||||
});
|
||||
@@ -120,6 +123,9 @@ public class EditUserPresenter extends BasePresenter<EditUserConactos.View> impl
|
||||
|
||||
@Override
|
||||
public void onNext(String s) {
|
||||
if (MvpRef==null){
|
||||
MvpRef=new WeakReference<>(mView);
|
||||
}
|
||||
MvpRef.get().editUserInfoSuccess(s);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -3,6 +3,7 @@ package com.xscm.modulemain.activity.user.presenter;
|
||||
import android.content.Context;
|
||||
|
||||
import com.hjq.toast.ToastUtils;
|
||||
import com.xscm.modulemain.activity.plaza.contacts.CircleContacts;
|
||||
import com.xscm.modulemain.activity.user.conacts.MyAlbumConacts;
|
||||
import com.xscm.moduleutil.base.CommonAppContext;
|
||||
import com.xscm.moduleutil.bean.AlbumBean;
|
||||
@@ -12,13 +13,17 @@ import com.xscm.moduleutil.utils.cos.CosUploadManager;
|
||||
import com.xscm.moduleutil.utils.oss.OSSOperUtils;
|
||||
|
||||
import java.io.File;
|
||||
import java.lang.ref.WeakReference;
|
||||
import java.util.List;
|
||||
|
||||
import io.reactivex.disposables.Disposable;
|
||||
|
||||
public class MyAlbumPresenter extends BasePresenter<MyAlbumConacts.View> implements MyAlbumConacts.IMePre {
|
||||
MyAlbumConacts.View mView;
|
||||
|
||||
public MyAlbumPresenter(MyAlbumConacts.View view, Context context) {
|
||||
super(view, context);
|
||||
this.mView = view;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -31,6 +36,9 @@ public class MyAlbumPresenter extends BasePresenter<MyAlbumConacts.View> impleme
|
||||
|
||||
@Override
|
||||
public void onNext(List<AlbumBean> albumBeans) {
|
||||
if (MvpRef==null){
|
||||
MvpRef=new WeakReference<>(mView);
|
||||
}
|
||||
MvpRef.get().getAlbumList(albumBeans);
|
||||
}
|
||||
});
|
||||
@@ -54,7 +62,7 @@ public class MyAlbumPresenter extends BasePresenter<MyAlbumConacts.View> impleme
|
||||
|
||||
@Override
|
||||
public void uploadFile(File file, int type) {
|
||||
MvpRef.get().showLoadings("上传中...");
|
||||
// MvpRef.get().showLoadings("上传中...");
|
||||
String url = OSSOperUtils.getPath(file, type);
|
||||
CosUploadManager.getInstance(CommonAppContext.getInstance()).upParameters(url,file.getPath(), new CosUploadManager.UploadCallback() {
|
||||
@Override
|
||||
|
||||
@@ -1,16 +1,35 @@
|
||||
package com.xscm.modulemain.activity.user.presenter;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
|
||||
import com.blankj.utilcode.util.FileUtils;
|
||||
import com.blankj.utilcode.util.LogUtils;
|
||||
import com.blankj.utilcode.util.ToastUtils;
|
||||
import com.blankj.utilcode.util.ZipUtils;
|
||||
import com.xscm.modulemain.Application;
|
||||
import com.xscm.modulemain.activity.user.activity.SettingActivity;
|
||||
import com.xscm.modulemain.activity.user.conacts.SettingConacts;
|
||||
import com.xscm.moduleutil.http.BaseObserver;
|
||||
import com.xscm.moduleutil.presenter.BasePresenter;
|
||||
import com.xscm.moduleutil.utils.SpUtil;
|
||||
import com.xscm.moduleutil.utils.TimeUtils;
|
||||
import com.xscm.moduleutil.utils.cos.CosUploadManager;
|
||||
import com.xscm.moduleutil.utils.oss.OSSOperUtils;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.io.File;
|
||||
import java.lang.ref.WeakReference;
|
||||
import java.util.UUID;
|
||||
|
||||
import io.reactivex.Observable;
|
||||
import io.reactivex.ObservableEmitter;
|
||||
import io.reactivex.ObservableOnSubscribe;
|
||||
import io.reactivex.android.schedulers.AndroidSchedulers;
|
||||
import io.reactivex.disposables.Disposable;
|
||||
import io.reactivex.functions.Consumer;
|
||||
import io.reactivex.schedulers.Schedulers;
|
||||
|
||||
public class SettingPresenter extends BasePresenter<SettingConacts.View> implements SettingConacts.IMePre {
|
||||
private SettingConacts.View mView;
|
||||
@@ -69,4 +88,84 @@ public class SettingPresenter extends BasePresenter<SettingConacts.View> impleme
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@SuppressLint("CheckResult")
|
||||
@Override
|
||||
public void sendAppLog() {
|
||||
MvpRef.get().showLoadings("正在上传...");
|
||||
Observable.create(new ObservableOnSubscribe<String>() {
|
||||
@SuppressLint("CheckResult")
|
||||
@Override
|
||||
public void subscribe(ObservableEmitter<String> emitter) throws Exception {
|
||||
try {
|
||||
File file = new File(Application.Companion.getInstance().getAppContent());
|
||||
|
||||
if (FileUtils.isFileExists(file.getParent() +"/DataInfo.zip")){
|
||||
FileUtils.delete(file.getParent() +"/DataInfo.zip");
|
||||
}
|
||||
boolean isZip = ZipUtils.zipFile(Application.Companion.getInstance().getAppContent(),
|
||||
file.getParent() +"/DataInfo.zip");
|
||||
if (isZip) {
|
||||
emitter.onNext(file.getParent() + "/DataInfo.zip");
|
||||
}else {
|
||||
emitter.onNext("");
|
||||
}
|
||||
}catch (Exception e){
|
||||
LogUtils.e("压缩失败",e.toString());
|
||||
emitter.onNext("");
|
||||
}
|
||||
}
|
||||
}).subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread()).subscribe(new Consumer<String>() {
|
||||
@SuppressLint("CheckResult")
|
||||
@Override
|
||||
public void accept(String zipPath) {
|
||||
String upLogUrl = OSSOperUtils.getAppLogPath(new File(zipPath));
|
||||
if(!zipPath.isEmpty()){
|
||||
CosUploadManager.getInstance(Application.getInstance()).upParameters(upLogUrl,zipPath, new CosUploadManager.UploadCallback(){
|
||||
|
||||
@Override
|
||||
public void onSuccess(String url) {
|
||||
if (MvpRef==null){
|
||||
MvpRef=new WeakReference<>(mView);
|
||||
}
|
||||
api.sendAppLog(upLogUrl,url, new BaseObserver<String>() {
|
||||
|
||||
|
||||
@Override
|
||||
public void onSubscribe(Disposable d) {
|
||||
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void onNext(String s) {
|
||||
MvpRef.get().disLoadings();
|
||||
ToastUtils.showShort(s);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFailure(Exception e) {
|
||||
ToastUtils.showLong("上传失败");
|
||||
LogUtils.e("上传失败",e.toString());
|
||||
MvpRef.get().disLoadings();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFailure1(IllegalStateException e) {
|
||||
ToastUtils.showLong("上传失败");
|
||||
LogUtils.e("上传失败",e.toString());
|
||||
MvpRef.get().disLoadings();
|
||||
}
|
||||
});
|
||||
}else {
|
||||
ToastUtils.showLong("上传失败");
|
||||
LogUtils.e("压缩失败");
|
||||
MvpRef.get().disLoadings();
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,11 +15,13 @@ import android.text.style.ForegroundColorSpan;
|
||||
import android.view.View;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.constraintlayout.widget.ConstraintLayout;
|
||||
|
||||
import com.blankj.utilcode.util.LogUtils;
|
||||
import com.bumptech.glide.Glide;
|
||||
import com.bumptech.glide.load.DataSource;
|
||||
import com.bumptech.glide.load.engine.GlideException;
|
||||
@@ -29,19 +31,18 @@ import com.bumptech.glide.request.target.Target;
|
||||
import com.bumptech.glide.request.transition.Transition;
|
||||
import com.chad.library.adapter.base.BaseMultiItemQuickAdapter;
|
||||
import com.chad.library.adapter.base.BaseViewHolder;
|
||||
import com.xscm.modulemain.R;
|
||||
import com.xscm.modulemain.FakeNinePatchDrawable;
|
||||
import com.xscm.modulemain.R;
|
||||
import com.xscm.moduleutil.bean.GiftBean;
|
||||
import com.xscm.moduleutil.bean.RoomMessageEvent;
|
||||
import com.xscm.moduleutil.bean.UserInfo;
|
||||
import com.xscm.moduleutil.bean.room.EMMessageInfo;
|
||||
import com.xscm.moduleutil.bean.room.EmotionDeatils;
|
||||
import com.xscm.moduleutil.utils.ImageUtils;
|
||||
import com.xscm.moduleutil.utils.MeHeadView;
|
||||
import com.xscm.moduleutil.utils.logger.Logger;
|
||||
import com.xscm.moduleutil.widget.AdaptiveImageView;
|
||||
import com.xscm.moduleutil.widget.GifAvatarOvalView;
|
||||
import com.xscm.moduleutil.widget.ShineTextView;
|
||||
import com.xscm.moduleutil.widget.img.BubbleBackgroundHelper;
|
||||
import com.xscm.moduleutil.bean.room.EmotionDeatils;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
@@ -73,7 +74,6 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
addItemType(1, com.xscm.moduleutil.R.layout.ease_row_received_message_system);//系统消息、官方公告
|
||||
addItemType(2, com.xscm.moduleutil.R.layout.ease_row_received_message_user_send);//用户发送的消息
|
||||
addItemType(3, com.xscm.moduleutil.R.layout.ease_row_received_message_system);//加入房间 、赠送礼物、上下麦、禁言 2025年6月12日15:42:08,让和聊天显示的是同一个额布局,后面需要修改
|
||||
// addItemType(3, com.qxcm.moduleutil.R.layout.ease_row_received_message_join_room);//加入房间 、赠送礼物、上下麦、禁言
|
||||
addItemType(4, com.xscm.moduleutil.R.layout.ease_row_received_message_new_user);//新用户注册
|
||||
addItemType(5, com.xscm.moduleutil.R.layout.ease_row_received_message_wagging);//摇签
|
||||
addItemType(6, com.xscm.moduleutil.R.layout.ease_row_received_message_expression);//表情
|
||||
@@ -199,10 +199,10 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
|
||||
switch (helper.getItemViewType()) {
|
||||
case 1:
|
||||
helper.getView(R.id.tv_content).setVisibility(View.VISIBLE);
|
||||
helper.setText(R.id.tv_content, getSpannable(emMessage));
|
||||
helper.getView(com.xscm.moduleutil.R.id.tv_content).setVisibility(View.VISIBLE);
|
||||
helper.setText(com.xscm.moduleutil.R.id.tv_content, getSpannable(emMessage));
|
||||
|
||||
// helper.setText(R.id.tv_content, emMessage.getText().getText());
|
||||
// helper.setText(com.xscm.moduleutil.R.id.tv_content, emMessage.getText().getText());
|
||||
// tv_content.setTextColor(ColorManager.getInstance().getPrimaryColorInt());
|
||||
break;
|
||||
case 2:
|
||||
@@ -215,8 +215,18 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
MeHeadView avatar = helper.getView(com.xscm.moduleutil.R.id.avatar);
|
||||
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));
|
||||
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"));
|
||||
ShineTextView tvName = helper.getView(com.xscm.moduleutil.R.id.tv_name);
|
||||
tvName.setText(emMessage.getText().getFromUserInfo().getNickname());
|
||||
|
||||
if (!emMessage.getText().getFromUserInfo().getNickname_color().isEmpty()) {
|
||||
tvName.setStartColor(Color.parseColor(emMessage.getText().getFromUserInfo().getNickname_color()));
|
||||
tvName.setShineColor(Color.parseColor(emMessage.getText().getFromUserInfo().getNickname_color()));
|
||||
tvName.setEndColor(Color.parseColor(emMessage.getText().getFromUserInfo().getNickname_color()));
|
||||
tvName.setShine(true);
|
||||
tvName.setShineType(0);
|
||||
}
|
||||
|
||||
// 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) {
|
||||
helper.setText(com.xscm.moduleutil.R.id.tv_content, getSpannable(emMessage));
|
||||
}
|
||||
@@ -335,7 +345,7 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
break;
|
||||
case 3:
|
||||
// if (emMessage.getText().getFromUserInfo().getChat_bubble() != null && !emMessage.getText().getFromUserInfo().getChat_bubble().isEmpty()) {
|
||||
//// helper.getView(com.xscm.moduleutil.R.id.bubble).setBackgroundResource(com.xscm.moduleutil.R.mipmap.qipaokang);
|
||||
//// helper.getView(com.xscm.moduleutil.R.id.bubble).setBackgroundResource(R.mipmap.qipaokang);
|
||||
//// ImageUtils.loadHeadCC(emMessage.getText().getFromUserInfo().getChat_bubble(), helper.getView(com.xscm.moduleutil.R.id.network_background));
|
||||
//
|
||||
// // 使用 Glide 加载图片并设置名称
|
||||
@@ -363,15 +373,15 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
// }
|
||||
// });
|
||||
// } else {
|
||||
// helper.getView(com.xscm.moduleutil.R.id.bubble1).setBackgroundResource(com.xscm.moduleutil.R.drawable.ease_row_pubilc_user_bg);
|
||||
// helper.getView(com.xscm.moduleutil.R.id.bubble1).setBackgroundResource(R.drawable.ease_row_pubilc_user_bg);
|
||||
// }
|
||||
// if (emMessage.getText().getFromUserInfo() != null && emMessage.getText().getFromUserInfo().getAvatar() != null) {
|
||||
// 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_content, emMessage.getText().getText());
|
||||
helper.getView(R.id.tv_content).setVisibility(View.VISIBLE);
|
||||
helper.setText(R.id.tv_content, getSpannable(emMessage));
|
||||
helper.getView(com.xscm.moduleutil.R.id.tv_content).setVisibility(View.VISIBLE);
|
||||
helper.setText(com.xscm.moduleutil.R.id.tv_content, getSpannable(emMessage));
|
||||
// List<String> images1 = emMessage.getText().getFromUserInfo().getIcon();
|
||||
// LinearLayout ll_images1 = helper.getView(com.xscm.moduleutil.R.id.line);
|
||||
// ll_images1.removeAllViews();
|
||||
@@ -382,10 +392,10 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
// if (url.contains("http")) {
|
||||
// ImageView imageView = new ImageView(helper.itemView.getContext());
|
||||
// LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(
|
||||
// helper.itemView.getContext().getResources().getDimensionPixelSize(com.xscm.moduleutil.R.dimen.dp_57),
|
||||
// helper.itemView.getContext().getResources().getDimensionPixelSize(com.xscm.moduleutil.R.dimen.dp_15)
|
||||
// helper.itemView.getContext().getResources().getDimensionPixelSize(R.dimen.dp_57),
|
||||
// helper.itemView.getContext().getResources().getDimensionPixelSize(R.dimen.dp_15)
|
||||
// );
|
||||
// params.setMargins(0, 0, helper.itemView.getContext().getResources().getDimensionPixelSize(com.xscm.moduleutil.R.dimen.dp_5), 0); // 右边距
|
||||
// params.setMargins(0, 0, helper.itemView.getContext().getResources().getDimensionPixelSize(R.dimen.dp_5), 0); // 右边距
|
||||
// imageView.setLayoutParams(params);
|
||||
// imageView.setScaleType(ImageView.ScaleType.CENTER_CROP);
|
||||
// // 使用 Glide 加载图片
|
||||
@@ -396,21 +406,21 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
|
||||
break;
|
||||
// case 4:
|
||||
// TextView tvContent7 = helper.getView(R.id.tv_content);
|
||||
// ivNew = helper.getView(R.id.new_view);
|
||||
// TextView tvContent7 = helper.getView(com.xscm.moduleutil.R.id.tv_content);
|
||||
// ivNew = helper.getView(com.xscm.moduleutil.R.id.new_view);
|
||||
// ivNew.setNew(1);
|
||||
// tvContent7.setText(new SpanUtils().append(spanned).create());
|
||||
// break;
|
||||
// //抽签
|
||||
// case 5:
|
||||
// String number = emMessage.getStringAttribute("number", "");
|
||||
// ivRole = helper.getView(R.id.iv_role);
|
||||
// ivNew = helper.getView(R.id.iv_new);
|
||||
// ivGrade = helper.getView(R.id.iv_grade);
|
||||
// ivTitle = helper.getView(R.id.iv_title_label);
|
||||
// ivNHobility = helper.getView(R.id.iv_nobility);
|
||||
// tvName = helper.getView(R.id.tv_name);
|
||||
// TextView tvContent5 = helper.getView(R.id.tv_content);
|
||||
// ivRole = helper.getView(com.xscm.moduleutil.R.id.iv_role);
|
||||
// ivNew = helper.getView(com.xscm.moduleutil.R.id.iv_new);
|
||||
// ivGrade = helper.getView(com.xscm.moduleutil.R.id.iv_grade);
|
||||
// ivTitle = helper.getView(com.xscm.moduleutil.R.id.iv_title_label);
|
||||
// ivNHobility = helper.getView(com.xscm.moduleutil.R.id.iv_nobility);
|
||||
// tvName = helper.getView(com.xscm.moduleutil.R.id.tv_name);
|
||||
// TextView tvContent5 = helper.getView(com.xscm.moduleutil.R.id.tv_content);
|
||||
// ivRole.setRole(Integer.parseInt(role));
|
||||
// ivNew.setNew(Integer.parseInt(userIsNew));
|
||||
// ivGrade.setGrade(rankIcon);
|
||||
@@ -428,14 +438,14 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
// }
|
||||
// ivTitle.setLabelView(user_title);
|
||||
// ivNHobility.setNobility(nobilityIcon);
|
||||
// ImageUtils.loadIcon(charmIcon, helper.getView(R.id.iv_charm));
|
||||
// ImageUtils.loadIcon(charmIcon, helper.getView(com.xscm.moduleutil.R.id.iv_charm));
|
||||
// tvName.setText(String.format("%s:", nickname));
|
||||
// tvContent5.setText(new SpanUtils().append(spanned).create());
|
||||
// GlideApp.with(mContext).load(String.format("http://soundriver.oss-cn-hangzhou.aliyuncs.com/custom/random%ss.webp", number)).into(new SimpleTarget<Drawable>() {
|
||||
// @Override
|
||||
// public void onResourceReady(@NonNull Drawable drawable, @Nullable Transition<? super Drawable> transition) {
|
||||
// if (drawable instanceof WebpDrawable) {
|
||||
// AppCompatImageView imageView = helper.getView(R.id.iv_wagginh);
|
||||
// AppCompatImageView imageView = helper.getView(com.xscm.moduleutil.R.id.iv_wagginh);
|
||||
// imageView.setImageDrawable(drawable);
|
||||
// ((WebpDrawable) drawable).start();
|
||||
// ((WebpDrawable) drawable).setLoopCount(1);
|
||||
@@ -443,7 +453,7 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
// @Override
|
||||
// public void onAnimationEnd(Drawable drawable) {
|
||||
// super.onAnimationEnd(drawable);
|
||||
// helper.setImageResource(R.id.iv_wagginh, a[Integer.parseInt(number)]);
|
||||
// helper.setImageResource(com.xscm.moduleutil.R.id.iv_wagginh, a[Integer.parseInt(number)]);
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
@@ -452,20 +462,20 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
// break;
|
||||
// //表情
|
||||
// case 6:
|
||||
// ivRole = helper.getView(R.id.iv_role);
|
||||
// ivNew = helper.getView(R.id.iv_new);
|
||||
// ivGrade = helper.getView(R.id.iv_grade);
|
||||
// ivTitle = helper.getView(R.id.iv_title_label);
|
||||
// ivNHobility = helper.getView(R.id.iv_nobility);
|
||||
// tvName = helper.getView(R.id.tv_name);
|
||||
// ivRole = helper.getView(com.xscm.moduleutil.R.id.iv_role);
|
||||
// ivNew = helper.getView(com.xscm.moduleutil.R.id.iv_new);
|
||||
// ivGrade = helper.getView(com.xscm.moduleutil.R.id.iv_grade);
|
||||
// ivTitle = helper.getView(com.xscm.moduleutil.R.id.iv_title_label);
|
||||
// ivNHobility = helper.getView(com.xscm.moduleutil.R.id.iv_nobility);
|
||||
// tvName = helper.getView(com.xscm.moduleutil.R.id.tv_name);
|
||||
// ivRole.setRole(Integer.parseInt(role));
|
||||
// ivNew.setNew(Integer.parseInt(userIsNew));
|
||||
// ivGrade.setGrade(rankIcon);
|
||||
// ivTitle.setLabelView(user_title);
|
||||
// ivNHobility.setNobility(nobilityIcon);
|
||||
// tvName.setText(Html.fromHtml(nickname));
|
||||
// ImageUtils.loadIcon(charmIcon, helper.getView(R.id.iv_charm));
|
||||
// ImageLoader.loadIcon(mContext, helper.getView(R.id.iv_expression), emoji_special);
|
||||
// ImageUtils.loadIcon(charmIcon, helper.getView(com.xscm.moduleutil.R.id.iv_charm));
|
||||
// ImageLoader.loadIcon(mContext, helper.getView(com.xscm.moduleutil.R.id.iv_expression), emoji_special);
|
||||
//
|
||||
// //称号图标
|
||||
// try {
|
||||
@@ -486,44 +496,44 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
// String second = emMessage.getStringAttribute("second", "");
|
||||
// String third = emMessage.getStringAttribute("third", "");
|
||||
//
|
||||
// ivRole = helper.getView(R.id.iv_role);
|
||||
// ivNew = helper.getView(R.id.iv_new);
|
||||
// ivGrade = helper.getView(R.id.iv_grade);
|
||||
// ivTitle = helper.getView(R.id.iv_title_label);
|
||||
// ivNHobility = helper.getView(R.id.iv_nobility);
|
||||
// tvName = helper.getView(R.id.tv_name);
|
||||
// TextView tvContent8 = helper.getView(R.id.tv_content);
|
||||
// ivRole = helper.getView(com.xscm.moduleutil.R.id.iv_role);
|
||||
// ivNew = helper.getView(com.xscm.moduleutil.R.id.iv_new);
|
||||
// ivGrade = helper.getView(com.xscm.moduleutil.R.id.iv_grade);
|
||||
// ivTitle = helper.getView(com.xscm.moduleutil.R.id.iv_title_label);
|
||||
// ivNHobility = helper.getView(com.xscm.moduleutil.R.id.iv_nobility);
|
||||
// tvName = helper.getView(com.xscm.moduleutil.R.id.tv_name);
|
||||
// TextView tvContent8 = helper.getView(com.xscm.moduleutil.R.id.tv_content);
|
||||
//
|
||||
// ivRole.setRole(Integer.parseInt(role));
|
||||
// ivNew.setNew(Integer.parseInt(userIsNew));
|
||||
// ivGrade.setGrade(rankIcon);
|
||||
// ivTitle.setLabelView(user_title);
|
||||
// ivNHobility.setNobility(nobilityIcon);
|
||||
// ImageUtils.loadIcon(charmIcon, helper.getView(R.id.iv_charm));
|
||||
// ImageUtils.loadIcon(charmIcon, helper.getView(com.xscm.moduleutil.R.id.iv_charm));
|
||||
// tvName.setText(Html.fromHtml(nickname));
|
||||
// if (emMessage.getIntAttribute("type", 0) == 6019) {//亮球
|
||||
// helper.setVisible(R.id.iv_qiu1, true);
|
||||
// helper.setVisible(R.id.iv_qiu2, true);
|
||||
// helper.setVisible(R.id.iv_qiu3, true);
|
||||
// helper.setVisible(com.xscm.moduleutil.R.id.iv_qiu1, true);
|
||||
// helper.setVisible(com.xscm.moduleutil.R.id.iv_qiu2, true);
|
||||
// helper.setVisible(com.xscm.moduleutil.R.id.iv_qiu3, true);
|
||||
//
|
||||
// try {
|
||||
// helper.setImageResource(R.id.iv_qiu1, mContext.getResources().getIdentifier(first, "mipmap", mContext.getPackageName()));
|
||||
// helper.setImageResource(R.id.iv_qiu2, mContext.getResources().getIdentifier(second, "mipmap", mContext.getPackageName()));
|
||||
// helper.setImageResource(R.id.iv_qiu3, mContext.getResources().getIdentifier(third, "mipmap", mContext.getPackageName()));
|
||||
// helper.setImageResource(com.xscm.moduleutil.R.id.iv_qiu1, mContext.getResources().getIdentifier(first, "mipmap", mContext.getPackageName()));
|
||||
// helper.setImageResource(com.xscm.moduleutil.R.id.iv_qiu2, mContext.getResources().getIdentifier(second, "mipmap", mContext.getPackageName()));
|
||||
// helper.setImageResource(com.xscm.moduleutil.R.id.iv_qiu3, mContext.getResources().getIdentifier(third, "mipmap", mContext.getPackageName()));
|
||||
// } catch (Exception e) {
|
||||
// e.printStackTrace();
|
||||
// }
|
||||
//
|
||||
// } else {
|
||||
// helper.setVisible(R.id.iv_qiu1, false);
|
||||
// helper.setVisible(R.id.iv_qiu2, false);
|
||||
// helper.setVisible(R.id.iv_qiu3, false);
|
||||
// helper.setVisible(com.xscm.moduleutil.R.id.iv_qiu1, false);
|
||||
// helper.setVisible(com.xscm.moduleutil.R.id.iv_qiu2, false);
|
||||
// helper.setVisible(com.xscm.moduleutil.R.id.iv_qiu3, false);
|
||||
// }
|
||||
// spanUtils.append(spanned);
|
||||
// tvContent8.setText(spanUtils.create());
|
||||
// break;
|
||||
// case 10:
|
||||
// TextView tv = helper.getView(R.id.tv_content);
|
||||
// TextView tv = helper.getView(com.xscm.moduleutil.R.id.tv_content);
|
||||
// float height = tv.getTextSize();//获取字体高度
|
||||
// String bell = "<img src=\"" + R.drawable.ease_message_bell + "\"/>"; //前面加一个铃铛
|
||||
// Spanned sp = Html.fromHtml(bell + txtBody.getMessage(), source -> {
|
||||
@@ -533,10 +543,10 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
// return drawable;
|
||||
// }, null);
|
||||
// tv.setText(sp);
|
||||
// helper.setGone(R.id.tv_red_rain_detail, false);
|
||||
// helper.setGone(com.xscm.moduleutil.R.id.tv_red_rain_detail, false);
|
||||
// break;
|
||||
// case 11:
|
||||
// TextView tv11 = helper.getView(R.id.tv_content);
|
||||
// TextView tv11 = helper.getView(com.xscm.moduleutil.R.id.tv_content);
|
||||
// float height11 = tv11.getTextSize();//获取字体高度
|
||||
// String bell11 = "<img src=\"" + R.drawable.ease_message_bell + "\"/>"; //前面加一个铃铛
|
||||
// Spanned sp11 = Html.fromHtml(bell11 + txtBody.getMessage(), source -> {
|
||||
@@ -546,11 +556,11 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
// return drawable;
|
||||
// }, null);
|
||||
// tv11.setText(sp11);
|
||||
// helper.setGone(R.id.tv_red_rain_detail, true);
|
||||
// helper.addOnClickListener(R.id.tv_red_rain_detail);
|
||||
// helper.setGone(com.xscm.moduleutil.R.id.tv_red_rain_detail, true);
|
||||
// helper.addOnClickListener(com.xscm.moduleutil.R.id.tv_red_rain_detail);
|
||||
// break;
|
||||
// default:
|
||||
// helper.setText(R.id.tv_content, Html.fromHtml(txtBody.getMessage()));
|
||||
// helper.setText(com.xscm.moduleutil.R.id.tv_content, Html.fromHtml(txtBody.getMessage()));
|
||||
// break;
|
||||
}
|
||||
|
||||
@@ -590,7 +600,7 @@ public class EaseChatAdapter extends BaseMultiItemQuickAdapter<EMMessageInfo, Ba
|
||||
|
||||
@Override
|
||||
public void onViewRecycled(@NonNull BaseViewHolder holder) {
|
||||
Logger.e("onViewRecycled", "onViewRecycled");
|
||||
LogUtils.e("onViewRecycled", "onViewRecycled");
|
||||
// AdaptiveImageView imEmj = (AdaptiveImageView)holder.getView(com.xscm.moduleutil.R.id.im_emj);
|
||||
MeHeadView avatarOvalView = holder.getView(com.xscm.moduleutil.R.id.avatar);
|
||||
ImageView ivNobility = holder.getView(com.xscm.moduleutil.R.id.iv_nobility);
|
||||
|
||||
@@ -14,6 +14,7 @@ import com.xscm.moduleutil.utils.ImageUtils;
|
||||
import com.xscm.moduleutil.utils.MeHeadView;
|
||||
import com.xscm.moduleutil.utils.SpUtil;
|
||||
import com.xscm.moduleutil.widget.MyGridView;
|
||||
import com.xscm.moduleutil.widget.ShineTextView;
|
||||
import com.xscm.moduleutil.widget.img.FullScreenUtil;
|
||||
|
||||
import java.util.List;
|
||||
@@ -53,8 +54,16 @@ public class ExpandColumnAdapter extends BaseQuickAdapter<ExpandColumnBean, Base
|
||||
helper.getView(R.id.dy_image_recyc).setVisibility(View.VISIBLE);
|
||||
helper.setText(R.id.tv_agree,(item.getAgree()!=null?item.getAgree():"0")+"岁");
|
||||
//昵称
|
||||
helper.setText(R.id.dy_name_text, item.getNickname());
|
||||
helper.setTextColor(R.id.dy_name_text,(item.getNickname_color()!=null && !item.getNickname_color().isEmpty())? Color.parseColor(item.getNickname_color()):Color.parseColor("#333333"));
|
||||
helper.setText(com.xscm.moduleutil.R.id.dy_name_text, item.getNickname());
|
||||
ShineTextView tvName = helper.getView(com.xscm.moduleutil.R.id.dy_name_text);
|
||||
if (!item.getNickname_color().isEmpty()) {
|
||||
tvName.setStartColor(Color.parseColor(item.getNickname_color()));
|
||||
tvName.setShineColor(Color.parseColor(item.getNickname_color()));
|
||||
tvName.setEndColor(Color.parseColor(item.getNickname_color()));
|
||||
tvName.setShine(true);
|
||||
tvName.setShineType(0);
|
||||
}
|
||||
// helper.setTextColor(R.id.dy_name_text,(item.getNickname_color()!=null && !item.getNickname_color().isEmpty())? Color.parseColor(item.getNickname_color()):Color.parseColor("#333333"));
|
||||
helper.setText(R.id.tv_address, item.getLoginip());
|
||||
if (item.getUser_id().equals(SpUtil.getUserId()+"")){
|
||||
helper.setVisible(R.id.gensui, false);
|
||||
|
||||
@@ -48,7 +48,7 @@ public class HotAdapter extends BaseMultiItemQuickAdapter<TopRoom, BaseViewHolde
|
||||
iv.setVisibility(GONE);
|
||||
}
|
||||
helper.setText(R.id.tv_num, formatHotValue(Integer.parseInt(item.getHot_value())));
|
||||
ImageUtils.loadHeadCC(item.getLabel_icon(), helper.getView(R.id.iv_type));
|
||||
ImageUtils.loadRoomItem(item.getLabel_icon(), helper.getView(R.id.iv_type));
|
||||
|
||||
helper.itemView.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
|
||||
@@ -15,6 +15,7 @@ import com.xscm.moduleutil.bean.CharmRankingResp;
|
||||
import com.xscm.moduleutil.utils.ImageUtils;
|
||||
import com.xscm.moduleutil.utils.StringUtil;
|
||||
import com.xscm.moduleutil.utils.logger.Logger;
|
||||
import com.xscm.moduleutil.widget.ShineTextView;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -37,6 +38,16 @@ public class RankingCharmListAdapter extends BaseQuickAdapter<CharmRankingResp,
|
||||
//数据绑定赋值
|
||||
helper.setText(R.id.room_item_seq, String.valueOf(helper.getAdapterPosition() + 4));//从第四个开始设置值
|
||||
helper.setText(R.id.room_item_name, item.getNickname());
|
||||
ShineTextView shineTextView = helper.getView(R.id.room_item_name);
|
||||
// if (!item.getNickname_color().isEmpty()){
|
||||
// shineTextView.setStartColor(Color.parseColor(item.getNickname_color()));
|
||||
// shineTextView.setShineColor(Color.parseColor(item.getNickname_color()));
|
||||
// shineTextView.setEndColor(Color.parseColor(item.getNickname_color()));
|
||||
// shineTextView.setShine(true);
|
||||
// shineTextView.setShineType(0);
|
||||
// }
|
||||
|
||||
|
||||
helper.setText(R.id.room_item_pop, StringUtil.toWan2(item.getTotal(),2));
|
||||
// if (GG.equals(item.getSex())) {
|
||||
// helper.setBackgroundRes(R.id.room_item_pop, R.mipmap.room_bg_wheat_charm_gg_sr);
|
||||
|
||||
@@ -3,6 +3,7 @@ package com.xscm.modulemain.adapter;
|
||||
import static android.view.View.GONE;
|
||||
import static android.view.View.VISIBLE;
|
||||
|
||||
import android.graphics.Color;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.TextView;
|
||||
@@ -13,6 +14,8 @@ import com.xscm.modulemain.R;
|
||||
import com.xscm.moduleutil.bean.room.RoomOnlineBean;
|
||||
import com.xscm.moduleutil.utils.ColorManager;
|
||||
import com.xscm.moduleutil.utils.ImageUtils;
|
||||
import com.xscm.moduleutil.utils.MeHeadView;
|
||||
import com.xscm.moduleutil.widget.ShineTextView;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -53,8 +56,23 @@ public class RoomOnlineAdapter extends BaseMultiItemQuickAdapter<RoomOnlineBean,
|
||||
if (item.getItemType() == 1) {
|
||||
helper.setText(R.id.maishang, item.getTypeNames());
|
||||
} else if (item.getItemType() == 2) {
|
||||
ImageUtils.loadHeadCC(item.getAvatar(), helper.getView(R.id.like_avatar));
|
||||
// ImageUtils.loadHeadCC(item.getAvatar(), helper.getView(R.id.like_avatar));
|
||||
|
||||
MeHeadView headView = helper.getView(R.id.like_avatar);
|
||||
headView.setData(item.getAvatar(), "", ""/*item.getNobility_image()*/);
|
||||
helper.setText(R.id.tv_nickname, item.getNickname());
|
||||
|
||||
// ShineTextView tvName = helper.getView(R.id.tv_nickname);
|
||||
// if (!item.getNickname_color().isEmpty()) {
|
||||
// tvName.setStartColor(Color.parseColor(item.getNickname_color()));
|
||||
// tvName.setShineColor(Color.parseColor(item.getNickname_color()));
|
||||
// tvName.setEndColor(Color.parseColor(item.getNickname_color()));
|
||||
// tvName.setShine(true);
|
||||
// tvName.setShineType(0);
|
||||
// }
|
||||
//
|
||||
|
||||
|
||||
ImageView imageView = helper.getView(R.id.im_i);
|
||||
TextView textView = helper.getView(R.id.tv_status);
|
||||
imageView.setVisibility(VISIBLE);
|
||||
|
||||
@@ -15,11 +15,11 @@ import com.xscm.modulemain.activity.room.contacts.HourlyChartContacts;
|
||||
import com.xscm.modulemain.activity.room.presenter.HourlyChartPresenter;
|
||||
import com.xscm.modulemain.adapter.RoomHourlyAdapter;
|
||||
import com.xscm.modulemain.databinding.DialogHourlyChartFragmentBinding;
|
||||
import com.xscm.modulemain.manager.RoomManager;
|
||||
import com.xscm.moduleutil.base.BaseMvpDialogFragment;
|
||||
import com.xscm.moduleutil.base.CommonAppContext;
|
||||
import com.xscm.moduleutil.bean.room.RoomHourBean;
|
||||
|
||||
import org.greenrobot.eventbus.EventBus;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.util.ArrayList;
|
||||
@@ -129,7 +129,8 @@ public class HourlyChartDialog extends BaseMvpDialogFragment<HourlyChartPresente
|
||||
|
||||
@Override
|
||||
public void onItemClick(RoomHourBean.RoomListBean item, int position) {
|
||||
RoomManager.getInstance().fetchRoomDataAndEnter(getActivity(), item.getRoom_id(),"",null);
|
||||
// RoomManager.getInstance().fetchRoomDataAndEnter(getActivity(), item.getRoom_id(),"",null);
|
||||
EventBus.getDefault().post(item);
|
||||
dismiss();
|
||||
}
|
||||
});
|
||||
|
||||
@@ -10,6 +10,7 @@ import android.graphics.Color;
|
||||
import android.os.Bundle;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.fragment.app.FragmentManager;
|
||||
|
||||
import android.view.Gravity;
|
||||
@@ -105,6 +106,12 @@ public class RoomUserInfoFragment extends BaseMvpDialogFragment<RoomUserPresente
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceState) {
|
||||
super.onViewCreated(view, savedInstanceState);
|
||||
MvpPre.getRoomUserInfo(room_id, user_id);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void initDialogStyle(Window window) {
|
||||
super.initDialogStyle(window);
|
||||
@@ -123,7 +130,6 @@ public class RoomUserInfoFragment extends BaseMvpDialogFragment<RoomUserPresente
|
||||
|
||||
@Override
|
||||
protected void initData() {
|
||||
MvpPre.getRoomUserInfo(room_id, user_id);
|
||||
if (type == 0) {
|
||||
mBinding.roomDian.setVisibility(GONE);
|
||||
} else {
|
||||
@@ -381,7 +387,16 @@ public class RoomUserInfoFragment extends BaseMvpDialogFragment<RoomUserPresente
|
||||
String sex = userInfo.getSex()==1?"男":"女";
|
||||
mBinding.tvId.setText(sex+" | ID:"+userInfo.getUser_code());
|
||||
mBinding.tvName.setText(userInfo.getNickname());
|
||||
mBinding.tvName.setTextColor( (userInfo.getNickname_color()!=null && !userInfo.getNickname_color().equals(""))? Color.parseColor(userInfo.getNickname_color()):Color.parseColor("#333333"));
|
||||
|
||||
if (!userInfo.getNickname_color().isEmpty()){
|
||||
mBinding.tvName.setStartColor(Color.parseColor(userInfo.getNickname_color()));
|
||||
mBinding.tvName.setShineColor(Color.parseColor(userInfo.getNickname_color()));
|
||||
mBinding.tvName.setEndColor(Color.parseColor(userInfo.getNickname_color()));
|
||||
mBinding.tvName.setShine(true);
|
||||
mBinding.tvName.setShineType(0);
|
||||
}
|
||||
|
||||
// mBinding.tvName.setTextColor( (userInfo.getNickname_color()!=null && !userInfo.getNickname_color().equals(""))? Color.parseColor(userInfo.getNickname_color()):Color.parseColor("#333333"));
|
||||
// mBinding.tvId.setText("ID:" + userInfo.getUser_code());
|
||||
if (userInfo.getIs_in_pit() == 1) {
|
||||
mBinding.roomMCz.setText("下麦");
|
||||
|
||||
@@ -9,9 +9,12 @@ import android.util.Log;
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.blankj.utilcode.util.ActivityUtils;
|
||||
import com.blankj.utilcode.util.FragmentUtils;
|
||||
import com.blankj.utilcode.util.LogUtils;
|
||||
import com.blankj.utilcode.util.ToastUtils;
|
||||
import com.xscm.modulemain.activity.main.activity.MainActivity;
|
||||
import com.xscm.modulemain.activity.room.activity.RoomActivity;
|
||||
import com.xscm.modulemain.activity.user.activity.MyRoomActivity;
|
||||
import com.xscm.moduleutil.base.CommonAppContext;
|
||||
import com.xscm.moduleutil.bean.room.RoomInfoResp;
|
||||
import com.xscm.moduleutil.bean.room.RoomOnline;
|
||||
@@ -151,6 +154,12 @@ public class RoomManager {
|
||||
.joinRoom(token, roomId, uid, enableMic, enableJs);
|
||||
cacheRoomData(roomId, resp);
|
||||
navigateToRoom(context, roomId, password, resp, false, taskId);
|
||||
}else {
|
||||
if (ActivityUtils.getTopActivity() instanceof MainActivity){
|
||||
((MainActivity) ActivityUtils.getTopActivity()).isShowLoading(false);
|
||||
}else if (ActivityUtils.getTopActivity() instanceof MyRoomActivity){
|
||||
((MyRoomActivity) ActivityUtils.getTopActivity()).isShowLoading(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,193 +1,181 @@
|
||||
<?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"
|
||||
tools:context=".activity.NobleTitleActivity">
|
||||
<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"
|
||||
tools:context=".activity.NobleTitleActivity">
|
||||
|
||||
<data>
|
||||
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@mipmap/noble_bj">
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@mipmap/noble_bj">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/top_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
android:id="@+id/top_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="45dp"
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_back"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:contentDescription="@null"
|
||||
android:scaleType="centerInside"
|
||||
android:src="@mipmap/ic_topbar_back_dark"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintDimensionRatio="1:1"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
/>
|
||||
android:id="@+id/iv_back"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:contentDescription="@null"
|
||||
android:scaleType="centerInside"
|
||||
android:src="@mipmap/ic_topbar_back_dark"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintDimensionRatio="1:1"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/tv_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@mipmap/icon_noble_title"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
/>
|
||||
android:id="@+id/tv_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@mipmap/icon_noble_title"
|
||||
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_intent"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
android:src="@mipmap/icon_noble_gz"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
/>
|
||||
android:id="@+id/iv_intent"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
android:src="@mipmap/icon_noble_gz"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<com.xscm.moduleutil.widget.CircularImage
|
||||
android:id="@+id/ci_user_image"
|
||||
android:layout_width="@dimen/dp_30"
|
||||
android:layout_height="@dimen/dp_30"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
android:layout_marginStart="@dimen/dp_16"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/top_bar"
|
||||
tools:src="@mipmap/ic_launcher_foreground"
|
||||
/>
|
||||
android:id="@+id/ci_user_image"
|
||||
android:layout_width="@dimen/dp_30"
|
||||
android:layout_height="@dimen/dp_30"
|
||||
android:layout_marginStart="@dimen/dp_16"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/top_bar"
|
||||
tools:src="@mipmap/ic_launcher_foreground" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_user_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_6"
|
||||
app:layout_constraintTop_toTopOf="@+id/ci_user_image"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/ci_user_image"
|
||||
app:layout_constraintStart_toEndOf="@+id/ci_user_image"
|
||||
tools:text="用户名"
|
||||
android:textColor="#F5E9D1"
|
||||
android:textSize="@dimen/sp_12"
|
||||
/>
|
||||
android:id="@+id/tv_user_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_6"
|
||||
android:textColor="#F5E9D1"
|
||||
android:textSize="@dimen/sp_12"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/ci_user_image"
|
||||
app:layout_constraintStart_toEndOf="@+id/ci_user_image"
|
||||
app:layout_constraintTop_toTopOf="@+id/ci_user_image"
|
||||
tools:text="用户名" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_user_lv"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintStart_toEndOf="@+id/tv_user_name"
|
||||
app:layout_constraintTop_toTopOf="@+id/tv_user_name"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_user_name"
|
||||
tools:text="Lv.1"
|
||||
android:textColor="#F5E9D1"
|
||||
android:textSize="@dimen/sp_12"
|
||||
/>
|
||||
android:id="@+id/tv_user_lv"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="#F5E9D1"
|
||||
android:textSize="@dimen/sp_12"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_user_name"
|
||||
app:layout_constraintStart_toEndOf="@+id/tv_user_name"
|
||||
app:layout_constraintTop_toTopOf="@+id/tv_user_name"
|
||||
tools:text="Lv.1" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/im_me_noble"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_94"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
android:layout_marginEnd="@dimen/dp_15"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ci_user_image"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:src="@mipmap/me_noble_bj"
|
||||
android:scaleType="fitXY"
|
||||
/>
|
||||
android:id="@+id/im_me_noble"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_94"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
android:layout_marginEnd="@dimen/dp_15"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@mipmap/me_noble_bj"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ci_user_image" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_me_noble_lv"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_44"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
app:layout_constraintStart_toStartOf="@+id/im_me_noble"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_me_noble"
|
||||
tools:text="Lv.1"
|
||||
android:fontFamily="@font/youshebiaotihei"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible"
|
||||
android:textSize="@dimen/sp_34"
|
||||
/>
|
||||
android:id="@+id/tv_me_noble_lv"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_44"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
android:fontFamily="@font/youshebiaotihei"
|
||||
android:textSize="@dimen/sp_34"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintStart_toStartOf="@+id/im_me_noble"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_me_noble"
|
||||
tools:text="Lv.1"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/im_me_noble_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_36"
|
||||
android:layout_marginStart="@dimen/dp_13"
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
app:layout_constraintStart_toStartOf="@+id/im_me_noble"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_me_noble"
|
||||
android:scaleType="fitCenter"
|
||||
tools:src="@mipmap/me_noble_no"
|
||||
tools:visibility="gone"
|
||||
/>
|
||||
android:id="@+id/im_me_noble_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_36"
|
||||
android:layout_marginStart="@dimen/dp_13"
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
android:scaleType="fitCenter"
|
||||
app:layout_constraintStart_toStartOf="@+id/im_me_noble"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_me_noble"
|
||||
tools:src="@mipmap/me_noble_no"
|
||||
tools:visibility="gone" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/im_me_noble_xf"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
app:layout_constraintStart_toEndOf="@+id/tv_me_noble_lv"
|
||||
app:layout_constraintTop_toTopOf="@+id/tv_me_noble_lv"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_me_noble_lv"
|
||||
android:src="@mipmap/me_noble_xf"
|
||||
tools:visibility="visible"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
android:id="@+id/im_me_noble_xf"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
android:src="@mipmap/me_noble_xf"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_me_noble_lv"
|
||||
app:layout_constraintStart_toEndOf="@+id/tv_me_noble_lv"
|
||||
app:layout_constraintTop_toTopOf="@+id/tv_me_noble_lv"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_user_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_12"
|
||||
android:layout_marginBottom="@dimen/dp_12"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
app:layout_constraintStart_toStartOf="@+id/im_me_noble_status"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im_me_noble"
|
||||
tools:text="未开通"
|
||||
android:textColor="#F5E9D1"
|
||||
android:textSize="@dimen/sp_12"
|
||||
/>
|
||||
android:id="@+id/tv_user_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
android:layout_marginTop="@dimen/dp_12"
|
||||
android:layout_marginBottom="@dimen/dp_12"
|
||||
android:textColor="#F5E9D1"
|
||||
android:textSize="@dimen/sp_12"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im_me_noble"
|
||||
app:layout_constraintStart_toStartOf="@+id/im_me_noble_status"
|
||||
tools:text="未开通" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/im_noble_db"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
android:layout_marginEnd="@dimen/dp_15"
|
||||
app:layout_constraintTop_toBottomOf="@+id/im_me_noble"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:src="@mipmap/noble_duib"
|
||||
android:scaleType="fitCenter"/>
|
||||
android:id="@+id/im_noble_db"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
android:layout_marginEnd="@dimen/dp_15"
|
||||
android:scaleType="fitCenter"
|
||||
android:src="@mipmap/noble_duib"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/im_me_noble" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/im_noble"
|
||||
android:layout_width="@dimen/dp_104"
|
||||
android:layout_height="@dimen/dp_104"
|
||||
app:layout_constraintTop_toBottomOf="@+id/top_bar"
|
||||
app:layout_constraintEnd_toEndOf="@+id/im_me_noble"
|
||||
android:src="@mipmap/me_noble_image"
|
||||
android:scaleType="fitXY"
|
||||
android:layout_marginEnd="@dimen/dp_13"
|
||||
/>
|
||||
android:id="@+id/im_noble"
|
||||
android:layout_width="@dimen/dp_120"
|
||||
android:layout_height="@dimen/dp_120"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:layout_marginEnd="@dimen/dp_13"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@mipmap/me_noble_image"
|
||||
app:layout_constraintEnd_toEndOf="@+id/im_me_noble"
|
||||
app:layout_constraintTop_toBottomOf="@+id/top_bar" />
|
||||
|
||||
<!-- <androidx.cardview.widget.CardView-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
@@ -203,83 +191,78 @@
|
||||
<!-- >-->
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:background="@drawable/noble_card_border"
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
android:layout_marginStart="@dimen/dp_16"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
app:layout_constraintTop_toBottomOf="@+id/im_noble_db"
|
||||
app:layout_constraintBottom_toTopOf="@+id/im_kt"
|
||||
>
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginStart="@dimen/dp_16"
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
android:background="@drawable/noble_card_border"
|
||||
app:layout_constraintBottom_toTopOf="@+id/im_kt"
|
||||
app:layout_constraintTop_toBottomOf="@+id/im_noble_db">
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:orientation="vertical"
|
||||
android:id="@+id/contentView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_margin="@dimen/dp_12"
|
||||
android:background="@drawable/bg_r6_2a2a4e"
|
||||
/>
|
||||
android:id="@+id/contentView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_margin="@dimen/dp_12"
|
||||
android:background="@drawable/bg_r6_2a2a4e"
|
||||
android:orientation="vertical" />
|
||||
</FrameLayout>
|
||||
<!-- </androidx.cardview.widget.CardView>-->
|
||||
<ImageView
|
||||
android:id="@+id/im_kt"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:src="@mipmap/me_sj"
|
||||
android:scaleType="fitXY"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
tools:visibility="visible"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
|
||||
android:id="@+id/im_kt"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@mipmap/me_sj"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<com.xscm.moduleutil.widget.CircularImage
|
||||
android:id="@+id/ci_image2"
|
||||
android:layout_width="@dimen/dp_30"
|
||||
android:layout_height="@dimen/dp_30"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
app:layout_constraintStart_toStartOf="@+id/im_kt"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_kt"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im_kt"
|
||||
tools:src="@mipmap/ic_launcher"
|
||||
tools:visibility="visible"
|
||||
android:visibility="gone"/>
|
||||
android:id="@+id/ci_image2"
|
||||
android:layout_width="@dimen/dp_30"
|
||||
android:layout_height="@dimen/dp_30"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im_kt"
|
||||
app:layout_constraintStart_toStartOf="@+id/im_kt"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_kt"
|
||||
tools:src="@mipmap/ic_launcher"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_me_x"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_6"
|
||||
app:layout_constraintStart_toEndOf="@+id/ci_image2"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_kt"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im_kt"
|
||||
tools:text="夏沫..的当前爵位状态是骑"
|
||||
android:textColor="#F5E9D1"
|
||||
android:textSize="@dimen/sp_12"
|
||||
android:maxLines="1"
|
||||
android:ellipsize="end"
|
||||
android:singleLine="true"
|
||||
android:maxEms="12"
|
||||
tools:visibility="visible"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
android:id="@+id/tv_me_x"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_6"
|
||||
android:ellipsize="end"
|
||||
android:maxEms="12"
|
||||
android:maxLines="1"
|
||||
android:singleLine="true"
|
||||
android:textColor="#F5E9D1"
|
||||
android:textSize="@dimen/sp_12"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im_kt"
|
||||
app:layout_constraintStart_toEndOf="@+id/ci_image2"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_kt"
|
||||
tools:text="夏沫..的当前爵位状态是骑"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/im_sj"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_36"
|
||||
android:src="@mipmap/noble_sj"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_kt"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im_kt"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
tools:visibility="visible"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
android:id="@+id/im_sj"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_36"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
android:src="@mipmap/noble_sj"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im_kt"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/im_kt"
|
||||
tools:visibility="visible" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
|
||||
@@ -258,6 +258,26 @@
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0.5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:background="@color/color_FFE5E5E5" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_send_log"
|
||||
style="@style/My_Info_Item_LL_Style"
|
||||
android:background="@drawable/bg_r15_white">
|
||||
|
||||
<TextView
|
||||
style="@style/My_Info_Item_Title_Style"
|
||||
android:layout_width="0dp"
|
||||
android:layout_weight="1"
|
||||
android:text="上传报错信息" />
|
||||
|
||||
<ImageView style="@style/My_Info_Item_Arrow_Style" />
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0.5dp"
|
||||
@@ -300,6 +320,8 @@
|
||||
<ImageView style="@style/My_Info_Item_Arrow_Style" />
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0.5dp"
|
||||
@@ -386,6 +408,7 @@
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_share"
|
||||
android:visibility="gone"
|
||||
android:layout_gravity="start"
|
||||
android:padding="@dimen/dp_40"
|
||||
android:layout_marginTop="-50dp"
|
||||
|
||||
@@ -1,128 +0,0 @@
|
||||
<?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:id="@+id/bubble"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:minWidth="@dimen/dp_256"
|
||||
android:maxWidth="@dimen/dp_256"
|
||||
android:padding="@dimen/dp_8"
|
||||
android:background="@drawable/ease_row_pubilc_user_bg"
|
||||
>
|
||||
|
||||
<!-- 网络背景图片 -->
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/network_background"-->
|
||||
<!-- android:layout_width="0dp"-->
|
||||
<!-- android:layout_height="0dp"-->
|
||||
<!-- tools:src="@mipmap/a1img_9"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="parent"-->
|
||||
<!-- app:layout_constraintBottom_toBottomOf="parent"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="parent"-->
|
||||
<!-- app:layout_constraintEnd_toEndOf="parent"/>-->
|
||||
|
||||
<!-- 用户头像 -->
|
||||
<com.xscm.moduleutil.utils.MeHeadView
|
||||
android:id="@+id/avatar"
|
||||
android:layout_width="@dimen/dp_40"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="@dimen/dp_3"
|
||||
android:layout_marginTop="@dimen/dp_3"
|
||||
android:layout_marginBottom="@dimen/dp_3"
|
||||
android:layout_marginStart="@dimen/dp_8"
|
||||
app:riv_oval="true"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"/>
|
||||
|
||||
<!-- 用户名称 -->
|
||||
<TextView
|
||||
android:id="@+id/tv_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="#CCA882"
|
||||
android:textSize="@dimen/sp_12"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
tools:text="饶利"
|
||||
app:layout_constraintStart_toEndOf="@+id/avatar"
|
||||
app:layout_constraintTop_toTopOf="@+id/avatar"/>
|
||||
|
||||
<!-- 用户标签容器 -->
|
||||
<LinearLayout
|
||||
android:id="@+id/line"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
android:layout_marginTop="@dimen/dp_5"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintStart_toEndOf="@+id/avatar"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tv_name"/>
|
||||
|
||||
<!-- 消息内容 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="left|center_vertical"
|
||||
android:layout_marginStart="4dp"
|
||||
android:layout_marginTop="2dp"
|
||||
android:padding="@dimen/dp_3"
|
||||
android:paddingEnd="@dimen/dp_10"
|
||||
app:layout_constraintStart_toEndOf="@+id/avatar"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/line">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_content"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:lineHeight="@dimen/dp_20"
|
||||
android:lineSpacingExtra="@dimen/dp_2"
|
||||
android:paddingStart="@dimen/dp_8"
|
||||
android:paddingEnd="@dimen/dp_8"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_14"
|
||||
tools:text="饶利: 潇洒亼◇生2.0:"
|
||||
tools:visibility="gone"/>
|
||||
|
||||
<com.xscm.moduleutil.widget.AdaptiveImageView
|
||||
android:id="@+id/im_emj"
|
||||
android:layout_width="@dimen/dp_40"
|
||||
android:layout_height="@dimen/dp_40"
|
||||
android:layout_marginStart="@dimen/dp_2"
|
||||
|
||||
tools:src="@mipmap/ic_launcher"
|
||||
android:scaleType="fitXY"
|
||||
android:adjustViewBounds="true"
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible"/>
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/im_emj"-->
|
||||
<!-- android:layout_width="0dp"-->
|
||||
<!-- android:layout_height="0dp"-->
|
||||
<!-- android:layout_marginStart="@dimen/dp_2"-->
|
||||
<!-- android:paddingStart="@dimen/dp_8"-->
|
||||
<!-- android:paddingEnd="@dimen/dp_8"-->
|
||||
<!-- tools:src="@mipmap/ic_launcher"-->
|
||||
<!-- android:maxHeight="@dimen/dp_50"-->
|
||||
<!-- android:maxWidth="@dimen/dp_50"-->
|
||||
<!-- android:minWidth="@dimen/dp_40"-->
|
||||
<!-- android:minHeight="@dimen/dp_40"-->
|
||||
<!-- android:scaleType="centerCrop"-->
|
||||
<!-- android:adjustViewBounds="true"-->
|
||||
<!-- android:visibility="gone"-->
|
||||
<!-- tools:visibility="visible"-->
|
||||
|
||||
<!-- app:layout_constraintWidth_default="wrap"-->
|
||||
<!-- app:layout_constraintHeight_default="wrap"-->
|
||||
<!-- app:layout_constraintWidth_min="@dimen/dp_40"-->
|
||||
<!-- app:layout_constraintHeight_min="@dimen/dp_40"-->
|
||||
<!-- app:layout_constraintWidth_max="@dimen/dp_50"-->
|
||||
<!-- app:layout_constraintHeight_max="@dimen/dp_50"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="parent"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="parent"/>-->
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -24,7 +24,7 @@
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
android:id="@+id/tv_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -32,6 +32,7 @@
|
||||
android:text="用户名"
|
||||
android:textColor="#ffffff"
|
||||
android:textSize="@dimen/sp_14"
|
||||
app:isShine="false"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
@@ -96,9 +97,9 @@
|
||||
android:gravity="center"
|
||||
android:text="转币"
|
||||
android:textColor="@color/white"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
android:visibility="gone"/>
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/kb"
|
||||
@@ -132,8 +133,7 @@
|
||||
android:visibility="gone"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/im_qml"
|
||||
tools:visibility="visible"/>
|
||||
|
||||
tools:visibility="visible" />
|
||||
|
||||
|
||||
<ImageView
|
||||
@@ -145,9 +145,7 @@
|
||||
android:src="@mipmap/gsui"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/kb"
|
||||
/>
|
||||
|
||||
app:layout_constraintTop_toBottomOf="@+id/kb" />
|
||||
|
||||
|
||||
<TextView
|
||||
@@ -347,9 +345,9 @@
|
||||
android:layout_alignStart="@+id/user_nav1"
|
||||
android:layout_alignEnd="@+id/user_nav1"
|
||||
android:gravity="center"
|
||||
tools:text="用户昵称"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_10" />
|
||||
android:textSize="@dimen/sp_10"
|
||||
tools:text="用户昵称" />
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/rl_reqit"
|
||||
@@ -366,10 +364,10 @@
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
android:gravity="center"
|
||||
tools:text="开始使用"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_12"
|
||||
android:textStyle="bold" />
|
||||
android:textStyle="bold"
|
||||
tools:text="开始使用" />
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
@@ -402,13 +400,13 @@
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_marginTop="@dimen/dp_43"
|
||||
android:layout_marginEnd="@dimen/dp_22"
|
||||
android:background="@drawable/bg_r53_33333"
|
||||
android:gravity="center"
|
||||
android:paddingStart="5dp"
|
||||
android:paddingEnd="5dp"
|
||||
android:background="@drawable/bg_r53_33333"
|
||||
tools:text="5天"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_9" />
|
||||
android:textSize="@dimen/sp_9"
|
||||
tools:text="5天" />
|
||||
</RelativeLayout>
|
||||
|
||||
<com.google.android.flexbox.FlexboxLayout
|
||||
|
||||
@@ -7,12 +7,12 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:overScrollMode="never"
|
||||
android:background="@mipmap/home_bj"
|
||||
android:paddingBottom="@dimen/dp_60">
|
||||
android:background="@mipmap/home_bj">
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:paddingBottom="@dimen/dp_60"
|
||||
android:orientation="vertical">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
@@ -85,8 +85,20 @@
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:riv_oval="true"/>
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
android:id="@+id/tv_nick_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textSize="@dimen/sp_16"
|
||||
android:layout_marginTop="@dimen/dp_5"
|
||||
android:textColor="@color/white"
|
||||
app:isShine="false"
|
||||
app:layout_constraintStart_toEndOf="@+id/riv_user_head"
|
||||
app:layout_constraintTop_toTopOf="@+id/riv_user_head"
|
||||
android:layout_marginStart="@dimen/dp_14"
|
||||
tools:text="用户22333333"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="#fff"
|
||||
@@ -139,66 +151,6 @@
|
||||
app:layout_constraintStart_toStartOf="@+id/beautiful_view"
|
||||
/>
|
||||
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/lin"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="match_parent"-->
|
||||
<!-- android:orientation="vertical"-->
|
||||
<!-- android:layout_marginStart="@dimen/dp_14"-->
|
||||
<!-- app:layout_constraintStart_toEndOf="@+id/riv_user_head"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="@+id/riv_user_head">-->
|
||||
|
||||
<!-- <TextView-->
|
||||
<!-- android:id="@+id/tv_nick_name"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:textColor="#fff"-->
|
||||
<!-- android:textSize="@dimen/sp_16"-->
|
||||
<!-- tools:text="用户22333333" />-->
|
||||
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/beautiful_view_copy"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:layout_marginTop="7dp"-->
|
||||
<!-- android:gravity="center_vertical"-->
|
||||
<!-- android:orientation="horizontal">-->
|
||||
|
||||
<!-- <TextView-->
|
||||
<!-- android:id="@+id/beautiful_view"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:textColor="@color/color_FFFFFFE0"-->
|
||||
<!-- android:textSize="@dimen/sp_12"-->
|
||||
<!-- tools:text="22222" />-->
|
||||
|
||||
<!-- <TextView-->
|
||||
<!-- android:id="@+id/tv_copy"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:layout_marginLeft="5dp"-->
|
||||
<!-- android:background="@mipmap/copy"-->
|
||||
<!-- android:textColor="@color/color_666666"-->
|
||||
<!-- android:textSize="12sp" />-->
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/im_beautiful"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="@dimen/dp_11"-->
|
||||
<!-- android:layout_marginLeft="5dp"-->
|
||||
<!-- android:scaleType="fitCenter"-->
|
||||
<!-- tools:src="@mipmap/beautiful" />-->
|
||||
<!-- </LinearLayout>-->
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/ll_image_container"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:orientation="horizontal"-->
|
||||
<!-- android:layout_gravity="bottom"-->
|
||||
<!-- android:layout_marginTop="@dimen/dp_4"-->
|
||||
<!-- >-->
|
||||
<!-- </LinearLayout>-->
|
||||
<!-- </LinearLayout>-->
|
||||
<ImageView
|
||||
android:id="@+id/tv_home"
|
||||
android:layout_width="@dimen/dp_60"
|
||||
@@ -364,34 +316,6 @@
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<!-- <androidx.cardview.widget.CardView-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:layout_gravity="bottom"-->
|
||||
<!-- android:layout_marginLeft="@dimen/dp_12"-->
|
||||
<!-- android:layout_marginTop="-46dp"-->
|
||||
<!-- android:layout_marginRight="@dimen/dp_12"-->
|
||||
<!-- app:cardCornerRadius="10dp"-->
|
||||
<!-- app:layout_constraintBottom_toBottomOf="parent"-->
|
||||
<!-- app:layout_constraintTop_toBottomOf="@+id/me_linearlayout3"-->
|
||||
<!-- tools:layout_editor_absoluteX="13dp">-->
|
||||
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:gravity="center_vertical"-->
|
||||
<!-- android:layout_marginTop="-50dp"-->
|
||||
<!-- android:layout_marginStart="@dimen/dp_16"-->
|
||||
<!-- android:layout_marginEnd="@dimen/dp_16">-->
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/im_my_room"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="@dimen/dp_67"-->
|
||||
<!-- android:src="@mipmap/me_wallet_icon"/>-->
|
||||
|
||||
<!-- </LinearLayout>-->
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/cl_noble_title"
|
||||
android:layout_width="match_parent"
|
||||
|
||||
@@ -112,20 +112,5 @@
|
||||
android:background="@color/color_transparent"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/cool_wait_view"
|
||||
android:visibility="gone"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
<app.dinus.com.loadingdrawable.LoadingView
|
||||
android:layout_width="@dimen/dp_100"
|
||||
android:layout_height="@dimen/dp_100"
|
||||
android:layout_centerInParent="true"
|
||||
android:background="@drawable/ps_ic_shadow_bg"
|
||||
app:loading_renderer="CoolWaitLoadingRenderer" />
|
||||
</RelativeLayout>
|
||||
</RelativeLayout>
|
||||
</layout>
|
||||
@@ -46,11 +46,12 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
android:id="@+id/dy_name_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/color_FF333333"
|
||||
app:isShine="false"
|
||||
android:textStyle="bold"
|
||||
android:text="萌新驾到"
|
||||
android:textSize="18sp" />
|
||||
|
||||
@@ -2,14 +2,14 @@
|
||||
<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:id="@+id/item"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_50"
|
||||
android:layout_marginStart="@dimen/dp_16"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:layout_marginEnd="@dimen/dp_16">
|
||||
|
||||
<com.xscm.moduleutil.widget.GifAvatarOvalView
|
||||
<com.xscm.moduleutil.utils.MeHeadView
|
||||
android:id="@+id/like_avatar"
|
||||
android:layout_width="@dimen/dp_50"
|
||||
android:layout_height="@dimen/dp_50"
|
||||
@@ -17,17 +17,17 @@
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:riv_oval="true" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/im_i"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@mipmap/zc"
|
||||
app:layout_constraintStart_toStartOf="@+id/like_avatar"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/like_avatar"
|
||||
app:layout_constraintEnd_toEndOf="@+id/like_avatar"
|
||||
/>
|
||||
app:layout_constraintStart_toStartOf="@+id/like_avatar" />
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
android:id="@+id/tv_nickname"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_21"
|
||||
@@ -35,6 +35,7 @@
|
||||
android:text="用户名"
|
||||
android:textColor="@color/color_FF333333"
|
||||
android:textSize="@dimen/sp_12"
|
||||
app:isShine="false"
|
||||
app:layout_constraintStart_toEndOf="@+id/like_avatar"
|
||||
app:layout_constraintTop_toTopOf="@+id/like_avatar" />
|
||||
|
||||
|
||||
@@ -42,27 +42,14 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/tv_main_title" />
|
||||
|
||||
<!-- <LinearLayout-->
|
||||
<!-- android:id="@+id/video_container"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="160dp"-->
|
||||
<!-- android:layout_alignParentTop="true"-->
|
||||
<!-- android:orientation="horizontal"-->
|
||||
<!-- app:layout_constraintEnd_toEndOf="parent"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="parent"-->
|
||||
<!-- app:layout_constraintTop_toBottomOf="@+id/tv_main_title">-->
|
||||
|
||||
|
||||
<!-- </LinearLayout>-->
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/im"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@+id/iv_exit"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@mipmap/xiaohei_bj"
|
||||
android:scaleType="fitXY"/>
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/iv_exit" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/dating_time"
|
||||
@@ -86,11 +73,10 @@
|
||||
android:id="@+id/cl_2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/im"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/im"
|
||||
>
|
||||
app:layout_constraintTop_toTopOf="@+id/im">
|
||||
|
||||
|
||||
<com.xscm.moduleutil.widget.RoomMakeWheatView
|
||||
@@ -102,61 +88,26 @@
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:room_make_wheat_number="000" />
|
||||
|
||||
<!-- <com.qxcm.moduleutil.widget.GifAvatarOvalView-->
|
||||
<!-- android:id="@+id/riv_room"-->
|
||||
<!-- android:layout_width="@dimen/dp_60"-->
|
||||
<!-- android:layout_height="@dimen/dp_70"-->
|
||||
<!-- android:layout_marginStart="@dimen/dp_35"-->
|
||||
<!-- android:src="@mipmap/default_avatar"-->
|
||||
<!-- app:gav_border_color="#404F8591"-->
|
||||
<!-- app:gav_border_width="@dimen/dp_5"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="parent"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="parent"-->
|
||||
<!-- app:riv_border_color="#404F8591"-->
|
||||
<!-- app:riv_border_width="@dimen/dp_5"-->
|
||||
<!-- app:riv_oval="true"-->
|
||||
<!-- tools:src="@mipmap/default_avatar"/>-->
|
||||
|
||||
<!-- <TextView-->
|
||||
<!-- android:id="@+id/user_name"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:text="房间号"-->
|
||||
<!-- android:textColor="@color/white"-->
|
||||
<!-- android:textSize="14sp"-->
|
||||
<!-- app:layout_constraintEnd_toEndOf="@+id/riv_room"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="@+id/riv_room"-->
|
||||
<!-- app:layout_constraintTop_toBottomOf="@+id/riv_room" />-->
|
||||
|
||||
<FrameLayout
|
||||
<RelativeLayout
|
||||
android:id="@+id/fl_heart_value2"
|
||||
android:layout_width="@dimen/dp_180"
|
||||
android:layout_height="@dimen/dp_85"
|
||||
android:layout_gravity="center_vertical|center_horizontal|center"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/room_make_wheat1"
|
||||
app:layout_constraintEnd_toStartOf="@+id/room_make_wheat2"
|
||||
app:layout_constraintStart_toEndOf="@+id/room_make_wheat1"
|
||||
app:layout_constraintTop_toTopOf="@+id/room_make_wheat1"
|
||||
>
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="@dimen/dp_20"-->
|
||||
<!-- android:layout_gravity="center_vertical|center_horizontal"-->
|
||||
<!-- android:src="@mipmap/cxian" />-->
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_heart_value2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center_vertical|center_horizontal"
|
||||
android:src="@mipmap/dating_heart_line2" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_heart_value2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical|center_horizontal"
|
||||
android:layout_centerInParent="true"
|
||||
android:shadowColor="#40b40066"
|
||||
android:shadowDx="0"
|
||||
android:shadowDy="1"
|
||||
@@ -164,7 +115,7 @@
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_18"
|
||||
tools:text="1000000" />
|
||||
</FrameLayout>
|
||||
</RelativeLayout>
|
||||
|
||||
<com.xscm.moduleutil.widget.RoomMakeWheatView
|
||||
android:id="@+id/room_make_wheat2"
|
||||
@@ -174,46 +125,9 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:room_make_wheat_number="000" />
|
||||
<!-- <com.qxcm.moduleutil.widget.GifAvatarOvalView-->
|
||||
<!-- android:id="@+id/riv_room2"-->
|
||||
<!-- android:layout_width="@dimen/dp_60"-->
|
||||
<!-- android:layout_height="@dimen/dp_60"-->
|
||||
<!-- android:layout_marginEnd="@dimen/dp_35"-->
|
||||
<!-- android:src="@mipmap/default_avatar"-->
|
||||
<!-- app:gav_border_color="#404F8591"-->
|
||||
<!-- app:gav_border_width="@dimen/dp_5"-->
|
||||
<!-- app:layout_constraintEnd_toEndOf="parent"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="parent"-->
|
||||
<!-- app:riv_border_color="#404F8591"-->
|
||||
<!-- app:riv_border_width="@dimen/dp_5"-->
|
||||
<!-- app:riv_oval="true" />-->
|
||||
|
||||
<!-- <TextView-->
|
||||
<!-- android:id="@+id/user_name2"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:text="房间号"-->
|
||||
<!-- android:textColor="@color/white"-->
|
||||
<!-- android:textSize="14sp"-->
|
||||
<!-- app:layout_constraintEnd_toEndOf="@+id/riv_room2"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="@+id/riv_room2"-->
|
||||
<!-- app:layout_constraintTop_toBottomOf="@+id/riv_room2" />-->
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<!-- <androidx.recyclerview.widget.RecyclerView-->
|
||||
<!-- android:id="@+id/rv_gift"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="@dimen/dp_140"-->
|
||||
<!-- android:layout_marginStart="@dimen/dp_16"-->
|
||||
<!-- android:layout_marginTop="@dimen/dp_60"-->
|
||||
<!-- android:layout_marginEnd="@dimen/dp_16"-->
|
||||
<!-- android:visibility="gone"-->
|
||||
<!-- app:layout_constraintEnd_toEndOf="parent"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="parent"-->
|
||||
<!-- app:layout_constraintTop_toBottomOf="@+id/cl_2"-->
|
||||
<!-- tools:listitem="@layout/room_gift_wall_item" />-->
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -248,28 +162,5 @@
|
||||
android:src="@mipmap/gongxiang" />
|
||||
</LinearLayout>
|
||||
|
||||
<!-- <com.qxcm.moduleutil.widget.DropView-->
|
||||
<!-- android:id="@+id/drop_view"-->
|
||||
<!-- android:layout_width="@dimen/dp_240"-->
|
||||
<!-- android:layout_height="@dimen/dp_135"-->
|
||||
<!-- android:background="@drawable/bg_r6_000000"-->
|
||||
<!-- app:layout_constraintEnd_toEndOf="parent"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="parent"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="parent">-->
|
||||
|
||||
<!-- <FrameLayout-->
|
||||
<!-- android:id="@+id/fl_screenshare"-->
|
||||
<!-- android:layout_width="match_parent"-->
|
||||
<!-- android:layout_height="match_parent"-->
|
||||
<!-- />-->
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:layout_width="@dimen/dp_18"-->
|
||||
<!-- android:layout_height="@dimen/dp_18"-->
|
||||
<!-- android:layout_gravity="center|bottom"-->
|
||||
<!-- android:layout_marginEnd="@dimen/dp_16"-->
|
||||
<!-- android:src="@mipmap/quan" />-->
|
||||
|
||||
<!-- </com.qxcm.moduleutil.widget.DropView>-->
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -128,10 +128,10 @@
|
||||
app:tl_indicator_corner_radius="@dimen/dp_3"
|
||||
app:tl_indicator_drawable="@color/transparent"
|
||||
app:tl_indicator_height="@dimen/dp_6"
|
||||
app:tl_tab_padding="@dimen/dp_10"
|
||||
app:tl_indicator_margin_bottom="@dimen/dp_3"
|
||||
app:tl_indicator_width="0dp"
|
||||
app:tl_showCateIndicator="false"
|
||||
app:tl_tab_width="@dimen/dp_50"
|
||||
app:tl_textBold="SELECT"
|
||||
app:tl_textSelectColor="@color/white"
|
||||
app:tl_textSelectedSize="@dimen/sp_14"
|
||||
|
||||
@@ -63,7 +63,8 @@
|
||||
app:layout_constraintEnd_toEndOf="@id/view_top2"
|
||||
app:layout_constraintStart_toStartOf="@id/view_top2"/>
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
app:isShine="false"
|
||||
android:id="@+id/room_top2_name"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -167,9 +168,10 @@
|
||||
app:layout_constraintTop_toBottomOf="@+id/room_top2_name"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
android:id="@+id/room_top1_name"
|
||||
android:layout_width="0dp"
|
||||
app:isShine="false"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:ellipsize="end"
|
||||
@@ -207,7 +209,8 @@
|
||||
app:layout_constraintTop_toBottomOf="@+id/room_top1_name"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
app:isShine="false"
|
||||
android:id="@+id/room_top3_name"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
|
||||
@@ -46,7 +46,8 @@
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintVertical_bias="0.20">
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
app:isShine="false"
|
||||
android:id="@+id/room_item_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
|
||||
@@ -46,9 +46,10 @@
|
||||
android:layout_marginEnd="@dimen/dp_12"
|
||||
android:background="@mipmap/gsui" />
|
||||
|
||||
<TextView
|
||||
<com.xscm.moduleutil.widget.ShineTextView
|
||||
android:id="@+id/tv_nick_name"
|
||||
android:layout_width="wrap_content"
|
||||
app:isShine="false"
|
||||
android:layout_height="@dimen/dp_24"
|
||||
android:layout_below="@+id/riv_user_head"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
|
||||
4
MainModule/src/main/res/values/style.xml
Normal file
4
MainModule/src/main/res/values/style.xml
Normal file
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
</resources>
|
||||
@@ -54,7 +54,10 @@ android {
|
||||
dimension "environment"
|
||||
// 正式版包名:使用基础包名(com.example.myapp)
|
||||
applicationIdSuffix ""
|
||||
|
||||
// // 测试版包名:基础包名 + .beta(com.example.myapp.beta)
|
||||
// applicationIdSuffix ".beta.b"
|
||||
// // 测试版版本名:1.0-beta
|
||||
// versionNameSuffix "-beta.b"
|
||||
// 【正式版应用名称】通过resValue动态生成string资源
|
||||
resValue "string", "app_name", "羽声语音"
|
||||
|
||||
|
||||
@@ -7,8 +7,8 @@ android {
|
||||
defaultConfig {
|
||||
minSdk 24
|
||||
targetSdk 35
|
||||
versionCode 12
|
||||
versionName "1.1.2"
|
||||
versionCode 1
|
||||
versionName "1.0.0"
|
||||
|
||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user