Merge remote-tracking branch 'origin/dev_改版主分支-升级融云SDK&AGP8' into dev_改版主分支-升级融云SDK&AGP8

This commit is contained in:
zlzw 2024-03-29 13:05:10 +08:00
commit 3f717131cc
20 changed files with 108 additions and 48 deletions

View File

@ -161,7 +161,7 @@ public class CommentAdapter extends RecyclerView.Adapter {
del.setVisibility(View.GONE); del.setVisibility(View.GONE);
} }
if (bean.getReplyCommentList() != null) { if (bean.getReplyCommentList() != null) {
replyCount.setText("" + bean.getReplyCommentList().size() + "条回复>"); replyCount.setText(String.format(mContext.getResources().getString(R.string.active_count), String.valueOf(bean.getReplyCommentList().size())));
if (bean.getReplyCommentList().size() > 0) { if (bean.getReplyCommentList().size() > 0) {
report1.setTag(bean.getReplyCommentList().get(0)); report1.setTag(bean.getReplyCommentList().get(0));
del1.setTag(bean.getReplyCommentList().get(0)); del1.setTag(bean.getReplyCommentList().get(0));
@ -214,10 +214,11 @@ public class CommentAdapter extends RecyclerView.Adapter {
public void onClick(View v) { public void onClick(View v) {
if (!bean.isShow()) { if (!bean.isShow()) {
recyclerView.setVisibility(View.VISIBLE); recyclerView.setVisibility(View.VISIBLE);
replyCount.setText("收起"); replyCount.setText(mContext.getResources().getString(R.string.close));
} else { } else {
recyclerView.setVisibility(View.GONE); recyclerView.setVisibility(View.GONE);
replyCount.setText("" + bean.getReplyCommentList().size() + "条回复>"); replyCount.setText(String.format(mContext.getResources().getString(R.string.active_count), String.valueOf(bean.getReplyCommentList().size())))
;
} }
bean.setShow(!bean.isShow()); bean.setShow(!bean.isShow());
} }

View File

@ -162,7 +162,7 @@ public class CommentVideoAdapter extends RefreshAdapter<CommentBean> {
del.setVisibility(View.GONE); del.setVisibility(View.GONE);
} }
if (bean.getReplyCommentList() != null) { if (bean.getReplyCommentList() != null) {
replyCount.setText("" + bean.getReplyCommentList().size() + "条回复>"); replyCount.setText( String.format(mContext.getResources().getString(R.string.active_count), String.valueOf(bean.getReplyCommentList().size())));
if (bean.getReplyCommentList().size() > 0) { if (bean.getReplyCommentList().size() > 0) {
del1.setTag(bean.getReplyCommentList().get(0)); del1.setTag(bean.getReplyCommentList().get(0));
replyContent.setText(bean.getReplyCommentList().get(0).getContent()); replyContent.setText(bean.getReplyCommentList().get(0).getContent());
@ -214,10 +214,10 @@ public class CommentVideoAdapter extends RefreshAdapter<CommentBean> {
public void onClick(View v) { public void onClick(View v) {
if (!bean.isShow()) { if (!bean.isShow()) {
recyclerView.setVisibility(View.VISIBLE); recyclerView.setVisibility(View.VISIBLE);
replyCount.setText("收起"); replyCount.setText(mContext.getResources().getString(R.string.close));
} else { } else {
recyclerView.setVisibility(View.GONE); recyclerView.setVisibility(View.GONE);
replyCount.setText("" + bean.getReplyCommentList().size() + "条回复>"); replyCount.setText( String.format(mContext.getResources().getString(R.string.active_count), String.valueOf(bean.getReplyCommentList().size())));
} }
bean.setShow(!bean.isShow()); bean.setShow(!bean.isShow());
} }

View File

@ -81,7 +81,7 @@
<LinearLayout <LinearLayout
android:id="@+id/followLayout" android:id="@+id/followLayout"
android:layout_width="78dp" android:layout_width="wrap_content"
android:layout_height="36dp" android:layout_height="36dp"
android:background="@drawable/bg_main_com_type" android:background="@drawable/bg_main_com_type"
android:gravity="center" android:gravity="center"
@ -91,6 +91,7 @@
android:id="@+id/followIcon" android:id="@+id/followIcon"
android:layout_width="20dp" android:layout_width="20dp"
android:layout_height="20dp" android:layout_height="20dp"
android:layout_marginLeft="10dp"
android:src="@mipmap/icon_like_follow" /> android:src="@mipmap/icon_like_follow" />
<TextView <TextView
@ -98,6 +99,7 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="5dp" android:layout_marginLeft="5dp"
android:layout_marginRight="10dp"
android:text="@string/follow" android:text="@string/follow"
android:textColor="@color/white" android:textColor="@color/white"
android:textSize="14dp" android:textSize="14dp"
@ -188,7 +190,7 @@
android:id="@+id/replyCount" android:id="@+id/replyCount"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="评论0" android:text="0"
android:textColor="#333333" android:textColor="#333333"
android:textSize="16dp" android:textSize="16dp"
android:textStyle="bold" /> android:textStyle="bold" />
@ -255,7 +257,7 @@
android:layout_height="40dp" android:layout_height="40dp"
android:layout_weight="1" android:layout_weight="1"
android:background="@color/transparent" android:background="@color/transparent"
android:hint="说点什么..." android:hint="@string/video_say_something"
android:paddingLeft="5dp" android:paddingLeft="5dp"
android:paddingRight="5dp" android:paddingRight="5dp"
android:textSize="14dp" /> android:textSize="14dp" />

View File

@ -183,7 +183,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="10dp" android:layout_marginLeft="10dp"
android:layout_weight="1" android:layout_weight="1"
android:text="立即发表" android:text=""
android:textColor="#333333" android:textColor="#333333"
android:textSize="12dp" android:textSize="12dp"
android:visibility="invisible" /> android:visibility="invisible" />

View File

@ -801,7 +801,7 @@
android:layout_width="30dp" android:layout_width="30dp"
android:layout_height="30dp" android:layout_height="30dp"
android:src="@mipmap/icon_right_gray" android:src="@mipmap/icon_right_gray"
android:visibility="invisible" /> android:visibility="visible" />
</LinearLayout> </LinearLayout>

View File

@ -46,7 +46,7 @@
android:gravity="center" android:gravity="center"
android:paddingLeft="8dp" android:paddingLeft="8dp"
android:paddingRight="8dp" android:paddingRight="8dp"
android:text="作者" android:text="@string/active_author"
android:textColor="@color/white" android:textColor="@color/white"
android:textSize="12dp" android:textSize="12dp"
android:visibility="gone" /> android:visibility="gone" />
@ -61,7 +61,7 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:padding="10dp" android:padding="10dp"
android:text="删除" android:text="@string/delete"
android:textColor="#777777" android:textColor="#777777"
android:textSize="11dp" android:textSize="11dp"
android:visibility="gone" /> android:visibility="gone" />
@ -72,7 +72,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginRight="5dp" android:layout_marginRight="5dp"
android:padding="10dp" android:padding="10dp"
android:text="举报" android:text="@string/report"
android:textColor="#333333" android:textColor="#333333"
android:textSize="11dp" android:textSize="11dp"
android:textStyle="bold" /> android:textStyle="bold" />

View File

@ -59,7 +59,7 @@
android:gravity="center" android:gravity="center"
android:paddingLeft="8dp" android:paddingLeft="8dp"
android:paddingRight="8dp" android:paddingRight="8dp"
android:text="作者" android:text="@string/active_author"
android:textColor="@color/white" android:textColor="@color/white"
android:textSize="10dp" android:textSize="10dp"
android:visibility="gone" /> android:visibility="gone" />
@ -75,7 +75,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="10dp" android:layout_marginTop="10dp"
android:padding="10dp" android:padding="10dp"
android:text="删除" android:text="@string/delete"
android:textColor="#777777" android:textColor="#777777"
android:textSize="11dp" android:textSize="11dp"
android:visibility="gone" /> android:visibility="gone" />
@ -97,7 +97,7 @@
android:layout_marginTop="10dp" android:layout_marginTop="10dp"
android:layout_marginRight="5dp" android:layout_marginRight="5dp"
android:padding="10dp" android:padding="10dp"
android:text="举报" android:text="@string/report"
android:textColor="#333333" android:textColor="#333333"
android:textSize="11dp" android:textSize="11dp"
android:textStyle="bold" /> android:textStyle="bold" />
@ -148,7 +148,7 @@
android:gravity="center" android:gravity="center"
android:paddingLeft="8dp" android:paddingLeft="8dp"
android:paddingRight="8dp" android:paddingRight="8dp"
android:text="作者" android:text="@string/active_author"
android:textColor="@color/white" android:textColor="@color/white"
android:textSize="11dp" android:textSize="11dp"
android:visibility="gone" /> android:visibility="gone" />
@ -163,7 +163,7 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:padding="10dp" android:padding="10dp"
android:text="删除" android:text="@string/delete"
android:textColor="#777777" android:textColor="#777777"
android:textSize="11dp" android:textSize="11dp"
android:visibility="gone" /> android:visibility="gone" />
@ -174,7 +174,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginRight="5dp" android:layout_marginRight="5dp"
android:padding="10dp" android:padding="10dp"
android:text="举报" android:text="@string/report"
android:textColor="#333333" android:textColor="#333333"
android:textSize="11dp" android:textSize="11dp"
android:textStyle="bold" /> android:textStyle="bold" />
@ -203,7 +203,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="30dp" android:layout_marginLeft="30dp"
android:layout_marginTop="5dp" android:layout_marginTop="5dp"
android:text="共4条回复>" android:text="@string/active_count"
android:textColor="#FF4874" android:textColor="#FF4874"
android:textSize="12dp" android:textSize="12dp"
android:textStyle="bold" android:textStyle="bold"

View File

@ -56,7 +56,7 @@
android:gravity="center" android:gravity="center"
android:paddingLeft="8dp" android:paddingLeft="8dp"
android:paddingRight="8dp" android:paddingRight="8dp"
android:text="作者" android:text="@string/active_author"
android:textColor="@color/white" android:textColor="@color/white"
android:textSize="10dp" android:textSize="10dp"
android:visibility="gone" /> android:visibility="gone" />
@ -72,7 +72,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="10dp" android:layout_marginTop="10dp"
android:padding="10dp" android:padding="10dp"
android:text="删除" android:text="@string/delete"
android:textColor="#777777" android:textColor="#777777"
android:textSize="11dp" android:textSize="11dp"
android:visibility="gone" /> android:visibility="gone" />
@ -145,7 +145,7 @@
android:gravity="center" android:gravity="center"
android:paddingLeft="8dp" android:paddingLeft="8dp"
android:paddingRight="8dp" android:paddingRight="8dp"
android:text="作者" android:text="@string/active_author"
android:textColor="@color/white" android:textColor="@color/white"
android:textSize="11dp" android:textSize="11dp"
android:visibility="gone" /> android:visibility="gone" />
@ -160,7 +160,7 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:padding="10dp" android:padding="10dp"
android:text="删除" android:text="@string/delete"
android:textColor="#777777" android:textColor="#777777"
android:textSize="11dp" android:textSize="11dp"
android:visibility="gone" /> android:visibility="gone" />
@ -200,7 +200,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="30dp" android:layout_marginLeft="30dp"
android:layout_marginTop="5dp" android:layout_marginTop="5dp"
android:text="共4条回复>" android:text="@string/active_count"
android:textColor="#FF4874" android:textColor="#FF4874"
android:textSize="12dp" android:textSize="12dp"
android:textStyle="bold" android:textStyle="bold"

View File

@ -30,4 +30,9 @@
<string name="time_cannot_be_greater_than_the_current_time">Time cannot be greater than the current time</string> <string name="time_cannot_be_greater_than_the_current_time">Time cannot be greater than the current time</string>
<string name="msg_del_sure">Do you confirm deletion?</string> <string name="msg_del_sure">Do you confirm deletion?</string>
<string name="not_blackmail">Cannot blackmail oneself</string> <string name="not_blackmail">Cannot blackmail oneself</string>
<string name="active_author">author</string>
<string name="active_count">altogether %1$s strip reply></string>
<string name="uploading">Uploading...</string>
<string name="upload_fail">Upload failed</string>
<string name="please_input_content">Please fill in the publication content</string>
</resources> </resources>

View File

@ -1474,7 +1474,7 @@
<string name="upload_failed">删除成功</string> <string name="upload_failed">删除成功</string>
<string name="_9">最多添加9張圖片</string> <string name="_9">最多添加9張圖片</string>
<string name="not_interested">不感興趣</string> <string name="not_interested">不感興趣</string>
<string name="person_like">觉得很赞</string> <string name="person_like">覺得很讚</string>
<string name="fan_group_name">主播守護團</string> <string name="fan_group_name">主播守護團</string>
<string name="user_home_anchor">主播粉絲團</string> <string name="user_home_anchor">主播粉絲團</string>
<string name="main_active_type_01">美圖</string> <string name="main_active_type_01">美圖</string>
@ -1495,4 +1495,9 @@
<string name="time_cannot_be_greater_than_the_current_time">时间不能大于当前时间</string> <string name="time_cannot_be_greater_than_the_current_time">时间不能大于当前时间</string>
<string name="msg_del_sure">是否確認刪除?</string> <string name="msg_del_sure">是否確認刪除?</string>
<string name="not_blackmail">不能拉黑自己</string> <string name="not_blackmail">不能拉黑自己</string>
<string name="active_author">作者</string>
<string name="active_count">共%1$s條回復></string>
<string name="uploading">上傳中...</string>
<string name="upload_fail">上傳失敗</string>
<string name="please_input_content">請填寫發佈內容</string>
</resources> </resources>

View File

@ -1474,7 +1474,7 @@
<string name="upload_failed">删除成功</string> <string name="upload_failed">删除成功</string>
<string name="_9">最多添加9張圖片</string> <string name="_9">最多添加9張圖片</string>
<string name="not_interested">不感興趣</string> <string name="not_interested">不感興趣</string>
<string name="person_like">觉得很赞</string> <string name="person_like">覺得很讚</string>
<string name="fan_group_name">主播守護團</string> <string name="fan_group_name">主播守護團</string>
<string name="user_home_anchor">主播粉絲團</string> <string name="user_home_anchor">主播粉絲團</string>
<string name="main_active_type_01">美圖</string> <string name="main_active_type_01">美圖</string>
@ -1495,4 +1495,9 @@
<string name="time_cannot_be_greater_than_the_current_time">时间不能大于当前时间</string> <string name="time_cannot_be_greater_than_the_current_time">时间不能大于当前时间</string>
<string name="msg_del_sure">是否確認刪除?</string> <string name="msg_del_sure">是否確認刪除?</string>
<string name="not_blackmail">不能拉黑自己</string> <string name="not_blackmail">不能拉黑自己</string>
<string name="active_author">作者</string>
<string name="active_count">共%1$s條回復></string>
<string name="uploading">上傳中...</string>
<string name="upload_fail">上傳失敗</string>
<string name="please_input_content">請填寫發佈內容</string>
</resources> </resources>

View File

@ -1472,7 +1472,7 @@
<string name="upload_failed">删除成功</string> <string name="upload_failed">删除成功</string>
<string name="_9">最多添加9張圖片</string> <string name="_9">最多添加9張圖片</string>
<string name="not_interested">不感興趣</string> <string name="not_interested">不感興趣</string>
<string name="person_like">觉得很赞</string> <string name="person_like">覺得很讚</string>
<string name="fan_group_name">主播守護團</string> <string name="fan_group_name">主播守護團</string>
<string name="user_home_anchor">主播粉絲團</string> <string name="user_home_anchor">主播粉絲團</string>
<string name="main_active_type_01">美圖</string> <string name="main_active_type_01">美圖</string>
@ -1493,4 +1493,9 @@
<string name="time_cannot_be_greater_than_the_current_time">时间不能大于当前时间</string> <string name="time_cannot_be_greater_than_the_current_time">时间不能大于当前时间</string>
<string name="msg_del_sure">是否確認刪除?</string> <string name="msg_del_sure">是否確認刪除?</string>
<string name="not_blackmail">不能拉黑自己</string> <string name="not_blackmail">不能拉黑自己</string>
<string name="active_author">作者</string>
<string name="active_count">共%1$s條回復></string>
<string name="uploading">上傳中...</string>
<string name="upload_fail">上傳失敗</string>
<string name="please_input_content">請填寫發佈內容</string>
</resources> </resources>

View File

@ -557,7 +557,7 @@
<string name="video_download_success">Video download successful</string> <string name="video_download_success">Video download successful</string>
<string name="video_download_failed">Video download failed</string> <string name="video_download_failed">Video download failed</string>
<string name="video_no_more_video">No more videos</string> <string name="video_no_more_video">No more videos</string>
<string name="video_comment">comment</string> <string name="video_comment">Comment</string>
<string name="video_comment_cannot_self">I can\'t give myself a compliment</string> <string name="video_comment_cannot_self">I can\'t give myself a compliment</string>
<string name="video_no_comment">No comment for the moment. Grab the sofa</string> <string name="video_no_comment">No comment for the moment. Grab the sofa</string>
<string name="video_comment_reply">Reply</string> <string name="video_comment_reply">Reply</string>
@ -1494,7 +1494,7 @@ Limited ride And limited avatar frame</string>
<string name="upload_failed">删除成功</string> <string name="upload_failed">删除成功</string>
<string name="_9">最多添加9張圖片</string> <string name="_9">最多添加9張圖片</string>
<string name="not_interested">不感興趣</string> <string name="not_interested">不感興趣</string>
<string name="person_like">觉得很赞</string> <string name="person_like">覺得很讚</string>
<string name="fan_group_name">主播守護團</string> <string name="fan_group_name">主播守護團</string>
<string name="user_home_anchor">主播粉絲團</string> <string name="user_home_anchor">主播粉絲團</string>
<string name="main_active_type_01">美圖</string> <string name="main_active_type_01">美圖</string>
@ -1515,6 +1515,10 @@ Limited ride And limited avatar frame</string>
<string name="time_cannot_be_greater_than_the_current_time">时间不能大于当前时间</string> <string name="time_cannot_be_greater_than_the_current_time">时间不能大于当前时间</string>
<string name="msg_del_sure">是否確認刪除?</string> <string name="msg_del_sure">是否確認刪除?</string>
<string name="not_blackmail">不能拉黑自己</string> <string name="not_blackmail">不能拉黑自己</string>
<string name="active_author">作者</string>
<string name="active_count">共%1$s條回復></string>
<string name="uploading">上傳中...</string>
<string name="upload_fail">上傳失敗</string>
<string name="please_input_content">請填寫發佈內容</string>
</resources> </resources>

View File

@ -156,7 +156,7 @@ public class LiveNewWishListAdapter extends RecyclerView.Adapter<LiveNewWishList
mRlDelete.setOnClickListener(new View.OnClickListener() { mRlDelete.setOnClickListener(new View.OnClickListener() {
@Override @Override
public void onClick(View v) { public void onClick(View v) {
ToastUtil.show("删除" + mWishList.get(pos).getWishlist_name() + "成功"); ToastUtil.show(mContext.getResources().getString(R.string.delete) + mWishList.get(pos).getWishlist_name() + "成功");
mWishList.remove(pos); mWishList.remove(pos);
notifyDataSetChanged(); notifyDataSetChanged();
} }

View File

@ -156,7 +156,7 @@ public class LiveWishListAdapter extends RecyclerView.Adapter<LiveWishListAdapte
@Override @Override
public void onClick(View v) { public void onClick(View v) {
mWishList.remove(pos); mWishList.remove(pos);
ToastUtil.show("删除" + bean.getWishlist_name() + "成功"); ToastUtil.show(mContext.getResources().getString(R.string.delete) + bean.getWishlist_name() + "成功");
notifyDataSetChanged(); notifyDataSetChanged();
} }
}); });

View File

@ -360,7 +360,7 @@ public class CommunityDetailsActivity extends AbsActivity {
} }
}); });
commentRecyclerView.setAdapter(commentAdapter); commentRecyclerView.setAdapter(commentAdapter);
replyCount.setText("评论 " + list.size()); replyCount.setText(getResources().getString(R.string.video_comment) + " " + list.size());
} }
} }
}); });
@ -388,7 +388,7 @@ public class CommunityDetailsActivity extends AbsActivity {
ImgLoader.display(CommunityDetailsActivity.this, activeBean.getUser_avatar(), avatar); ImgLoader.display(CommunityDetailsActivity.this, activeBean.getUser_avatar(), avatar);
name.setText(activeBean.getUser_name()); name.setText(activeBean.getUser_name());
time.setText(activeBean.getCreate_time()); time.setText(activeBean.getCreate_time());
likeCount.setText(activeBean.getLove_num() + "人觉得很赞"); likeCount.setText(activeBean.getLove_num() + getResources().getString(R.string.person_like));
if (!StringUtil.isEmpty(activeBean.getContent())) { if (!StringUtil.isEmpty(activeBean.getContent())) {
content.setText(String.valueOf(JSONObject.parseObject(activeBean.getContent()).get("msg"))); content.setText(String.valueOf(JSONObject.parseObject(activeBean.getContent()).get("msg")));
} }

View File

@ -2,6 +2,7 @@ package com.yunbao.main.activity;
import android.Manifest; import android.Manifest;
import android.annotation.SuppressLint; import android.annotation.SuppressLint;
import android.app.Dialog;
import android.content.ClipData; import android.content.ClipData;
import android.content.Intent; import android.content.Intent;
import android.content.pm.PackageManager; import android.content.pm.PackageManager;
@ -43,6 +44,7 @@ import com.yunbao.common.upload.UploadCallback;
import com.yunbao.common.upload.UploadQnImpl; import com.yunbao.common.upload.UploadQnImpl;
import com.yunbao.common.utils.ActiveImageAdapter; import com.yunbao.common.utils.ActiveImageAdapter;
import com.yunbao.common.utils.DateFormatUtil; import com.yunbao.common.utils.DateFormatUtil;
import com.yunbao.common.utils.DialogUitl;
import com.yunbao.common.utils.FilesUtils; import com.yunbao.common.utils.FilesUtils;
import com.yunbao.common.utils.L; import com.yunbao.common.utils.L;
import com.yunbao.common.utils.StringUtil; import com.yunbao.common.utils.StringUtil;
@ -86,6 +88,8 @@ public class CommunitySendActivity extends AbsActivity {
List<NewCommunityType> newCommunityTypeList = new ArrayList<>(); List<NewCommunityType> newCommunityTypeList = new ArrayList<>();
int talkId; int talkId;
Dialog dialog;
@Override @Override
protected int getLayoutId() { protected int getLayoutId() {
return R.layout.activity_community_send; return R.layout.activity_community_send;
@ -110,6 +114,25 @@ public class CommunitySendActivity extends AbsActivity {
submit.setOnClickListener(new View.OnClickListener() { submit.setOnClickListener(new View.OnClickListener() {
@Override @Override
public void onClick(View v) { public void onClick(View v) {
if (StringUtil.isEmpty(content.getText().toString())) {
ToastUtil.show(mContext.getResources().getString(com.yunbao.main.R.string.please_input_content));
return;
}
if (isImage) {
if (imgUrlList.size() == 0) {
ToastUtil.show(mContext.getResources().getString(com.yunbao.main.R.string.please_input_content));
return;
}
} else {
if (videoFile == null) {
ToastUtil.show(mContext.getResources().getString(com.yunbao.main.R.string.please_input_content));
return;
}
}
if (StringUtil.isEmpty(talkContent.getText().toString())) {
ToastUtil.show(mContext.getResources().getString(com.yunbao.main.R.string.please_input_content));
return;
}
List<UploadBean> uploadBeanList = new ArrayList<>(); List<UploadBean> uploadBeanList = new ArrayList<>();
if (isImage) { if (isImage) {
for (int i = 0; i < activeImageAdapter.getImageFileList().size(); i++) { for (int i = 0; i < activeImageAdapter.getImageFileList().size(); i++) {
@ -222,15 +245,6 @@ public class CommunitySendActivity extends AbsActivity {
} }
private void submit() { private void submit() {
if (isImage) {
if (imgUrlList.size() == 0) {
return;
}
} else {
if (StringUtil.isEmpty(videoUrl)) {
return;
}
}
String imgUrl = ""; String imgUrl = "";
if (isImage) { if (isImage) {
imgUrl = new Gson().toJson(imgUrlList); imgUrl = new Gson().toJson(imgUrlList);
@ -244,6 +258,9 @@ public class CommunitySendActivity extends AbsActivity {
CommonHttpUtil.pushCommunity(isImage, jsonObject.toString(), String.valueOf(talkId), imgUrl, videoUrl, tempTime, new HttpCallback() { CommonHttpUtil.pushCommunity(isImage, jsonObject.toString(), String.valueOf(talkId), imgUrl, videoUrl, tempTime, new HttpCallback() {
@Override @Override
public void onSuccess(int code, String msg, String[] info) { public void onSuccess(int code, String msg, String[] info) {
if (dialog != null) {
dialog.dismiss();
}
ToastUtil.show(msg); ToastUtil.show(msg);
if (code == 0) { if (code == 0) {
finish(); finish();
@ -384,10 +401,14 @@ public class CommunitySendActivity extends AbsActivity {
if (mUploadStrategy == null) { if (mUploadStrategy == null) {
mUploadStrategy = new UploadQnImpl(mContext); mUploadStrategy = new UploadQnImpl(mContext);
} }
dialog = DialogUitl.loadingDialog(mContext, mContext.getResources().getString(com.yunbao.main.R.string.uploading));
dialog.show();
mUploadStrategy.upload(uploadBeans, true, new UploadCallback() { mUploadStrategy.upload(uploadBeans, true, new UploadCallback() {
@Override @Override
public void onFinish(List<UploadBean> list, boolean success) { public void onFinish(List<UploadBean> list, boolean success) {
if (!success) { if (!success) {
dialog.dismiss();
ToastUtil.show(mContext.getResources().getString(com.yunbao.main.R.string.upload_fail));
return; return;
} }
if (isImage) { if (isImage) {
@ -402,4 +423,12 @@ public class CommunitySendActivity extends AbsActivity {
} }
}, isImg); }, isImg);
} }
@Override
protected void onDestroy() {
super.onDestroy();
if (dialog != null) {
dialog.dismiss();
}
}
} }

View File

@ -248,7 +248,7 @@ public class UserHomeActivity extends AbsActivity {
likeCount.setText(String.valueOf(userInfo.getUserHomeTopInfo().getUser_love_num()));//关注数量 likeCount.setText(String.valueOf(userInfo.getUserHomeTopInfo().getUser_love_num()));//关注数量
if (isMe) { if (isMe) {
findViewById(R.id.setting).setVisibility(View.VISIBLE); findViewById(R.id.setting).setVisibility(View.INVISIBLE);
bottomEditLayout.setVisibility(View.VISIBLE); bottomEditLayout.setVisibility(View.VISIBLE);
imgUp.setVisibility(View.VISIBLE); imgUp.setVisibility(View.VISIBLE);
imgLabel.setVisibility(View.VISIBLE); imgLabel.setVisibility(View.VISIBLE);
@ -307,7 +307,7 @@ public class UserHomeActivity extends AbsActivity {
if (!StringUtil.isEmpty(userInfo.getUserHomeTopInfo().getAge())) { if (!StringUtil.isEmpty(userInfo.getUserHomeTopInfo().getAge())) {
tagList.add(userInfo.getUserHomeTopInfo().getAge() + (WordUtil.isNewZh() ? "" : "years old")); tagList.add(userInfo.getUserHomeTopInfo().getAge() + (WordUtil.isNewZh() ? "" : "years old"));
} }
if (!StringUtil.isEmpty(userInfo.getUserHomeTopInfo().getHeight())) { if (!StringUtil.isEmpty(userInfo.getUserHomeTopInfo().getHeight()) && !userInfo.getUserHomeTopInfo().getHeight().equals("0")) {
tagList.add(userInfo.getUserHomeTopInfo().getHeight() + "cm"); tagList.add(userInfo.getUserHomeTopInfo().getHeight() + "cm");
} }
if (!StringUtil.isEmpty(userInfo.getUserHomeTopInfo().getCareer())) { if (!StringUtil.isEmpty(userInfo.getUserHomeTopInfo().getCareer())) {

View File

@ -42,7 +42,7 @@ public class ConversationPopuwWindow implements View.OnClickListener {
private void initView() { private void initView() {
tvBlack = popupView.findViewById(com.yunbao.live.R.id.tv_black); tvBlack = popupView.findViewById(com.yunbao.live.R.id.tv_black);
tvBlack.setOnClickListener(this); tvBlack.setOnClickListener(this);
tvBlack.setText("删除"); tvBlack.setText(mContext.getResources().getString(R.string.delete));
} }

View File

@ -27,6 +27,7 @@ import com.yunbao.common.adapter.CommentVideoAdapter;
import com.yunbao.common.adapter.RefreshAdapter; import com.yunbao.common.adapter.RefreshAdapter;
import com.yunbao.common.bean.CommentBean; import com.yunbao.common.bean.CommentBean;
import com.yunbao.common.custom.CommonRefreshView; import com.yunbao.common.custom.CommonRefreshView;
import com.yunbao.common.custom.ItemDecoration;
import com.yunbao.common.custom.MyLinearLayout3; import com.yunbao.common.custom.MyLinearLayout3;
import com.yunbao.common.glide.ImgLoader; import com.yunbao.common.glide.ImgLoader;
import com.yunbao.common.http.CommonHttpUtil; import com.yunbao.common.http.CommonHttpUtil;
@ -35,6 +36,7 @@ import com.yunbao.common.utils.L;
import com.yunbao.common.utils.RouteUtil; import com.yunbao.common.utils.RouteUtil;
import com.yunbao.common.utils.ToastUtil; import com.yunbao.common.utils.ToastUtil;
import com.yunbao.common.views.AbsViewHolder; import com.yunbao.common.views.AbsViewHolder;
import com.yunbao.common.views.TopGradual;
import com.yunbao.live.activity.LiveReportActivity; import com.yunbao.live.activity.LiveReportActivity;
import com.yunbao.video.R; import com.yunbao.video.R;
import com.yunbao.video.activity.AbsVideoCommentActivity; import com.yunbao.video.activity.AbsVideoCommentActivity;
@ -127,6 +129,8 @@ public class VideoCommentViewHolder extends AbsViewHolder implements View.OnClic
mCommentNum = (TextView) findViewById(R.id.comment_num); mCommentNum = (TextView) findViewById(R.id.comment_num);
mRefreshView = (CommonRefreshView) findViewById(R.id.refreshView); mRefreshView = (CommonRefreshView) findViewById(R.id.refreshView);
mRefreshView.setEmptyLayoutId(R.layout.view_no_data_comment); mRefreshView.setEmptyLayoutId(R.layout.view_no_data_comment);
ItemDecoration decoration = new ItemDecoration(mContext, 0x00000000, 5, 0);
mRefreshView.setItemDecoration(decoration);
mRefreshView.setLoadMoreEnable(false); mRefreshView.setLoadMoreEnable(false);
mRefreshView.setLayoutManager(new LinearLayoutManager(mContext, LinearLayoutManager.VERTICAL, false) { mRefreshView.setLayoutManager(new LinearLayoutManager(mContext, LinearLayoutManager.VERTICAL, false) {
@Override @Override