修複踢人邏輯,增加翻譯

This commit is contained in:
18401019693
2022-12-30 17:24:46 +08:00
parent 488bee514d
commit 4a0901ea93
5 changed files with 82 additions and 68 deletions

View File

@@ -55,7 +55,9 @@ public class IMLoginManager extends BaseCacheManager {
* @return
*/
public int getSelectClarity() {
return getInt(SELECT_CLARITY, 1);
return getInt(SELECT_CLARITY, 0);
}
public boolean isHint() {

View File

@@ -111,21 +111,28 @@ public class LiveRobotMessageCustomPopup extends BottomPopupView {
@Override
public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {
if (actionId == EditorInfo.IME_ACTION_DONE) {
// 修改助手名字
LiveNetManager.get(getContext())
.setAiRobotDate("ai_time", robotNameSetting.getText().toString(), new HttpCallback<HttpCallbackModel>() {
@Override
public void onSuccess(HttpCallbackModel data) {
robotNameSetting.setVisibility(GONE);
robotTime.setVisibility(VISIBLE);
robotTime.setText(robotNameSetting.getText().toString());
}
String time = robotNameSetting.getText().toString();
int timeInt = Integer.parseInt(time);
if (timeInt > 5) {
// 修改助手名字
LiveNetManager.get(getContext())
.setAiRobotDate("ai_time", time, new HttpCallback<HttpCallbackModel>() {
@Override
public void onSuccess(HttpCallbackModel data) {
robotNameSetting.setVisibility(GONE);
robotTime.setVisibility(VISIBLE);
robotTime.setText(robotNameSetting.getText().toString());
}
@Override
public void onError(String error) {
ToastUtil.show(error);
}
});
} else {
ToastUtil.show(R.string.robot_minimum_interval);
}
@Override
public void onError(String error) {
ToastUtil.show(error);
}
});
}
return false;
@@ -136,7 +143,7 @@ public class LiveRobotMessageCustomPopup extends BottomPopupView {
@Override
public void onClick(View v) {
new XPopup.Builder(getContext())
.asCustom(new InputCustomPopup(getContext(),R.string.automatic_message_sending).setListener(new InputCustomPopup.InputCustomListener() {
.asCustom(new InputCustomPopup(getContext(), R.string.automatic_message_sending).setListener(new InputCustomPopup.InputCustomListener() {
@Override
public void onConfirm(String text) {
//添加消息语