修改测试问题
This commit is contained in:
parent
c3a4b57e18
commit
cec82501db
@ -53,11 +53,6 @@ import org.greenrobot.eventbus.ThreadMode;
|
|||||||
public class LiveEndViewHolder extends AbsViewHolder implements View.OnClickListener {
|
public class LiveEndViewHolder extends AbsViewHolder implements View.OnClickListener {
|
||||||
|
|
||||||
private ImageView mAvatar1;
|
private ImageView mAvatar1;
|
||||||
private ImageView mAvatar2;
|
|
||||||
private TextView mName;
|
|
||||||
public static TextView mDuration;//直播时长
|
|
||||||
public static TextView mVotes;//收获映票
|
|
||||||
public static TextView mWatchNum;//观看人数
|
|
||||||
//直播类型
|
//直播类型
|
||||||
private static LiveOfType type;
|
private static LiveOfType type;
|
||||||
|
|
||||||
@ -92,16 +87,6 @@ public class LiveEndViewHolder extends AbsViewHolder implements View.OnClickList
|
|||||||
mAvatar1 = (ImageView) findViewById(R.id.avatar_1);
|
mAvatar1 = (ImageView) findViewById(R.id.avatar_1);
|
||||||
userLiveEnd = (RelativeLayout) findViewById(R.id.user_live_end);
|
userLiveEnd = (RelativeLayout) findViewById(R.id.user_live_end);
|
||||||
anchorLiveEnd = (RelativeLayout) findViewById(R.id.anchor_live_end);
|
anchorLiveEnd = (RelativeLayout) findViewById(R.id.anchor_live_end);
|
||||||
// mAvatar2 = (ImageView) findViewById(R.id.avatar_2);
|
|
||||||
// mName = (TextView) findViewById(R.id.name);
|
|
||||||
// mDuration = (TextView) findViewById(R.id.duration);
|
|
||||||
// mVotes = (TextView) findViewById(R.id.votes);
|
|
||||||
// mWatchNum = (TextView) findViewById(R.id.watch_num);
|
|
||||||
// findViewById(R.id.btn_back).setOnClickListener(this);
|
|
||||||
// TextView votesName = (TextView) findViewById(R.id.votes_name);
|
|
||||||
// votesName.setText(WordUtil.getString(R.string.live_votes) + CommonAppConfig.getInstance().getVotesName());
|
|
||||||
|
|
||||||
|
|
||||||
if (type == LiveOfType.USER) {
|
if (type == LiveOfType.USER) {
|
||||||
initViewOfUser();
|
initViewOfUser();
|
||||||
initDataOfUser();
|
initDataOfUser();
|
||||||
@ -210,10 +195,6 @@ public class LiveEndViewHolder extends AbsViewHolder implements View.OnClickList
|
|||||||
|
|
||||||
public static void upData(String votes, String length, int nums, String uname) {
|
public static void upData(String votes, String length, int nums, String uname) {
|
||||||
Log.e("收", votes + "votes" + length + "length" + nums + "nums");
|
Log.e("收", votes + "votes" + length + "length" + nums + "nums");
|
||||||
|
|
||||||
// mVotes.setText(votes);
|
|
||||||
// mDuration.setText(length);
|
|
||||||
// mWatchNum.setText(StringUtil.toWan(nums));
|
|
||||||
if (type == LiveOfType.USER) {
|
if (type == LiveOfType.USER) {
|
||||||
liveDurationUser.setText(length);
|
liveDurationUser.setText(length);
|
||||||
liveNameUser.setText(uname);
|
liveNameUser.setText(uname);
|
||||||
@ -346,6 +327,14 @@ public class LiveEndViewHolder extends AbsViewHolder implements View.OnClickList
|
|||||||
String json = GsonUtils.toJson(data);
|
String json = GsonUtils.toJson(data);
|
||||||
LiveBean liveBean = GsonUtils.fromJson(json, LiveBean.class);
|
LiveBean liveBean = GsonUtils.fromJson(json, LiveBean.class);
|
||||||
mCheckLivePresenter.checkLive(liveBean);
|
mCheckLivePresenter.checkLive(liveBean);
|
||||||
|
if (mContext instanceof LiveAnchorActivity) {
|
||||||
|
((LiveAnchorActivity) mContext).superBackPressed();
|
||||||
|
} else if (mContext instanceof LiveAudienceActivity) {
|
||||||
|
((LiveAudienceActivity) mContext).exitLiveRoom();
|
||||||
|
} else if (mContext instanceof LiveRyAnchorActivity) {
|
||||||
|
((LiveRyAnchorActivity) mContext).superBackPressed();
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -3,7 +3,9 @@ package com.yunbao.main.activity;
|
|||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
|
import android.text.Editable;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
|
import android.text.TextWatcher;
|
||||||
import android.view.KeyEvent;
|
import android.view.KeyEvent;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.inputmethod.EditorInfo;
|
import android.view.inputmethod.EditorInfo;
|
||||||
@ -72,7 +74,26 @@ public class SearchActivity extends AbsActivity {
|
|||||||
mEditText.setText("");
|
mEditText.setText("");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
findViewById(R.id.btn_delete).setVisibility(View.GONE);
|
||||||
mEditText.setOnEditorActionListener(onEditorActionListener);
|
mEditText.setOnEditorActionListener(onEditorActionListener);
|
||||||
|
mEditText.addTextChangedListener(new TextWatcher() {
|
||||||
|
@Override
|
||||||
|
public void beforeTextChanged(CharSequence s, int start, int count, int after) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onTextChanged(CharSequence s, int start, int before, int count) {
|
||||||
|
if (!s.toString().trim().isEmpty()) {
|
||||||
|
findViewById(R.id.btn_delete).setVisibility(View.VISIBLE);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void afterTextChanged(Editable s) {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
//退出检索页面保存搜索记录
|
//退出检索页面保存搜索记录
|
||||||
findViewById(R.id.btn_back).setOnClickListener(new View.OnClickListener() {
|
findViewById(R.id.btn_back).setOnClickListener(new View.OnClickListener() {
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
Reference in New Issue
Block a user