[add] 检测指标详情界面取值index修改, UI优化(边框添加,单元格网格宽度,色值修改)
This commit is contained in:
@@ -56,8 +56,8 @@ public class CheckInfoAdapter extends RecyclerView.Adapter {
|
||||
((CheckInfoViewHolder) holder).mTextView.setText("运行状态");
|
||||
} else {
|
||||
try {
|
||||
if ((position - 4) < showData.size()) {
|
||||
int index = position - 4;
|
||||
if ((position - 4) < showData.size() * 2) {
|
||||
int index = (position - 4) / 2;
|
||||
CheckResultData.CheckListItem positionItem = showData.get(index);
|
||||
if (isEven(position) == true) {//偶数隐藏图片显示检测指标
|
||||
((CheckInfoViewHolder) holder).checkIcon.setVisibility(View.GONE);
|
||||
@@ -94,7 +94,7 @@ public class CheckInfoAdapter extends RecyclerView.Adapter {
|
||||
|
||||
@Override
|
||||
public int getItemCount() {
|
||||
return showData.size() + 4;
|
||||
return showData.size() * 2 + 4;
|
||||
}
|
||||
|
||||
public class CheckInfoViewHolder extends RecyclerView.ViewHolder {
|
||||
|
||||
@@ -61,7 +61,8 @@ public class CheckInfoListDialog extends BaseFloatDialog {
|
||||
layoutManager.setOrientation(GridLayoutManager.VERTICAL);
|
||||
//网格绘制
|
||||
try {
|
||||
CheckInfoGridItemDivider gridLayoutDivider = new CheckInfoGridItemDivider(3, Color.parseColor("#767FCD"));
|
||||
CheckInfoGridItemDivider gridLayoutDivider = new CheckInfoGridItemDivider(1,
|
||||
(mContext.getResources().getColor(R.color.check_info_position_line_color)));
|
||||
mRecyclerView.addItemDecoration(gridLayoutDivider);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<stroke
|
||||
android:width="3px"
|
||||
android:color="@color/check_info_shape_color" />
|
||||
<padding
|
||||
android:bottom="2px"
|
||||
android:left="2px"
|
||||
android:right="2px"
|
||||
android:top="2px" />
|
||||
</shape>
|
||||
@@ -14,7 +14,7 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
app:layout_constraintTop_toTopOf="parent"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/btnBack"
|
||||
|
||||
@@ -36,7 +36,8 @@
|
||||
android:layout_marginLeft="@dimen/dp_143"
|
||||
android:layout_marginTop="@dimen/dp_184"
|
||||
android:layout_marginRight="@dimen/dp_143"
|
||||
android:layout_marginBottom="@dimen/dp_143"
|
||||
android:layout_marginBottom="@dimen/dp_80"
|
||||
android:background="@drawable/check_recycler_shape"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
android:layout_marginStart="@dimen/dp_100"
|
||||
android:layout_marginTop="@dimen/dp_15"
|
||||
android:layout_marginEnd="@dimen/dp_100"
|
||||
android:layout_marginBottom="@dimen/dp_15"
|
||||
android:layout_marginBottom="@dimen/dp_35"
|
||||
android:background="@drawable/check_list_item_back">
|
||||
|
||||
<TextView
|
||||
|
||||
@@ -9,5 +9,8 @@
|
||||
<color name="check_little_btn_green">#7AFF87</color>
|
||||
<color name="check_list_item_back">#242B59</color>
|
||||
<color name="check_icon_error_color">#EE3132</color>
|
||||
<color name="check_info_position_line_color">#666DA5</color>
|
||||
<color name="check_info_shape_color">#767FCD</color>
|
||||
|
||||
|
||||
</resources>
|
||||
Reference in New Issue
Block a user