Merge branch 'dev_1.1.2_lj' into dev_1.1.2
This commit is contained in:
@@ -5,6 +5,7 @@ import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.Button;
|
||||
import android.widget.RatingBar;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
@@ -18,24 +19,24 @@ import com.zhidao.mogo.module.event.panel.R;
|
||||
import com.zhidao.mogo.module.event.panel.bean.ShareEventDescription;
|
||||
import com.zhidao.mogo.module.event.panel.bean.ShareEventItem;
|
||||
import com.zhidao.mogo.module.event.panel.bean.ShareEventItemEnum;
|
||||
import com.zhidao.mogo.module.event.panel.bean.ShareEventLoadMoreItem;
|
||||
import com.zhidao.mogo.module.event.panel.fragment.EventPanelFragment;
|
||||
import com.zhidao.mogo.module.event.panel.presenter.ShareEventsPresenter;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
public class ShareEventAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder> {
|
||||
private Context context;
|
||||
private ShareEventsPresenter presenter;
|
||||
private ArrayList dataArrayList;
|
||||
private final LayoutInflater shareLayoutInflater;
|
||||
private boolean emptylist;//分享空白页
|
||||
private IMogoServiceApis mApis;
|
||||
|
||||
public void setEmptylist(boolean emptylist) {
|
||||
this.emptylist = emptylist;
|
||||
}
|
||||
|
||||
public ShareEventAdapter(Context context, ArrayList dataArrayList) {
|
||||
public ShareEventAdapter(Context context, ArrayList dataArrayList, ShareEventsPresenter presenter) {
|
||||
this.context = context;
|
||||
this.dataArrayList = dataArrayList;
|
||||
this.presenter = presenter;
|
||||
shareLayoutInflater = LayoutInflater.from(context);
|
||||
mApis = (IMogoServiceApis) ARouter.getInstance().build(MogoServicePaths.PATH_SERVICE_APIS).navigation(context);
|
||||
}
|
||||
@@ -67,24 +68,53 @@ public class ShareEventAdapter extends RecyclerView.Adapter<RecyclerView.ViewHol
|
||||
}
|
||||
}
|
||||
|
||||
private float getEnthusuasmIndex(double score) {
|
||||
if (score <= 0) {
|
||||
return 0;
|
||||
} else if (0 < score && score <= 5) {
|
||||
return (float) 0.5;
|
||||
} else if (5 < score && score <= 10) {
|
||||
return 1;
|
||||
} else if (10 < score && score <= 15) {
|
||||
return (float) 1.5;
|
||||
} else if (15 < score && score <= 20) {
|
||||
return 2;
|
||||
} else if (20 < score && score <= 25) {
|
||||
return (float) 2.5;
|
||||
} else if (25 < score && score <= 30) {
|
||||
return 3;
|
||||
} else if (30 < score && score <= 35) {
|
||||
return (float) 3.5;
|
||||
} else if (35 < score && score <= 40) {
|
||||
return 4;
|
||||
} else if (40 < score && score <= 45) {
|
||||
return (float) 4.5;
|
||||
}
|
||||
return 5;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder holder, int position) {
|
||||
|
||||
if (holder instanceof shareDescriptionViewHolder) {
|
||||
//分享次数,车友认同次数,热心指数
|
||||
if (dataArrayList.size() > position) {
|
||||
ShareEventDescription.ResultBean.EnthusiasmIndexBean data = (ShareEventDescription.ResultBean.EnthusiasmIndexBean) dataArrayList.get(position);
|
||||
if (data != null) {
|
||||
String shareNum = String.valueOf(data.getShareNum());
|
||||
String likeNum = String.valueOf(data.getLikeNum());
|
||||
double enthusiasmIndex = data.getEnthusiasmIndex();
|
||||
if (shareNum != null) {
|
||||
((shareDescriptionViewHolder) holder).shareNumTextView.setText(shareNum);
|
||||
}
|
||||
if (likeNum != null) {
|
||||
((shareDescriptionViewHolder) holder).approveNumTextView.setText(likeNum);
|
||||
}
|
||||
((shareDescriptionViewHolder) holder).ratingBar.setRating(getEnthusuasmIndex(enthusiasmIndex));
|
||||
}
|
||||
}
|
||||
} else if (holder instanceof shareItemViewHolder) {
|
||||
//分享列表
|
||||
if (dataArrayList.size() > position) {
|
||||
ShareEventItem.ResultBean.PageBean.ContentBean data = (ShareEventItem.ResultBean.PageBean.ContentBean) dataArrayList.get(position);
|
||||
if (data != null) {
|
||||
@@ -112,23 +142,27 @@ public class ShareEventAdapter extends RecyclerView.Adapter<RecyclerView.ViewHol
|
||||
|
||||
}
|
||||
} else if (holder instanceof shareLoadStatusViewHolder) {
|
||||
((shareLoadStatusViewHolder) holder).statusButton.setText("加载更多");
|
||||
ShareEventLoadMoreItem item = (ShareEventLoadMoreItem) dataArrayList.get(dataArrayList.size() - 1);
|
||||
((shareLoadStatusViewHolder) holder).statusButton.setText(item.getStatusText());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemCount() {
|
||||
return dataArrayList.size() + ((this.emptylist == true) ? 1 : 0);
|
||||
int size = dataArrayList.size();
|
||||
return dataArrayList.size();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemViewType(int position) {
|
||||
if (position == 0) {
|
||||
Object item = dataArrayList.get(position);
|
||||
if (item instanceof ShareEventDescription) {
|
||||
return ShareEventItemEnum.ITEM_TYPE_NUM_DES;
|
||||
}
|
||||
if (emptylist == true) {
|
||||
return ShareEventItemEnum.ITEM_TYPE_SHARE_EMPTY;
|
||||
} else if (item instanceof ShareEventItem) {
|
||||
return ShareEventItemEnum.ITEM_TYPE_SHARE_LIST;
|
||||
} else if (item instanceof ShareEventLoadMoreItem) {
|
||||
return ((ShareEventLoadMoreItem) dataArrayList.get(position)).getViewType();
|
||||
}
|
||||
return ShareEventItemEnum.ITEM_TYPE_SHARE_LIST;
|
||||
}
|
||||
@@ -159,11 +193,13 @@ public class ShareEventAdapter extends RecyclerView.Adapter<RecyclerView.ViewHol
|
||||
class shareDescriptionViewHolder extends RecyclerView.ViewHolder {
|
||||
private TextView shareNumTextView;
|
||||
private TextView approveNumTextView;
|
||||
private RatingBar ratingBar;
|
||||
|
||||
public shareDescriptionViewHolder(@NonNull View itemView) {
|
||||
super(itemView);
|
||||
shareNumTextView = itemView.findViewById(R.id.share_num);
|
||||
approveNumTextView = itemView.findViewById(R.id.share_approve);
|
||||
ratingBar = itemView.findViewById(R.id.rating_bar);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -173,6 +209,7 @@ public class ShareEventAdapter extends RecyclerView.Adapter<RecyclerView.ViewHol
|
||||
class shareEmptyViewHolder extends RecyclerView.ViewHolder {
|
||||
public shareEmptyViewHolder(@NonNull View itemView) {
|
||||
super(itemView);
|
||||
|
||||
Button shareBtn = itemView.findViewById(R.id.share_event_button);
|
||||
shareBtn.setOnClickListener(view -> {
|
||||
EventPanelFragment.Companion.getInstance().hidePanel();
|
||||
@@ -190,6 +227,15 @@ public class ShareEventAdapter extends RecyclerView.Adapter<RecyclerView.ViewHol
|
||||
public shareLoadStatusViewHolder(@NonNull View itemView) {
|
||||
super(itemView);
|
||||
statusButton = itemView.findViewById(R.id.event_share_load_status);
|
||||
statusButton.setOnClickListener(new View.OnClickListener() {
|
||||
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
|
||||
presenter.getMoreShareEventList();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -45,11 +45,11 @@ public class ShareEventDescription extends BaseData implements Serializable {
|
||||
this.enthusiasmIndex = enthusiasmIndex;
|
||||
}
|
||||
|
||||
public static class EnthusiasmIndexBean {
|
||||
public static class EnthusiasmIndexBean{
|
||||
@Override
|
||||
public String toString() {
|
||||
return "EnthusiasmIndexBean{" +
|
||||
"id=" + id +
|
||||
", id=" + id +
|
||||
", sn='" + sn + '\'' +
|
||||
", score=" + score +
|
||||
", shareNum=" + shareNum +
|
||||
@@ -72,7 +72,6 @@ public class ShareEventDescription extends BaseData implements Serializable {
|
||||
* createTime : 2020-07-28T06:21:11.523+0000
|
||||
* updateTime : 2020-07-28T06:21:11.523+0000
|
||||
*/
|
||||
|
||||
private int id;
|
||||
private String sn;
|
||||
private int score;
|
||||
|
||||
@@ -96,7 +96,8 @@ public class ShareEventItem extends BaseData implements Serializable {
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ContentBean{" +
|
||||
"uploadTimestamp=" + uploadTimestamp +
|
||||
"viewType=" + viewType +
|
||||
", uploadTimestamp=" + uploadTimestamp +
|
||||
", timeout=" + timeout +
|
||||
", uploadAddress='" + uploadAddress + '\'' +
|
||||
", distance=" + distance +
|
||||
@@ -162,6 +163,7 @@ public class ShareEventItem extends BaseData implements Serializable {
|
||||
* data : [{"url":"http://petchfile-1255510688.cos.ap-beijing.myqcloud.com/sso-server-image/1592546939076.mp4%3Fsign%3Dq-sign-algorithm%253Dsha1%2526q-ak%253DAKIDCWfcNwD5PXVWLxwejccR3Tiz5zhIkx0T%2526q-sign-time%253D1592546939%253B1592550539%2526q-key-time%253D1592546939%253B1592550539%2526q-header-list%253D%2526q-url-param-list%253D%2526q-signature%253D74a4058ad7579ea210dafcf78d7a19460cffb899?sign=q-sign-algorithm%3Dsha1%26q-ak%3DAKIDCWfcNwD5PXVWLxwejccR3Tiz5zhIkx0T%26q-sign-time%3D1595574735%3B1595578335%26q-key-time%3D1595574735%3B1595578335%26q-header-list%3D%26q-url-param-list%3D%26q-signature%3D679bff1838c7d497d38f48ef999b50e80c5856c4","thumbnail":"http://petchfile-1255510688.cos.ap-beijing.myqcloud.com/sso-server-image/1592546956790.png%3Fsign%3Dq-sign-algorithm%253Dsha1%2526q-ak%253DAKIDCWfcNwD5PXVWLxwejccR3Tiz5zhIkx0T%2526q-sign-time%253D1592546956%253B1592550556%2526q-key-time%253D1592546956%253B1592550556%2526q-header-list%253D%2526q-url-param-list%253D%2526q-signature%253Dcc9a35349fc55e433f934af88df576ae792b3987?sign=q-sign-algorithm%3Dsha1%26q-ak%3DAKIDCWfcNwD5PXVWLxwejccR3Tiz5zhIkx0T%26q-sign-time%3D1595574735%3B1595578335%26q-key-time%3D1595574735%3B1595578335%26q-header-list%3D%26q-url-param-list%3D%26q-signature%3D99b5a92a4f97909d8c217dbeec2ec6e9ec1052f4","content":null,"illegalCount":null}]
|
||||
*/
|
||||
|
||||
private int viewType = ShareEventItemEnum.ITEM_TYPE_SHARE_LIST;
|
||||
private long uploadTimestamp;
|
||||
private long timeout;
|
||||
private String uploadAddress;
|
||||
|
||||
@@ -6,5 +6,6 @@ public interface ShareEventItemEnum {
|
||||
int ITEM_TYPE_SHARE_LIST = 1;
|
||||
int ITEM_TYPE_SHARE_EMPTY = 2;
|
||||
int ITEM_TYPE_LOAD_MORE_STATUS = 3;
|
||||
int ITEM_TYPE_NO_MORE = 4;
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,29 @@
|
||||
package com.zhidao.mogo.module.event.panel.bean;
|
||||
|
||||
import com.mogo.commons.data.BaseData;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/*
|
||||
* 没有任何分享,去分享/加载更多/没有更多了
|
||||
* */
|
||||
public class ShareEventLoadMoreItem extends BaseData implements Serializable {
|
||||
private String statusText;
|
||||
private int viewType;
|
||||
|
||||
public int getViewType() {
|
||||
return viewType;
|
||||
}
|
||||
|
||||
public void setViewType(int viewType) {
|
||||
this.viewType = viewType;
|
||||
}
|
||||
|
||||
public void setStatusText(String statusText) {
|
||||
this.statusText = statusText;
|
||||
}
|
||||
|
||||
public String getStatusText() {
|
||||
return statusText;
|
||||
}
|
||||
}
|
||||
@@ -5,7 +5,6 @@ import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.Button;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
@@ -15,7 +14,6 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.mogo.commons.mvp.MvpFragment;
|
||||
import com.mogo.commons.network.SubscribeImpl;
|
||||
import com.mogo.commons.network.Utils;
|
||||
import com.mogo.service.MogoServicePaths;
|
||||
import com.mogo.service.network.IMogoNetwork;
|
||||
import com.mogo.utils.network.RequestOptions;
|
||||
@@ -24,6 +22,8 @@ import com.zhidao.mogo.module.event.panel.R;
|
||||
import com.zhidao.mogo.module.event.panel.adapter.ShareEventAdapter;
|
||||
import com.zhidao.mogo.module.event.panel.bean.ShareEventDescription;
|
||||
import com.zhidao.mogo.module.event.panel.bean.ShareEventItem;
|
||||
import com.zhidao.mogo.module.event.panel.bean.ShareEventItemEnum;
|
||||
import com.zhidao.mogo.module.event.panel.bean.ShareEventLoadMoreItem;
|
||||
import com.zhidao.mogo.module.event.panel.network.HostConstant;
|
||||
import com.zhidao.mogo.module.event.panel.network.EventApiService;
|
||||
import com.zhidao.mogo.module.event.panel.network.ShareEventParameter;
|
||||
@@ -46,7 +46,10 @@ public class ShareEventsFragment extends MvpFragment<ShareEventsFragment, ShareE
|
||||
private EventApiService eventApiService;
|
||||
private int pageNum = 1;
|
||||
private View emptyView;
|
||||
private Button shareBtn;
|
||||
|
||||
public int getPageNum() {
|
||||
return pageNum;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected int getLayoutId() {
|
||||
@@ -61,7 +64,7 @@ public class ShareEventsFragment extends MvpFragment<ShareEventsFragment, ShareE
|
||||
@Override
|
||||
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
|
||||
view = inflater.inflate(R.layout.module_event_panel_share_recylerview, container, false);
|
||||
emptyView = inflater.inflate(R.layout.module_event_panel_share_empty,container,false);
|
||||
emptyView = inflater.inflate(R.layout.module_event_panel_share_empty, container, false);
|
||||
initRecyclerView();
|
||||
initData();
|
||||
return view;
|
||||
@@ -69,7 +72,7 @@ public class ShareEventsFragment extends MvpFragment<ShareEventsFragment, ShareE
|
||||
|
||||
private void initRecyclerView() {
|
||||
recyclerView = view.findViewById(R.id.road_case_share_list);
|
||||
adapter = new ShareEventAdapter(getActivity(), dataArrayList);
|
||||
adapter = new ShareEventAdapter(getActivity(), dataArrayList, createPresenter());
|
||||
recyclerView.setAdapter(adapter);
|
||||
LinearLayoutManager linearLayoutManager =
|
||||
new LinearLayoutManager(getActivity(), LinearLayoutManager.VERTICAL, false);
|
||||
@@ -80,7 +83,7 @@ public class ShareEventsFragment extends MvpFragment<ShareEventsFragment, ShareE
|
||||
IMogoNetwork network = (IMogoNetwork) ARouter.getInstance().build(MogoServicePaths.PATH_SERVICES_NETWORK).navigation(getContext());
|
||||
this.eventApiService = network.create(EventApiService.class, HostConstant.getNetHost());
|
||||
|
||||
getShareEventDescription();
|
||||
// getShareEventDescription();
|
||||
getShareEventList(pageNum, 10);
|
||||
}
|
||||
|
||||
@@ -89,7 +92,7 @@ public class ShareEventsFragment extends MvpFragment<ShareEventsFragment, ShareE
|
||||
* */
|
||||
private void getShareEventDescription() {
|
||||
//ZD802B1932L00622 测试数据sn
|
||||
ShareEventParameter parameter = new ShareEventParameter(Utils.getSn());
|
||||
ShareEventParameter parameter = new ShareEventParameter("ZD802B1932L00622");
|
||||
Map<String, Object> parameters = new HashMap<>();
|
||||
parameters.put("data", GsonUtil.jsonFromObject(parameter));
|
||||
|
||||
@@ -118,8 +121,8 @@ public class ShareEventsFragment extends MvpFragment<ShareEventsFragment, ShareE
|
||||
/*
|
||||
* 分享列表
|
||||
* */
|
||||
private void getShareEventList(int page, int size) {
|
||||
ShareEventParameter parameter = new ShareEventParameter(Utils.getSn(), pageNum, 10);
|
||||
public void getShareEventList(int page, int size) {
|
||||
ShareEventParameter parameter = new ShareEventParameter("ZD802B1932L00622", page, 10);
|
||||
HashMap<String, Object> parameters = new HashMap<>();
|
||||
parameters.put("data", GsonUtil.jsonFromObject(parameter));
|
||||
|
||||
@@ -129,13 +132,40 @@ public class ShareEventsFragment extends MvpFragment<ShareEventsFragment, ShareE
|
||||
.subscribe(new SubscribeImpl<ShareEventItem>(RequestOptions.create(getContext())) {
|
||||
@Override
|
||||
public void onSuccess(ShareEventItem resultData) {
|
||||
if (resultData != null && resultData.getResult() != null
|
||||
&& resultData.getResult().getPage().getContent().size() > 0) {
|
||||
adapter.setEmptylist(false);
|
||||
dataArrayList.addAll(resultData.getResult().getPage().getContent());
|
||||
ShareEventLoadMoreItem item = new ShareEventLoadMoreItem();
|
||||
if (resultData != null && resultData.getResult() != null) {
|
||||
if (resultData.getResult().getPage() != null) {
|
||||
int total = resultData.getResult().getPage().getTotal();
|
||||
if (total == 0) {
|
||||
//空白
|
||||
item.setViewType(ShareEventItemEnum.ITEM_TYPE_SHARE_EMPTY);
|
||||
dataArrayList.add(item);
|
||||
} else {
|
||||
if (resultData.getResult().getPage().getContent().size() > 0) {
|
||||
//当前页有数据
|
||||
if (dataArrayList.size() > 0) {
|
||||
Object data = dataArrayList.get(dataArrayList.size() - 1);
|
||||
if (data instanceof ShareEventLoadMoreItem) {
|
||||
dataArrayList.remove(dataArrayList.size() - 1);
|
||||
}
|
||||
}
|
||||
dataArrayList.addAll(resultData.getResult().getPage().getContent());
|
||||
item.setViewType(ShareEventItemEnum.ITEM_TYPE_LOAD_MORE_STATUS);
|
||||
item.setStatusText("查看更早记录");
|
||||
} else {
|
||||
//当前页没有数据
|
||||
item.setViewType(ShareEventItemEnum.ITEM_TYPE_NO_MORE);
|
||||
item.setStatusText("没有更多了");
|
||||
}
|
||||
dataArrayList.add(item);
|
||||
}
|
||||
}
|
||||
Log.d(TAG, "分享列表---:" + dataArrayList.get(0));
|
||||
} else {
|
||||
adapter.setEmptylist(true);
|
||||
//空白
|
||||
item.setViewType(ShareEventItemEnum.ITEM_TYPE_SHARE_EMPTY);
|
||||
|
||||
dataArrayList.add(item);
|
||||
}
|
||||
adapter.notifyDataSetChanged();
|
||||
}
|
||||
@@ -147,9 +177,23 @@ public class ShareEventsFragment extends MvpFragment<ShareEventsFragment, ShareE
|
||||
});
|
||||
}
|
||||
|
||||
private void addLastData(ArrayList dataArray, int total) {
|
||||
ShareEventLoadMoreItem item = new ShareEventLoadMoreItem();
|
||||
if (total > 10) {
|
||||
if (pageNum <= 1) {//没有分享
|
||||
item.setViewType(ShareEventItemEnum.ITEM_TYPE_SHARE_EMPTY);
|
||||
} else {//没有更多了
|
||||
item.setViewType(ShareEventItemEnum.ITEM_TYPE_NO_MORE);
|
||||
}
|
||||
dataArray.add(item);
|
||||
}
|
||||
}
|
||||
|
||||
@NonNull
|
||||
@Override
|
||||
protected ShareEventsPresenter createPresenter() {
|
||||
return new ShareEventsPresenter(this);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -8,4 +8,9 @@ public class ShareEventsPresenter extends Presenter <ShareEventsFragment>{
|
||||
public ShareEventsPresenter(IView view) {
|
||||
super((ShareEventsFragment) view);
|
||||
}
|
||||
|
||||
public void getMoreShareEventList(){
|
||||
mView.getShareEventList(mView.getPageNum()+1,10);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 2.4 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 6.7 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 2.5 KiB |
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item
|
||||
android:id="@android:id/background"
|
||||
android:drawable="@drawable/icon_enthusiasm_unchoose">
|
||||
</item>
|
||||
<item
|
||||
android:id="@android:id/secondaryProgress"
|
||||
android:drawable="@drawable/icon_enthusiasm_second">
|
||||
</item>
|
||||
<item
|
||||
android:id="@android:id/progress"
|
||||
android:drawable="@drawable/icon_enthusiasm_choose">
|
||||
</item>
|
||||
|
||||
</layer-list>
|
||||
@@ -75,17 +75,20 @@
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/share_index"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:background="@drawable/amap_ride" />
|
||||
<RatingBar
|
||||
android:id="@+id/rating_bar"
|
||||
style="@style/customRatingBarStyle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginTop="20dp"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/share_index_des"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="30dp"
|
||||
android:gravity="center"
|
||||
android:paddingBottom="0dp"
|
||||
android:text="热心指数"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="20sp" />
|
||||
|
||||
@@ -1,15 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal">
|
||||
|
||||
<Button
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:id="@+id/event_share_load_status"
|
||||
android:textColor="#000000"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="没有更多了"
|
||||
android:textSize="18sp"
|
||||
android:gravity="center"/>
|
||||
android:textColor="#000000"
|
||||
android:textSize="18sp"/>
|
||||
|
||||
</RelativeLayout>
|
||||
@@ -1,2 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources></resources>
|
||||
<resources>
|
||||
<style name="customRatingBarStyle" parent="@style/Widget.AppCompat.RatingBar">
|
||||
<item name="android:minHeight">20dp</item>
|
||||
<item name="android:maxHeight">20dp</item>
|
||||
<item name="android:maxWidth">20dp</item>
|
||||
<item name="android:minWidth">20dp</item>
|
||||
<item name="android:spacing">4dp</item>
|
||||
<item name="android:numStars">5</item>
|
||||
<item name="android:rating">1</item>
|
||||
<item name="android:stepSize">0.5</item>
|
||||
<item name="android:progressDrawable">@drawable/share_rating_bar</item>
|
||||
</style>
|
||||
</resources>
|
||||
Reference in New Issue
Block a user