Parcourir la source

1.提交测试背景图和模板类型

FailedToRead il y a 2 ans
Parent
commit
bec2324e0f
35 fichiers modifiés avec 1085 ajouts et 214 suppressions
  1. 17 0
      .idea/deploymentTargetDropDown.xml
  2. 11 4
      .idea/misc.xml
  3. 4 3
      app/build.gradle
  4. BIN
      app/libs/mi-soundbox-command-sdk.aar
  5. 43 10
      app/src/exception/layout/adapter_item_cusview_model_view_d.xml
  6. 18 16
      app/src/exception/layout/cusview_model_view_d.xml
  7. 82 0
      app/src/fragmentRecommend/layout/adapter_item_cusview_model_view_f.xml
  8. 1 1
      app/src/main/java/com/edufound/reader/application/EApplication.java
  9. 35 44
      app/src/main/java/com/edufound/reader/cusview/ModelViewB.java
  10. 48 4
      app/src/main/java/com/edufound/reader/cusview/ModelViewC.java
  11. 19 15
      app/src/main/java/com/edufound/reader/cusview/ModelViewD.java
  12. 187 0
      app/src/main/java/com/edufound/reader/cusview/ModelViewE.java
  13. 79 0
      app/src/main/java/com/edufound/reader/cusview/ModelViewF.java
  14. 102 65
      app/src/main/java/com/edufound/reader/presenter/MainPresenter.java
  15. 37 25
      app/src/main/java/com/edufound/reader/util/GlideUtils.java
  16. BIN
      app/src/main/res/drawable/cusview_model_view_b_enter_btn_bg.png
  17. BIN
      app/src/main/res/drawable/cusview_model_view_b_info_btn_bg.png
  18. BIN
      app/src/main/res/drawable/cusview_model_view_f_item_bg.png
  19. 8 0
      app/src/main/res/drawable/cusview_model_view_f_layout_divier.xml
  20. BIN
      app/src/main/res/drawable/model_view_c_recyclerview_bottom_frame.png
  21. BIN
      app/src/main/res/drawable/model_view_d_item_btn_bt.png
  22. BIN
      app/src/main/res/drawable/model_view_d_rult_btn_bt.png
  23. BIN
      app/src/main/res/drawable/ranklist_one.png
  24. BIN
      app/src/main/res/drawable/ranklist_three.png
  25. BIN
      app/src/main/res/drawable/ranklist_two.png
  26. 15 12
      app/src/main/res/layout/adapter_item_cusview_model_view_c.xml
  27. 119 0
      app/src/main/res/layout/cusview_model_view_b.xml
  28. 22 15
      app/src/main/res/layout/cusview_model_view_c.xml
  29. 200 0
      app/src/main/res/layout/cusview_model_view_e.xml
  30. 38 0
      app/src/main/res/layout/cusview_model_view_f.xml
  31. BIN
      app/src/testimg/drawable/test_double_btn_bg.png
  32. BIN
      app/src/testimg/drawable/test_four_img.png
  33. BIN
      app/src/testimg/drawable/test_lijicansai.png
  34. BIN
      app/src/testimg/drawable/test_view_f_bg.png
  35. BIN
      app/src/testimg/drawable/test_youxiuzuopin.png

+ 17 - 0
.idea/deploymentTargetDropDown.xml

@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4">
+  <component name="deploymentTargetDropDown">
+    <runningDeviceTargetSelectedWithDropDown>
+      <Target>
+        <type value="RUNNING_DEVICE_TARGET" />
+        <deviceKey>
+          <Key>
+            <type value="SERIAL_NUMBER" />
+            <value value="27414/A0QE28771" />
+          </Key>
+        </deviceKey>
+      </Target>
+    </runningDeviceTargetSelectedWithDropDown>
+    <timeTargetWasSelectedWithDropDown value="2022-05-24T06:46:28.107238300Z" />
+  </component>
+</project>

+ 11 - 4
.idea/misc.xml

@@ -124,11 +124,13 @@
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/exception/drawable/adapter_item_video_tab_item_bg.xml" value="0.2165" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/exception/drawable/list_divider_horizontal.xml" value="0.2185" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/exception/layout/activity_event_pay.xml" value="0.22" />
-        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/exception/layout/adapter_item_cusview_model_view_d.xml" value="0.33" />
-        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/exception/layout/cusview_model_view_d.xml" value="0.22992700729927007" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/exception/layout/adapter_item_cusview_model_view_d.xml" value="0.9" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/exception/layout/cusview_model_view_d.xml" value="0.67" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/exception/layout/popupwindow_webs_events.xml" value="0.2572992700729927" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/fragmentRecommend/drawable/activity_comment_quick_item_one_bg.xml" value="0.2165" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/fragmentRecommend/drawable/slidevideo_switch_track_selector.xml" value="0.2005" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/fragmentRecommend/layout/adapter_item_cusview_model_view_f.xml" value="0.75" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/fragmentRecommend/layout/cusview_model_view_f.xml" value="0.24939172749391728" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/fragmentRecommend/layout/fragment_main_recommend.xml" value="0.5" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/fragmentRecommend/layout/popupwindow_myorder.xml" value="0.2871046228710462" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/fragmentRecommend/layout/popupwindow_record_remove.xml" value="0.2913625304136253" />
@@ -141,6 +143,7 @@
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/drawable/activity_comment_item_divier.xml" value="0.2005" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/drawable/activity_saffloer_task_divier.xml" value="0.2165" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/drawable/cusjzplayer_controller_seekbar.xml" value="0.2165" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/drawable/cusview_model_view_f_layout_divier.xml" value="0.2345" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/drawable/main_left_tab_character_selector.xml" value="0.2185" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/drawable/main_left_tab_myinfo_selector.xml" value="0.2185" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/drawable/main_left_tab_recommend_selector.xml" value="0.2185" />
@@ -159,11 +162,15 @@
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/activity_test.xml" value="0.24452554744525548" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/activity_userinfo_setting.xml" value="0.5185676392572944" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/activity_web.xml" value="0.18" />
-        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/adapter_item_cusview_model_view_c.xml" value="0.25" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/adapter_item_cusview_model_view_c.xml" value="0.75" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/adapter_item_popupwindow_myorder.xml" value="0.75" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/adapter_item_record_user.xml" value="1.0" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/adapter_item_safflower_v2.xml" value="0.19829683698296838" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/adapter_item_slidevideo.xml" value="0.2975260416666667" />
-        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/cusview_model_view_c.xml" value="0.33" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/cusview_model_view_b.xml" value="0.2" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/cusview_model_view_c.xml" value="0.6722408026755853" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/cusview_model_view_e.xml" value="0.75" />
+        <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/cusview_model_view_f.xml" value="0.5" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/fragment_main_character.xml" value="0.2615571776155718" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/fragment_main_event.xml" value="0.16" />
         <entry key="..\:/Work_Space/Android_Space/efunboxReader/efunboxReader-android-master/app/src/main/res/layout/fragment_main_user.xml" value="0.16" />

+ 4 - 3
app/build.gradle

@@ -8,11 +8,10 @@ def releaseTime() {
 
 android {
     compileSdkVersion 30
-    buildToolsVersion "30.0.3"
 
     defaultConfig {
         applicationId "com.edufound.reader"
-        minSdkVersion 26 //>23导致无法直接签名
+        minSdkVersion 23 //>23导致无法直接签名
         targetSdkVersion 30
         versionCode 20
         versionName "2.0"
@@ -21,6 +20,7 @@ android {
         ndk {
             abiFilters "armeabi-v7a"
         }
+        multiDexEnabled true
     }
     signingConfigs {
         efunboxKey {
@@ -74,7 +74,8 @@ android {
                     'src/fragmentRecommend',   //首页推荐
                     'src/fragmentUser',//首页我的
                     'src/activityLoginAlert',//登录弹窗
-                    'src/exception'//异常弹窗
+                    'src/exception',//异常弹窗
+                    'src/testimg'//测试图片
             ]
         }
     }

BIN
app/libs/mi-soundbox-command-sdk.aar


+ 43 - 10
app/src/exception/layout/adapter_item_cusview_model_view_d.xml

@@ -1,22 +1,21 @@
 <?xml version="1.0" encoding="utf-8"?>
 <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:app="http://schemas.android.com/apk/res-auto"
-    android:layout_width="299dp"
-    android:layout_height="235dp"
+    android:layout_width="309dp"
+    android:layout_height="260dp"
     android:layout_gravity="center"
     android:paddingLeft="10dp"
-    android:paddingTop="10dp"
     android:paddingRight="10dp">
 
     <ImageView
         android:layout_width="match_parent"
         android:layout_height="match_parent"
-        android:background="@color/blueviolet"></ImageView>
+        android:background="@drawable/model_view_d_item_btn_bt"></ImageView>
 
     <ImageView
         android:id="@+id/adapter_item_cusview_model_view_d_icon"
-        android:layout_width="260dp"
-        android:layout_height="146dp"
+        android:layout_width="258dp"
+        android:layout_height="145dp"
         android:layout_marginTop="10dp"
         android:background="@color/red"
         android:scaleType="fitXY"
@@ -66,16 +65,50 @@
     </LinearLayout>
 
 
-    <ImageView
+    <com.edufound.reader.cusview.RoundFrameLayout
+        android:id="@+id/adapter_item_cusview_model_view_d_ranklist"
+        android:layout_width="96dp"
+        android:layout_height="25dp"
+        android:background="#6BADFF"
+        app:layout_constraintBottom_toBottomOf="parent"
+        app:layout_constraintEnd_toEndOf="parent"
+        app:layout_constraintHorizontal_bias="0.1"
+        app:layout_constraintStart_toStartOf="parent"
+        app:layout_constraintTop_toBottomOf="@+id/linearLayout2"
+        app:layout_constraintVertical_bias="0.26999998"
+        app:radio="10">
+
+        <TextView
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:gravity="center"
+            android:text="查看排行榜"
+            android:textColor="#FFFFFF"
+            android:textSize="12dp"></TextView>
+
+    </com.edufound.reader.cusview.RoundFrameLayout>
+
+    <com.edufound.reader.cusview.RoundFrameLayout
         android:id="@+id/adapter_item_cusview_model_view_d_enter"
         android:layout_width="96dp"
         android:layout_height="25dp"
-        android:layout_marginBottom="10dp"
-        android:background="@color/green"
+        android:background="#32C965"
         app:layout_constraintBottom_toBottomOf="parent"
         app:layout_constraintEnd_toEndOf="parent"
+        app:layout_constraintHorizontal_bias="0.9"
         app:layout_constraintStart_toStartOf="parent"
         app:layout_constraintTop_toBottomOf="@+id/linearLayout2"
-        app:layout_constraintVertical_bias="1.0"></ImageView>
+        app:layout_constraintVertical_bias="0.29000002"
+        app:radio="10">
+
+        <TextView
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:gravity="center"
+            android:text="立即参赛"
+            android:textColor="#FFFFFF"
+            android:textSize="12dp"></TextView>
+
+    </com.edufound.reader.cusview.RoundFrameLayout>
 
 </androidx.constraintlayout.widget.ConstraintLayout>

+ 18 - 16
app/src/exception/layout/cusview_model_view_d.xml

@@ -12,31 +12,31 @@
         android:layout_height="match_parent"
         android:scaleType="fitXY"></ImageView>
 
-    <ImageView
+    <FrameLayout
         android:id="@+id/model_view_d_rule"
         android:layout_width="150dp"
         android:layout_height="50dp"
         android:layout_marginTop="26dp"
-        android:layout_marginEnd="190dp"
-        android:background="@color/red"
+        android:layout_marginEnd="39dp"
+        android:background="@drawable/model_view_d_rult_btn_bt"
         app:layout_constraintEnd_toEndOf="parent"
-        app:layout_constraintTop_toTopOf="parent"></ImageView>
+        app:layout_constraintTop_toTopOf="parent">
+
+        <TextView
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:gravity="center"
+            android:text="活动规则"
+            android:textColor="#333333"
+            android:textSize="26dp"></TextView>
+    </FrameLayout>
 
-    <ImageView
-        android:id="@+id/model_view_d_ranking_list"
-        android:layout_width="150dp"
-        android:layout_height="50dp"
-        android:layout_marginTop="26dp"
-        android:layout_marginEnd="20dp"
-        android:background="@color/red"
-        app:layout_constraintEnd_toEndOf="parent"
-        app:layout_constraintTop_toTopOf="parent"></ImageView>
 
     <GridLayout
         android:id="@+id/model_view_d_gridlayout"
         android:layout_width="match_parent"
-        android:layout_height="480dp"
-        android:layout_marginBottom="22dp"
+        android:layout_height="475dp"
+        android:layout_marginBottom="12dp"
         android:columnCount="2"
         android:orientation="horizontal"
         android:rowCount="2"
@@ -44,5 +44,7 @@
         app:layout_constraintEnd_toEndOf="parent"
         app:layout_constraintStart_toStartOf="parent"
         app:layout_constraintTop_toTopOf="parent"
-        app:layout_constraintVertical_bias="1.0"></GridLayout>
+        app:layout_constraintVertical_bias="1.0">
+
+    </GridLayout>
 </androidx.constraintlayout.widget.ConstraintLayout>

+ 82 - 0
app/src/fragmentRecommend/layout/adapter_item_cusview_model_view_f.xml

@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="utf-8"?>
+<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    android:layout_width="381dp"
+    android:layout_height="112dp"
+    android:layout_gravity="center"
+    android:background="@drawable/cusview_model_view_f_item_bg">
+
+
+    <ImageView
+        android:id="@+id/cusview_model_view_f_layout_item_icon"
+        android:layout_width="94dp"
+        android:layout_height="76dp"
+        android:layout_marginStart="25dp"
+        android:background="@color/bisque"
+        android:scaleType="fitXY"
+        app:layout_constraintBottom_toBottomOf="parent"
+        app:layout_constraintStart_toStartOf="parent"
+        app:layout_constraintTop_toTopOf="parent"
+        app:layout_constraintVertical_bias="0.45999998"></ImageView>
+
+    <TextView
+        android:id="@+id/cusview_model_view_f_layout_item_name"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginStart="15dp"
+        android:text="春夏秋冬"
+        android:textColor="#314051"
+        android:textSize="18dp"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintStart_toEndOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintVertical_bias="0.13"></TextView>
+
+    <TextView
+        android:id="@+id/cusview_model_view_f_layout_item_enter_num"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginStart="15dp"
+        android:text="248587"
+        android:textColor="#77CE6A"
+        android:textSize="18dp"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintStart_toEndOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintVertical_bias="0.85"></TextView>
+
+    <TextView
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:text="参与"
+        android:textColor="#999999"
+        android:textSize="18dp"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintStart_toEndOf="@+id/cusview_model_view_f_layout_item_enter_num"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintVertical_bias="0.85"></TextView>
+
+
+    <FrameLayout
+        android:id="@+id/cusview_model_view_f_layout_item_enter_btn"
+        android:layout_width="118dp"
+        android:layout_height="34dp"
+        android:background="@drawable/cusview_model_view_b_enter_btn_bg"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintEnd_toEndOf="parent"
+        app:layout_constraintHorizontal_bias="0.84"
+        app:layout_constraintStart_toEndOf="@+id/cusview_model_view_f_layout_item_icon"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_f_layout_item_icon">
+
+        <TextView
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_gravity="center"
+            android:gravity="center"
+            android:text="立即参赛"
+            android:textColor="#FFFFFF"
+            android:textSize="15dp"></TextView>
+
+    </FrameLayout>
+
+</androidx.constraintlayout.widget.ConstraintLayout>

+ 1 - 1
app/src/main/java/com/edufound/reader/application/EApplication.java

@@ -59,7 +59,7 @@ public class EApplication extends Application {
     public void onCreate() {
         super.onCreate();
         try {
-            Consts.setIsDebug(false);
+            Consts.setIsDebug(true);
             Consts.setmApplicAtion(this);
 
             //初始化异常监听

+ 35 - 44
app/src/main/java/com/edufound/reader/cusview/ModelViewB.java

@@ -2,16 +2,20 @@ package com.edufound.reader.cusview;
 
 import android.content.Context;
 import android.graphics.Color;
+import android.text.TextUtils;
 import android.util.AttributeSet;
 import android.view.Gravity;
+import android.view.LayoutInflater;
 import android.view.View;
-import android.view.ViewGroup;
 import android.widget.FrameLayout;
 import android.widget.ImageView;
 import android.widget.LinearLayout;
+import android.widget.TextView;
 
 import androidx.annotation.Nullable;
+import androidx.constraintlayout.widget.ConstraintLayout;
 
+import com.edufound.reader.R;
 import com.edufound.reader.util.GlideUtils;
 import com.edufound.reader.util.SizeUtils;
 
@@ -21,10 +25,18 @@ import com.edufound.reader.util.SizeUtils;
 public class ModelViewB extends FrameLayout {
 
     public Context mContext;
+    ImageView mBackGroundImg;
+    TextView mTextName;
+    TextView mTextTime;
+    TextView mTextEnterNum;
+    FrameLayout btnLeft;
+    FrameLayout btnRight;
+    private LayoutInflater mLayoutInflater;
 
     public ModelViewB(Context context) {
         super(context);
         mContext = context;
+        mLayoutInflater = LayoutInflater.from(mContext);
     }
 
     public ModelViewB(Context context, @Nullable AttributeSet attrs) {
@@ -36,31 +48,30 @@ public class ModelViewB extends FrameLayout {
     }
 
 
-    public void initView(String url, OnClickBtnListener clickListener) {
+    public void initView() {
         LayoutParams layoutParams = new LayoutParams(SizeUtils.dp2px(mContext, 644)
                 , SizeUtils.dp2px(mContext, 598));
         this.setLayoutParams(layoutParams);
-        this.setBackgroundColor(Color.BLUE);
-        //背景图片
-        ImageView imageView = new ImageView(mContext);
-        imageView.setScaleType(ImageView.ScaleType.FIT_XY);
-        imageView.setLayoutParams(new LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT));
-        GlideUtils.loadImageSizeKipMemoryCache(mContext, url, imageView);
-
-        //底部按钮layout
-        LinearLayout btnLayout = new LinearLayout(mContext);
-        btnLayout.setOrientation(LinearLayout.HORIZONTAL);
-        FrameLayout.LayoutParams btnLayoutParams = new FrameLayout.LayoutParams(SizeUtils.dp2px(mContext, 644), SizeUtils.dp2px(mContext, 65));
-        btnLayoutParams.gravity = Gravity.BOTTOM;
-        btnLayout.setLayoutParams(btnLayoutParams);
-        btnLayout.setBackgroundColor(Color.LTGRAY);
-        //底部按钮
-        LinearLayout.LayoutParams btnFrameParams = new LinearLayout.LayoutParams(0, SizeUtils.dp2px(mContext, 65));
-        btnFrameParams.weight = 1;
-        btnFrameParams.bottomMargin = SizeUtils.dp2px(mContext, 40);
-        FrameLayout btnLeft = new FrameLayout(mContext);
-        btnLeft.setLayoutParams(btnFrameParams);
-        btnLeft.setBackgroundColor(Color.RED);
+        ConstraintLayout modelViewB = (ConstraintLayout) mLayoutInflater.inflate(R.layout.cusview_model_view_b, null);
+        mBackGroundImg = modelViewB.findViewById(R.id.cusview_model_view_b_background);
+        mTextName = modelViewB.findViewById(R.id.cusview_model_view_b_name);
+        mTextTime = modelViewB.findViewById(R.id.cusview_model_view_b_time);
+        mTextEnterNum = modelViewB.findViewById(R.id.cusview_model_view_b_enter_num);
+        btnLeft = modelViewB.findViewById(R.id.cusview_model_view_b_info_btn);
+        btnRight = modelViewB.findViewById(R.id.cusview_model_view_b_enter_btn);
+        addView(modelViewB);
+    }
+
+
+    public void setView(String url, String name, String time, String enterNum, OnClickBtnListener clickListener) {
+        if (!TextUtils.isEmpty(url)) {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, url, mBackGroundImg);
+        } else {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, R.drawable.test_double_btn_bg, mBackGroundImg);
+        }
+        mTextName.setText(name);
+        mTextTime.setText(time);
+        mTextEnterNum.setText(enterNum);
         btnLeft.setOnClickListener(new OnClickListener() {
             @Override
             public void onClick(View v) {
@@ -69,9 +80,7 @@ public class ModelViewB extends FrameLayout {
                 }
             }
         });
-        FrameLayout btnRight = new FrameLayout(mContext);
-        btnRight.setLayoutParams(btnFrameParams);
-        btnRight.setBackgroundColor(Color.YELLOW);
+
         btnRight.setOnClickListener(new OnClickListener() {
             @Override
             public void onClick(View v) {
@@ -80,24 +89,6 @@ public class ModelViewB extends FrameLayout {
                 }
             }
         });
-        btnLayout.addView(btnLeft);
-        btnLayout.addView(btnRight);
-
-
-        FrameLayout.LayoutParams btnParams = new FrameLayout.LayoutParams(SizeUtils.dp2px(mContext, 244), SizeUtils.dp2px(mContext, 65));
-        btnParams.gravity = Gravity.CENTER;
-        ImageView leftBtnImg = new ImageView(mContext);
-        leftBtnImg.setLayoutParams(btnParams);
-        leftBtnImg.setBackgroundColor(Color.YELLOW);
-        ImageView rightBtnImg = new ImageView(mContext);
-        rightBtnImg.setLayoutParams(btnParams);
-        rightBtnImg.setBackgroundColor(Color.BLACK);
-        btnLeft.addView(leftBtnImg);
-        btnRight.addView(rightBtnImg);
-
-        //添加view
-        addView(imageView);
-        addView(btnLayout);
     }
 
     public interface OnClickBtnListener {

+ 48 - 4
app/src/main/java/com/edufound/reader/cusview/ModelViewC.java

@@ -2,6 +2,8 @@ package com.edufound.reader.cusview;
 
 import android.annotation.SuppressLint;
 import android.content.Context;
+import android.graphics.Color;
+import android.text.TextUtils;
 import android.util.AttributeSet;
 import android.view.LayoutInflater;
 import android.view.View;
@@ -12,6 +14,7 @@ import android.widget.TextView;
 
 import androidx.annotation.NonNull;
 import androidx.annotation.Nullable;
+import androidx.constraintlayout.widget.ConstraintLayout;
 import androidx.recyclerview.widget.LinearLayoutManager;
 import androidx.recyclerview.widget.RecyclerView;
 
@@ -25,7 +28,7 @@ import java.util.List;
 
 /**
  * 上面一个课程,下面一个list展示所有读过课程的用户
- * */
+ */
 public class ModelViewC extends FrameLayout {
     Context mContext;
     private LayoutInflater mLayoutInflater;
@@ -55,8 +58,30 @@ public class ModelViewC extends FrameLayout {
                 , SizeUtils.dp2px(mContext, 598));
         this.setLayoutParams(layoutParams);
         View modelCView = mLayoutInflater.inflate(R.layout.cusview_model_view_c, null);
-        ImageView backgournd = modelCView.findViewById(R.id.model_view_c_background);
-        GlideUtils.loadImageSizeKipMemoryCache(mContext, bgUrl, backgournd);
+        ImageView backgournd = modelCView.findViewById(R.id.cusview_model_view_e_background);
+        if (!TextUtils.isEmpty(bgUrl)) {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, bgUrl, backgournd);
+        } else {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, R.drawable.test_youxiuzuopin, backgournd);
+        }
+        FrameLayout mshowRule = modelCView.findViewById(R.id.cusview_model_view_c_show_rule);
+        mshowRule.setOnClickListener(new OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                //显示规
+                CusToast.getInstance(mContext).show("显示规则弹窗还是什么玩意儿", 2000);
+            }
+        });
+
+        //cusview_model_view_c_course_layout
+        ConstraintLayout mCourseLayout = modelCView.findViewById(R.id.cusview_model_view_c_course_layout);
+        mCourseLayout.setOnClickListener(new OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                CusToast.getInstance(mContext).show("去朗读页面", 2000);
+            }
+        });
+
         RecyclerView mRecyclerView = modelCView.findViewById(R.id.model_view_c_recyclerview);
         mRecyclerView.setLayoutManager(new LinearLayoutManager(mContext, LinearLayoutManager.VERTICAL, false));
 
@@ -91,8 +116,25 @@ public class ModelViewC extends FrameLayout {
 
         @Override
         public void onBindViewHolder(@NonNull ModelViewCViewHolder holder, @SuppressLint("RecyclerView") int position) {
+            switch (position) {
+                case 0:
+                    holder.mItemIcon.setBackgroundResource(R.drawable.ranklist_one);
+                    holder.mScore.setTextColor(Color.parseColor("#FF6984"));
+                    break;
+                case 1:
+                    holder.mItemIcon.setBackgroundResource(R.drawable.ranklist_two);
+                    holder.mScore.setTextColor(Color.parseColor("#FF6984"));
+                    break;
+                case 2:
+                    holder.mItemIcon.setBackgroundResource(R.drawable.ranklist_three);
+                    holder.mScore.setTextColor(Color.parseColor("#FF6984"));
+                    break;
+                default:
+                    holder.mItemIcon.setText(position + "");
+                    break;
+            }
             holder.mNickName.setText(mListData.get(position));
-            holder.mScore.setText(mListData.get(position) + "分数");
+            holder.mScore.setText(mListData.get(position) + "分");
             if (mItemClickListener != null) {
                 holder.itemView.setOnClickListener(new OnClickListener() {
                     @Override
@@ -126,11 +168,13 @@ public class ModelViewC extends FrameLayout {
 class ModelViewCViewHolder extends RecyclerView.ViewHolder {
 
 
+    TextView mItemIcon;
     TextView mNickName;
     TextView mScore;
 
     public ModelViewCViewHolder(@NonNull View itemView) {
         super(itemView);
+        mItemIcon = itemView.findViewById(R.id.adapter_item_cusview_model_view_c_icon);
         mNickName = itemView.findViewById(R.id.adapter_item_cusview_model_view_c_nickname);
         mScore = itemView.findViewById(R.id.adapter_item_cusview_model_view_c_score);
     }

+ 19 - 15
app/src/main/java/com/edufound/reader/cusview/ModelViewD.java

@@ -1,6 +1,7 @@
 package com.edufound.reader.cusview;
 
 import android.content.Context;
+import android.text.TextUtils;
 import android.util.AttributeSet;
 import android.view.Gravity;
 import android.view.LayoutInflater;
@@ -24,6 +25,9 @@ public class ModelViewD extends FrameLayout {
 
     Context mContext;
     private LayoutInflater mLayoutInflater;
+    private ImageView backgournd;
+    private GridLayout gridLayout;
+    FrameLayout rule;
 
     public ModelViewD(@NonNull Context context) {
         super(context);
@@ -39,30 +43,32 @@ public class ModelViewD extends FrameLayout {
         super(context, attrs, defStyleAttr);
     }
 
-    public void initView(String bgUrl, List<String> listData, OnClickBtnListener listener) {
+    public void initView() {
         LayoutParams layoutParams = new LayoutParams(SizeUtils.dp2px(mContext, 644)
                 , SizeUtils.dp2px(mContext, 598));
         this.setLayoutParams(layoutParams);
         layoutParams.gravity = Gravity.CENTER;
         View modelDView = mLayoutInflater.inflate(R.layout.cusview_model_view_d, null);
-        ImageView backgournd = modelDView.findViewById(R.id.model_view_d_background);
-        GlideUtils.loadImageSizeKipMemoryCache(mContext, bgUrl, backgournd);
-        ImageView rule = modelDView.findViewById(R.id.model_view_d_rule);
-        ImageView rankingList = modelDView.findViewById(R.id.model_view_d_ranking_list);
+        backgournd = modelDView.findViewById(R.id.model_view_d_background);
+        rule = modelDView.findViewById(R.id.model_view_d_rule);
+
+        gridLayout = modelDView.findViewById(R.id.model_view_d_gridlayout);
+
+        addView(modelDView);
+    }
+
+    public void setView(String bgUrl, List<String> listData, OnClickBtnListener listener) {
+        if (!TextUtils.isEmpty(bgUrl)) {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, bgUrl, backgournd);
+        } else {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, R.drawable.test_four_img, backgournd);
+        }
         rule.setOnClickListener(new OnClickListener() {
             @Override
             public void onClick(View v) {
                 listener.clickLeft(null);
             }
         });
-        rankingList.setOnClickListener(new OnClickListener() {
-            @Override
-            public void onClick(View v) {
-                listener.clickRight(null);
-            }
-        });
-
-        GridLayout gridLayout = modelDView.findViewById(R.id.model_view_d_gridlayout);
         for (int i = 0; i < listData.size(); i++) {
             View itemView = mLayoutInflater.inflate(R.layout.adapter_item_cusview_model_view_d, null);
             GridLayout.LayoutParams gridItemParams = new GridLayout.LayoutParams();
@@ -85,13 +91,11 @@ public class ModelViewD extends FrameLayout {
                 }
             });
         }
-        addView(modelDView);
     }
 
     public interface OnClickBtnListener {
         void clickLeft(Object object);
 
-        void clickRight(Object object);
 
         void clickItem(Object object);
     }

+ 187 - 0
app/src/main/java/com/edufound/reader/cusview/ModelViewE.java

@@ -0,0 +1,187 @@
+package com.edufound.reader.cusview;
+
+import android.annotation.SuppressLint;
+import android.content.Context;
+import android.text.TextUtils;
+import android.util.AttributeSet;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.view.ViewGroup;
+import android.widget.FrameLayout;
+import android.widget.ImageView;
+import android.widget.TextView;
+
+import androidx.annotation.NonNull;
+import androidx.annotation.Nullable;
+import androidx.constraintlayout.widget.ConstraintLayout;
+import androidx.recyclerview.widget.LinearLayoutManager;
+import androidx.recyclerview.widget.RecyclerView;
+
+import com.edufound.reader.R;
+import com.edufound.reader.util.GlideUtils;
+import com.edufound.reader.util.SizeUtils;
+
+import java.util.ArrayList;
+import java.util.List;
+
+
+/**
+ * 上面一个课程,下面一个list展示所有读过课程的用户
+ */
+public class ModelViewE extends FrameLayout {
+    Context mContext;
+    private LayoutInflater mLayoutInflater;
+    private onItemClickListener mItemClickListener;
+
+
+    public ModelViewE(@NonNull Context context) {
+        super(context);
+        mContext = context;
+        mLayoutInflater = LayoutInflater.from(context);
+    }
+
+    public ModelViewE(@NonNull Context context, @Nullable AttributeSet attrs) {
+        super(context, attrs);
+    }
+
+    public ModelViewE(@NonNull Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
+        super(context, attrs, defStyleAttr);
+    }
+
+    public void setItemClickListener(onItemClickListener listener) {
+        mItemClickListener = listener;
+    }
+
+    public void initView(String bgUrl) {
+        LayoutParams layoutParams = new LayoutParams(SizeUtils.dp2px(mContext, 428)
+                , SizeUtils.dp2px(mContext, 598));
+        this.setLayoutParams(layoutParams);
+        View modelCView = mLayoutInflater.inflate(R.layout.cusview_model_view_e, null);
+        ImageView backgournd = modelCView.findViewById(R.id.cusview_model_view_e_background);
+        if (!TextUtils.isEmpty(bgUrl)) {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, bgUrl, backgournd);
+        } else {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, R.drawable.test_lijicansai, backgournd);
+        }
+        FrameLayout mshowRule = modelCView.findViewById(R.id.cusview_model_view_e_show_rule);
+        mshowRule.setOnClickListener(new OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                //显示规
+                CusToast.getInstance(mContext).show("显示规则弹窗还是什么玩意儿", 2000);
+            }
+        });
+
+        //cusview_model_view_e_course_layout
+        ConstraintLayout mCourseLayout = modelCView.findViewById(R.id.cusview_cusview_model_view_e_course_layout);
+        mCourseLayout.setOnClickListener(new OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                CusToast.getInstance(mContext).show("去列表播放页SmallFullVideoActivity", 2000);
+            }
+        });
+
+        RoundFrameLayout enterMatch = modelCView.findViewById(R.id.cusview_model_view_e_enter_match);
+        enterMatch.setOnClickListener(new OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                CusToast.getInstance(mContext).show("立即参赛", 2000);
+            }
+        });
+        RecyclerView mRecyclerView = modelCView.findViewById(R.id.cusview_model_view_e_recyclerview);
+        mRecyclerView.setLayoutManager(new LinearLayoutManager(mContext, LinearLayoutManager.VERTICAL, false));
+
+        //测试数据
+        List<String> list = new ArrayList<>();
+        for (int i = 0; i < 40; i++) {
+            list.add("" + i);
+        }
+        ModelViewEAdapter adapter = new ModelViewEAdapter(mContext, list);
+        mRecyclerView.setAdapter(adapter);
+        addView(modelCView);
+    }
+
+
+    public class ModelViewEAdapter extends RecyclerView.Adapter<ModelViewEViewHolder> {
+
+
+        public List<String> mListData;
+
+
+        public ModelViewEAdapter(Context context, List<String> listData) {
+            mContext = context;
+            mListData = listData;
+        }
+
+
+        @NonNull
+        @Override
+        public ModelViewEViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
+            return new ModelViewEViewHolder(mLayoutInflater.inflate(R.layout.adapter_item_cusview_model_view_c, parent, false));
+        }
+
+        @Override
+        public void onBindViewHolder(@NonNull ModelViewEViewHolder holder, @SuppressLint("RecyclerView") int position) {
+            switch (position) {
+                case 0:
+                    holder.mItemIcon.setBackgroundResource(R.drawable.ranklist_one);
+                    break;
+                case 1:
+                    holder.mItemIcon.setBackgroundResource(R.drawable.ranklist_two);
+                    break;
+                case 2:
+                    holder.mItemIcon.setBackgroundResource(R.drawable.ranklist_three);
+                    break;
+                default:
+                    holder.mItemIcon.setText(position + "");
+                    break;
+            }
+            holder.mNickName.setText(mListData.get(position));
+            holder.mScore.setText(mListData.get(position) + "分数");
+            if (mItemClickListener != null) {
+                holder.itemView.setOnClickListener(new OnClickListener() {
+                    @Override
+                    public void onClick(View v) {
+                        mItemClickListener.clickItem(holder.itemView, position);
+                    }
+                });
+            }
+        }
+
+
+        @Override
+        public int getItemCount() {
+            return mListData.size();
+        }
+
+        @Override
+        public int getItemViewType(int position) {
+            return position;
+        }
+    }
+
+
+    public interface onItemClickListener {
+        void clickItem(View view, int position);
+
+    }
+
+}
+
+class ModelViewEViewHolder extends RecyclerView.ViewHolder {
+
+
+    TextView mItemIcon;
+    TextView mNickName;
+    TextView mScore;
+
+    public ModelViewEViewHolder(@NonNull View itemView) {
+        super(itemView);
+        mItemIcon = itemView.findViewById(R.id.adapter_item_cusview_model_view_c_icon);
+        mNickName = itemView.findViewById(R.id.adapter_item_cusview_model_view_c_nickname);
+        mScore = itemView.findViewById(R.id.adapter_item_cusview_model_view_c_score);
+    }
+}
+
+
+

+ 79 - 0
app/src/main/java/com/edufound/reader/cusview/ModelViewF.java

@@ -0,0 +1,79 @@
+package com.edufound.reader.cusview;
+
+import android.content.Context;
+import android.text.TextUtils;
+import android.util.AttributeSet;
+import android.view.Gravity;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.view.ViewGroup;
+import android.widget.FrameLayout;
+import android.widget.ImageView;
+import android.widget.LinearLayout;
+
+import androidx.annotation.NonNull;
+import androidx.annotation.Nullable;
+import androidx.constraintlayout.widget.ConstraintLayout;
+
+import com.edufound.reader.R;
+import com.edufound.reader.util.GlideUtils;
+import com.edufound.reader.util.SizeUtils;
+
+public class ModelViewF extends FrameLayout {
+
+    Context mContext;
+    LayoutInflater mLayoutInflater;
+    LinearLayout mItemLayout;
+    ImageView mBackgroundImg;
+
+    public ModelViewF(@NonNull Context context) {
+        super(context);
+        mContext = context;
+        mLayoutInflater = LayoutInflater.from(mContext);
+    }
+
+    public ModelViewF(@NonNull Context context, @Nullable AttributeSet attrs) {
+        super(context, attrs);
+    }
+
+    public ModelViewF(@NonNull Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
+        super(context, attrs, defStyleAttr);
+    }
+
+    public void initView() {
+        FrameLayout.LayoutParams layoutParams = new FrameLayout.LayoutParams(SizeUtils.dp2px(mContext, 428)
+                , SizeUtils.dp2px(mContext, 598));
+        this.setLayoutParams(layoutParams);
+        layoutParams.gravity = Gravity.CENTER;
+        FrameLayout modelViewF = (FrameLayout) mLayoutInflater.inflate(R.layout.cusview_model_view_f, null);
+        mBackgroundImg = modelViewF.findViewById(R.id.cusview_model_view_f_background);
+        FrameLayout btn_rule = modelViewF.findViewById(R.id.cusview_model_view_f_rule);
+        btn_rule.setOnClickListener(new OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                CusToast.getInstance(mContext).show("显示规则", 1000);
+            }
+        });
+
+        mItemLayout = modelViewF.findViewById(R.id.cusview_model_view_f_item_layout);
+        mItemLayout.removeAllViews();
+
+        this.addView(modelViewF);
+
+
+    }
+
+    public void setView(String bgurl) {
+        if (!TextUtils.isEmpty(bgurl)) {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, bgurl, mBackgroundImg);
+        } else {
+            GlideUtils.loadImageSizeKipMemoryCache(mContext, R.drawable.test_view_f_bg, mBackgroundImg);
+        }
+        LinearLayout.LayoutParams itemParams = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, 0, 1);
+        for (int i = 0; i < 4; i++) {
+            ConstraintLayout item = (ConstraintLayout) mLayoutInflater.inflate(R.layout.adapter_item_cusview_model_view_f, null);
+            item.setLayoutParams(itemParams);
+            mItemLayout.addView(item);
+        }
+    }
+}

+ 102 - 65
app/src/main/java/com/edufound/reader/presenter/MainPresenter.java

@@ -28,6 +28,13 @@ import com.edufound.reader.bean.UserBean;
 import com.edufound.reader.bean.UserEventEnum;
 import com.edufound.reader.contract.MainContract;
 import com.edufound.reader.cusview.CusToast;
+import com.edufound.reader.cusview.ModelViewA;
+import com.edufound.reader.cusview.ModelViewB;
+import com.edufound.reader.cusview.ModelViewC;
+import com.edufound.reader.cusview.ModelViewD;
+import com.edufound.reader.cusview.ModelViewE;
+import com.edufound.reader.cusview.ModelViewF;
+import com.edufound.reader.cusview.ModelViewWidthA;
 import com.edufound.reader.fragment.CharacterFragment;
 import com.edufound.reader.fragment.EventFragment;
 import com.edufound.reader.fragment.MyTabFragment;
@@ -50,7 +57,9 @@ import org.json.JSONException;
 import org.json.JSONObject;
 
 import java.io.IOException;
+import java.util.ArrayList;
 import java.util.HashMap;
+import java.util.List;
 import java.util.Map;
 
 import androidx.fragment.app.Fragment;
@@ -101,7 +110,7 @@ public class MainPresenter extends BasePresenter<MainContract.View> implements M
                     mUserApi.postUserEvent(mView.getActivity(), UserEventEnum.EVENT_MY.getEvent());
                 } else {
                     Logger.e("");
-//                    ((RadioButton) radioGroup.getChildAt(mRadioCheckIndex)).setChecked(true);
+                    ((RadioButton) radioGroup.getChildAt(mRadioCheckIndex)).setChecked(true);
                 }
                 break;
 
@@ -220,73 +229,97 @@ public class MainPresenter extends BasePresenter<MainContract.View> implements M
                 @Override
                 public void onClick(View view) {
 //                    MMKVUtil.getInstance().clearAll();
-                    EfunboxUtil.toWebFlowerActivity(mView.getActivity(), "http://activity.ai160.com/index.html",null);
+                    EfunboxUtil.toWebFlowerActivity(mView.getActivity(), "http://activity.ai160.com/index.html", null);
                 }
             });
             testlayout.addView(tv);
 //
 //
-//                ModelViewA modelViewA = new ModelViewA(mView.getActivity());
-//                modelViewA.initView("http://reader-apk.ai160.com/reader-apk/res/character_image.png", new View.OnClickListener() {
-//                    @Override
-//                    public void onClick(View v) {
-//                        CusToast.getInstance(mView.getActivity()).show("test model view A right", 1000);
-//                    }
-//                });
-//
-//
-//                ModelViewB modelViewB = new ModelViewB(mView.getActivity());
-//                modelViewB.initView("http://reader-apk.ai160.com/reader-apk/res/character_image.png", new ModelViewB.OnClickBtnListener() {
-//                    @Override
-//                    public void clickLeft() {
-//                        CusToast.getInstance(mView.getActivity()).show("test model view B left", 1000);
-//                    }
-//
-//                    @Override
-//                    public void clickRight() {
-//                        CusToast.getInstance(mView.getActivity()).show("test model view B right", 1000);
-//                    }
-//                });
-//
-//
-//                ModelViewC modelViewC = new ModelViewC(mView.getActivity());
-//                modelViewC.initView("http://reader-apk.ai160.com/reader-apk/res/character_image.png");
-//                modelViewC.setItemClickListener(new ModelViewC.onItemClickListener() {
-//                    @Override
-//                    public void clickItem(View view, int position) {
-//                        CusToast.getInstance(mView.getActivity()).show("test model view C position:" + position, 1000);
-//                    }
-//                });
-//
-//
-//                ModelViewD modelViewD = new ModelViewD(mView.getActivity());
-//                List<String> list = new ArrayList<>();
-//                for (int i = 0; i < 4; i++) {
-//                    list.add(i + "");
-//                }
-//                modelViewD.initView("http://reader-apk.ai160.com/reader-apk/res/character_image.png", list, new ModelViewD.OnClickBtnListener() {
-//                    @Override
-//                    public void clickLeft(Object object) {
-//                        CusToast.getInstance(mView.getActivity()).show("test model view D 查看规则", 1000);
-//                    }
-//
-//                    @Override
-//                    public void clickRight(Object object) {
-//                        CusToast.getInstance(mView.getActivity()).show("test model view D 排行榜", 1000);
-//                    }
-//
-//                    @Override
-//                    public void clickItem(Object object) {
-//                        CusToast.getInstance(mView.getActivity()).show("test model view D item:" + String.valueOf(object), 1000);
-//                    }
-//
-//
-//                });
-//
-//                testlayout.addView(modelViewA);
-//                testlayout.addView(modelViewB);
-//                testlayout.addView(modelViewC);
-//                testlayout.addView(modelViewD);
+            ModelViewA modelViewA = new ModelViewA(mView.getActivity());
+            modelViewA.initView();
+            modelViewA.setView("http://reader-apk.ai160.com/reader-apk/res/character_image.png", new View.OnClickListener() {
+                @Override
+                public void onClick(View v) {
+                    CusToast.getInstance(mView.getActivity()).show("test model view A right", 1000);
+                }
+            });
+            ModelViewWidthA modelViewWidthA = new ModelViewWidthA(mView.getActivity());
+            modelViewWidthA.initView();
+            modelViewWidthA.setView("http://reader-apk.ai160.com/reader-apk/res/character_image.png", new View.OnClickListener() {
+                @Override
+                public void onClick(View v) {
+                    CusToast.getInstance(mView.getActivity()).show("test model view A right", 1000);
+                }
+            });
+
+            ModelViewB modelViewB = new ModelViewB(mView.getActivity());
+            modelViewB.initView();
+            modelViewB.setView("", "不知道什么名字", "2020.05.24-2222.22.22", "111", new ModelViewB.OnClickBtnListener() {
+                @Override
+                public void clickLeft() {
+                    CusToast.getInstance(mView.getActivity()).show("test model view B left", 1000);
+                }
+
+                @Override
+                public void clickRight() {
+                    CusToast.getInstance(mView.getActivity()).show("test model view B right", 1000);
+                }
+            });
+
+
+            ModelViewC modelViewC = new ModelViewC(mView.getActivity());
+            //传空有默认图
+            modelViewC.initView("");
+            modelViewC.setItemClickListener(new ModelViewC.onItemClickListener() {
+                @Override
+                public void clickItem(View view, int position) {
+                    CusToast.getInstance(mView.getActivity()).show("test model view C position:" + position, 1000);
+                }
+            });
+
+
+            ModelViewD modelViewD = new ModelViewD(mView.getActivity());
+            List<String> list = new ArrayList<>();
+            for (int i = 0; i < 4; i++) {
+                list.add(i + "");
+            }
+            modelViewD.initView();
+            modelViewD.setView("", list, new ModelViewD.OnClickBtnListener() {
+                @Override
+                public void clickLeft(Object object) {
+                    CusToast.getInstance(mView.getActivity()).show("test model view D 查看规则", 1000);
+                }
+
+
+                @Override
+                public void clickItem(Object object) {
+                    CusToast.getInstance(mView.getActivity()).show("test model view D item:" + String.valueOf(object), 1000);
+                }
+
+
+            });
+
+            ModelViewE modelViewE = new ModelViewE(mView.getActivity());
+            modelViewE.initView("");
+            modelViewE.setItemClickListener(new ModelViewE.onItemClickListener() {
+                @Override
+                public void clickItem(View view, int position) {
+                    CusToast.getInstance(mView.getActivity()).show("test model view E position:" + position, 1000);
+                }
+            });
+
+            ModelViewF modelViewF = new ModelViewF(mView.getActivity());
+            modelViewF.initView();
+            modelViewF.setView("");
+
+
+            testlayout.addView(modelViewA);
+            testlayout.addView(modelViewWidthA);
+            testlayout.addView(modelViewB);
+            testlayout.addView(modelViewC);
+            testlayout.addView(modelViewD);
+            testlayout.addView(modelViewE);
+            testlayout.addView(modelViewF);
             scrollView.addView(testlayout);
 //
             mView.getRootView().addView(scrollView);
@@ -505,10 +538,14 @@ public class MainPresenter extends BasePresenter<MainContract.View> implements M
     public void refRecordById(String id) {
         switch (mRadioCheckIndex) {
             case 1:
-                mRecommendFragment.getPresenter().getRecordInfoById(id);
+                if (mRecommendFragment != null) {
+                    mRecommendFragment.getPresenter().getRecordInfoById(id);
+                }
                 break;
             case 2:
-                mFollowFragment.getPresenter().getRecordInfoById(id);
+                if (mFollowFragment != null) {
+                    mFollowFragment.getPresenter().getRecordInfoById(id);
+                }
                 break;
         }
 

+ 37 - 25
app/src/main/java/com/edufound/reader/util/GlideUtils.java

@@ -115,6 +115,18 @@ public class GlideUtils {
 
     }
 
+
+    public static void loadImageSizeKipMemoryCache(Context context, int id, ImageView imageView) {
+        RequestOptions options = new RequestOptions()
+                .placeholder(placeholderImage) //占位图
+                .error(errorImage)             //错误图
+                .format(PREFER_RGB_565)
+                .skipMemoryCache(true).diskCacheStrategy(DiskCacheStrategy.NONE);          //禁用掉Glide的内存缓存功能
+        Glide.with(context).load(id).apply(options).into(imageView);
+
+    }
+
+
     /**
      * 预先加载图片
      * 在使用图片之前,预先把图片加载到缓存,调用了预加载之后,我们以后想再去加载这张图片就会非常快了,
@@ -176,10 +188,10 @@ public class GlideUtils {
     public static void loadCircleWithBorderImage(Context context, String url, ImageView imageView,
                                                  float borderSize, @ColorInt int borderColor) {
         RequestOptions options = RequestOptions.bitmapTransform(
-                new MultiTransformation<>(
-                        new CenterCrop(),
-                        new CropCircleWithBorderTransformation(SizeUtils.px2dp(context, borderSize), borderColor)
-                ))
+                        new MultiTransformation<>(
+                                new CenterCrop(),
+                                new CropCircleWithBorderTransformation(SizeUtils.px2dp(context, borderSize), borderColor)
+                        ))
                 .placeholder(placeholderImage) //占位图
                 .format(PREFER_RGB_565)
                 .error(errorImage);            //错误图
@@ -197,11 +209,11 @@ public class GlideUtils {
     public static void loadRoundCircleImage(Context context, String url, ImageView imageView,
                                             float radius) {
         RequestOptions options = RequestOptions.bitmapTransform(
-                new MultiTransformation<>(
-                        new CenterCrop(),
-                        new RoundedCornersTransformation(SizeUtils.px2dp(context, radius), 0,
-                                RoundedCornersTransformation.CornerType.ALL)
-                ))
+                        new MultiTransformation<>(
+                                new CenterCrop(),
+                                new RoundedCornersTransformation(SizeUtils.px2dp(context, radius), 0,
+                                        RoundedCornersTransformation.CornerType.ALL)
+                        ))
                 .placeholder(placeholderImage) //占位图
                 .format(PREFER_RGB_565)
                 .error(errorImage);            //错误图
@@ -222,10 +234,10 @@ public class GlideUtils {
     public static void loadRoundCircleImage(Context context, String url, ImageView imageView,
                                             float radius, RoundedCornersTransformation.CornerType type) {
         RequestOptions options = RequestOptions.bitmapTransform(
-                new MultiTransformation<>(
-                        new CenterCrop(),
-                        new RoundedCornersTransformation(SizeUtils.px2dp(context, radius), 0, type)
-                ))
+                        new MultiTransformation<>(
+                                new CenterCrop(),
+                                new RoundedCornersTransformation(SizeUtils.px2dp(context, radius), 0, type)
+                        ))
                 .placeholder(placeholderImage) //占位图
                 .format(PREFER_RGB_565)
                 .error(errorImage);            //错误图
@@ -242,10 +254,10 @@ public class GlideUtils {
      */
     public static void loadBlurImage(Context context, String url, ImageView imageView, int blur) {
         RequestOptions options = RequestOptions.bitmapTransform(
-                new MultiTransformation<>(
-                        new CenterCrop(),
-                        new BlurTransformation(blur)
-                ))
+                        new MultiTransformation<>(
+                                new CenterCrop(),
+                                new BlurTransformation(blur)
+                        ))
                 .placeholder(placeholderImage) //占位图
                 .format(PREFER_RGB_565)
                 .error(errorImage);            //错误图
@@ -263,10 +275,10 @@ public class GlideUtils {
      */
     public static void loadBlurImage(Context context, String url, ImageView imageView, int blur, int sampling) {
         RequestOptions options = RequestOptions.bitmapTransform(
-                new MultiTransformation<>(
-                        new CenterCrop(),
-                        new BlurTransformation(blur, sampling)
-                ))
+                        new MultiTransformation<>(
+                                new CenterCrop(),
+                                new BlurTransformation(blur, sampling)
+                        ))
                 .placeholder(placeholderImage) //占位图
                 .format(PREFER_RGB_565)
                 .error(errorImage);            //错误图
@@ -282,10 +294,10 @@ public class GlideUtils {
      */
     public static void loadBlackImage(Context context, String url, ImageView imageView) {
         RequestOptions options = RequestOptions.bitmapTransform(
-                new MultiTransformation<>(
-                        new CenterCrop(),
-                        new GrayscaleTransformation()
-                ))
+                        new MultiTransformation<>(
+                                new CenterCrop(),
+                                new GrayscaleTransformation()
+                        ))
                 .placeholder(placeholderImage) //占位图
                 .format(PREFER_RGB_565)
                 .error(errorImage);            //错误图

BIN
app/src/main/res/drawable/cusview_model_view_b_enter_btn_bg.png


BIN
app/src/main/res/drawable/cusview_model_view_b_info_btn_bg.png


BIN
app/src/main/res/drawable/cusview_model_view_f_item_bg.png


+ 8 - 0
app/src/main/res/drawable/cusview_model_view_f_layout_divier.xml

@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+        android:shape="rectangle">
+    <size
+            android:width="0dp"
+            android:height="24dp" />
+    <solid android:color="@android:color/transparent" />
+</shape>

BIN
app/src/main/res/drawable/model_view_c_recyclerview_bottom_frame.png


BIN
app/src/main/res/drawable/model_view_d_item_btn_bt.png


BIN
app/src/main/res/drawable/model_view_d_rult_btn_bt.png


BIN
app/src/main/res/drawable/ranklist_one.png


BIN
app/src/main/res/drawable/ranklist_three.png


BIN
app/src/main/res/drawable/ranklist_two.png


+ 15 - 12
app/src/main/res/layout/adapter_item_cusview_model_view_c.xml

@@ -2,24 +2,27 @@
 <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:app="http://schemas.android.com/apk/res-auto"
     android:layout_width="381dp"
-    android:layout_height="38dp"
-    android:layout_gravity="center"
-    android:background="@color/blueviolet">
+    android:layout_height="50dp"
+    android:layout_gravity="center">
 
-    <ImageView
-        android:layout_width="37dp"
-        android:layout_height="37dp"
-        android:background="@color/red"
+
+    <TextView
+        android:id="@+id/adapter_item_cusview_model_view_c_icon"
+        android:layout_width="25dp"
+        android:layout_height="25dp"
+        android:gravity="center"
+        android:textColor="#1B1B1B"
+        android:textSize="20dp"
         app:layout_constraintBottom_toBottomOf="parent"
         app:layout_constraintEnd_toEndOf="parent"
         app:layout_constraintHorizontal_bias="0.0"
         app:layout_constraintStart_toStartOf="parent"
-        app:layout_constraintTop_toTopOf="parent"></ImageView>
+        app:layout_constraintTop_toTopOf="parent"></TextView>
 
     <TextView
         android:id="@+id/adapter_item_cusview_model_view_c_nickname"
         android:layout_width="200dp"
-        android:layout_height="37dp"
+        android:layout_height="25dp"
         android:gravity="center|left"
         android:text="昵称"
         android:textColor="#333333"
@@ -34,14 +37,14 @@
     <TextView
         android:id="@+id/adapter_item_cusview_model_view_c_score"
         android:layout_width="wrap_content"
-        android:layout_height="37dp"
+        android:layout_height="25dp"
         android:gravity="center|left"
-        android:text="99"
+        android:text="得分"
         android:textColor="#383838"
         android:textSize="20dp"
         app:layout_constraintBottom_toBottomOf="parent"
         app:layout_constraintEnd_toEndOf="parent"
-        app:layout_constraintHorizontal_bias="1.0"
+        app:layout_constraintHorizontal_bias="0.92"
         app:layout_constraintStart_toStartOf="parent"
         app:layout_constraintTop_toTopOf="parent"></TextView>
 </androidx.constraintlayout.widget.ConstraintLayout>

+ 119 - 0
app/src/main/res/layout/cusview_model_view_b.xml

@@ -0,0 +1,119 @@
+<?xml version="1.0" encoding="utf-8"?>
+<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    xmlns:tools="http://schemas.android.com/tools"
+    android:layout_width="644dp"
+    android:layout_height="598dp"
+    android:layout_gravity="center">
+
+    <ImageView
+        android:id="@+id/cusview_model_view_b_background"
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:scaleType="fitXY"
+        app:layout_constraintBottom_toBottomOf="parent"
+        app:layout_constraintEnd_toEndOf="parent"
+        app:layout_constraintStart_toStartOf="parent"
+        app:layout_constraintTop_toTopOf="parent"></ImageView>
+
+    <TextView
+        android:id="@+id/cusview_model_view_b_name"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginStart="30dp"
+        android:layout_marginTop="350dp"
+        android:text="儿童节 小红花当钱花"
+        android:textColor="#314051"
+        android:textSize="37dp"
+        android:textStyle="bold"
+        app:layout_constraintBottom_toBottomOf="parent"
+        app:layout_constraintEnd_toEndOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintHorizontal_bias="0.0"
+        app:layout_constraintStart_toStartOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintVertical_bias="0.0"></TextView>
+
+    <TextView
+        android:id="@+id/cusview_model_view_b_time"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginStart="30dp"
+        android:text="2022.6.1-6.7"
+        android:textColor="#999999"
+        android:textSize="34dp"
+        app:layout_constraintBottom_toBottomOf="parent"
+        app:layout_constraintEnd_toEndOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintHorizontal_bias="0.0"
+        app:layout_constraintStart_toStartOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintTop_toBottomOf="@+id/cusview_model_view_b_name"
+        app:layout_constraintVertical_bias="0.060000002"></TextView>
+
+
+    <TextView
+        android:id="@+id/cusview_model_view_b_enter_num"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginEnd="100dp"
+        android:text="24857"
+        android:textColor="#77CE6A"
+        android:textSize="34dp"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_b_time"
+        app:layout_constraintEnd_toEndOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_b_time"></TextView>
+
+    <TextView
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginEnd="30dp"
+        android:text="参与"
+        android:textColor="#999999"
+        android:textSize="34dp"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_b_enter_num"
+        app:layout_constraintEnd_toEndOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintHorizontal_bias="1.0"
+        app:layout_constraintStart_toEndOf="@+id/cusview_model_view_b_enter_num"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_b_enter_num"
+        app:layout_constraintVertical_bias="0.0"></TextView>
+
+    <FrameLayout
+        android:id="@+id/cusview_model_view_b_info_btn"
+        android:layout_width="244dp"
+        android:layout_height="66dp"
+        android:layout_marginStart="32dp"
+        android:background="@drawable/cusview_model_view_b_info_btn_bg"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintStart_toStartOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintTop_toBottomOf="@+id/cusview_model_view_b_time"
+        app:layout_constraintVertical_bias="0.38">
+
+        <TextView
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:gravity="center"
+            android:text="查看详情"
+            android:textColor="#7D3200"
+            android:textSize="32dp"></TextView>
+    </FrameLayout>
+
+    <FrameLayout
+        android:id="@+id/cusview_model_view_b_enter_btn"
+        android:layout_width="244dp"
+        android:layout_height="66dp"
+        android:layout_marginEnd="32dp"
+        android:background="@drawable/cusview_model_view_b_enter_btn_bg"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_b_info_btn"
+        app:layout_constraintEnd_toEndOf="@+id/cusview_model_view_b_background"
+        app:layout_constraintHorizontal_bias="1.0"
+        app:layout_constraintStart_toEndOf="@+id/cusview_model_view_b_info_btn"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_b_info_btn">
+
+        <TextView
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:gravity="center"
+            android:text="立即参加"
+            android:textColor="#FFFFFF"
+            android:textSize="32dp"></TextView>
+
+    </FrameLayout>
+</androidx.constraintlayout.widget.ConstraintLayout>

+ 22 - 15
app/src/main/res/layout/cusview_model_view_c.xml

@@ -6,20 +6,28 @@
     android:layout_gravity="center">
 
     <ImageView
-        android:id="@+id/model_view_c_background"
+        android:id="@+id/cusview_model_view_e_background"
         android:layout_width="match_parent"
         android:layout_height="match_parent"
-        android:background="@color/grassgreen"
         android:scaleType="fitXY"></ImageView>
 
+    <FrameLayout
+        android:id="@+id/cusview_model_view_c_show_rule"
+        android:layout_width="match_parent"
+        android:layout_height="123dp"
+        app:layout_constraintBottom_toTopOf="@+id/cusview_model_view_c_course_layout"
+        app:layout_constraintEnd_toEndOf="parent"
+        app:layout_constraintStart_toStartOf="parent"
+        app:layout_constraintTop_toTopOf="parent"></FrameLayout>
+
     <androidx.constraintlayout.widget.ConstraintLayout
+        android:id="@+id/cusview_model_view_c_course_layout"
         android:layout_width="381dp"
         android:layout_height="104dp"
-        android:layout_marginTop="128dp"
-        android:background="@color/coral"
-        app:layout_constraintBottom_toBottomOf="@+id/model_view_c_background"
-        app:layout_constraintEnd_toEndOf="@+id/model_view_c_background"
-        app:layout_constraintStart_toStartOf="@+id/model_view_c_background"
+        android:layout_marginTop="135dp"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_e_background"
+        app:layout_constraintEnd_toEndOf="@+id/cusview_model_view_e_background"
+        app:layout_constraintStart_toStartOf="@+id/cusview_model_view_e_background"
         app:layout_constraintTop_toTopOf="parent"
         app:layout_constraintVertical_bias="0.0">
 
@@ -50,6 +58,7 @@
 
 
         <LinearLayout
+            android:id="@+id/linearLayout3"
             android:layout_width="265dp"
             android:layout_height="30dp"
             android:gravity="left|center"
@@ -74,7 +83,6 @@
                     android:layout_width="0dp"
                     android:layout_height="wrap_content"
                     android:layout_gravity="center"
-                    android:layout_marginTop="3dp"
                     android:layout_weight="1"
                     android:scaleType="center"
                     android:src="@drawable/adapter_item_record_authority_allcount"></ImageView>
@@ -101,7 +109,6 @@
                     android:layout_width="0dp"
                     android:layout_height="wrap_content"
                     android:layout_gravity="center"
-                    android:layout_marginTop="3dp"
                     android:layout_weight="1"
                     android:scaleType="center"
                     android:src="@drawable/adapter_item_record_thumb"></ImageView>
@@ -128,7 +135,6 @@
                     android:layout_width="0dp"
                     android:layout_height="wrap_content"
                     android:layout_gravity="center"
-                    android:layout_marginTop="3dp"
                     android:layout_weight="1"
                     android:scaleType="center"
                     android:src="@drawable/adapter_item_record_stars"></ImageView>
@@ -151,21 +157,22 @@
 
     <FrameLayout
         android:layout_width="match_parent"
-        android:layout_height="308dp"
+        android:layout_height="335dp"
         android:layout_marginLeft="30dp"
         android:layout_marginRight="30dp"
-        android:background="@color/tomato"
-        app:layout_constraintBottom_toBottomOf="@+id/model_view_c_background"
+        android:layout_marginBottom="10dp"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_e_background"
         app:layout_constraintEnd_toEndOf="parent"
         app:layout_constraintStart_toStartOf="parent"
-        app:layout_constraintTop_toTopOf="@+id/model_view_c_background"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_e_background"
         app:layout_constraintVertical_bias="1.0">
 
 
         <androidx.recyclerview.widget.RecyclerView
             android:id="@+id/model_view_c_recyclerview"
             android:layout_width="match_parent"
-            android:layout_height="match_parent"></androidx.recyclerview.widget.RecyclerView>
+            android:layout_height="match_parent"
+            android:paddingBottom="5dp"></androidx.recyclerview.widget.RecyclerView>
 
     </FrameLayout>
 </androidx.constraintlayout.widget.ConstraintLayout>

+ 200 - 0
app/src/main/res/layout/cusview_model_view_e.xml

@@ -0,0 +1,200 @@
+<?xml version="1.0" encoding="utf-8"?>
+<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    android:layout_width="428dp"
+    android:layout_height="598dp"
+    android:layout_gravity="center">
+
+    <ImageView
+        android:id="@+id/cusview_model_view_e_background"
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:scaleType="fitXY"></ImageView>
+
+    <FrameLayout
+        android:id="@+id/cusview_model_view_e_show_rule"
+        android:layout_width="match_parent"
+        android:layout_height="123dp"
+        app:layout_constraintBottom_toTopOf="@+id/cusview_cusview_model_view_e_course_layout"
+        app:layout_constraintEnd_toEndOf="parent"
+        app:layout_constraintStart_toStartOf="parent"
+        app:layout_constraintTop_toTopOf="parent"></FrameLayout>
+
+    <androidx.constraintlayout.widget.ConstraintLayout
+        android:id="@+id/cusview_cusview_model_view_e_course_layout"
+        android:layout_width="381dp"
+        android:layout_height="104dp"
+        android:layout_marginTop="135dp"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_e_background"
+        app:layout_constraintEnd_toEndOf="@+id/cusview_model_view_e_background"
+        app:layout_constraintStart_toStartOf="@+id/cusview_model_view_e_background"
+        app:layout_constraintTop_toTopOf="parent"
+        app:layout_constraintVertical_bias="0.0">
+
+        <ImageView
+            android:id="@+id/cusview_model_view_e_icon"
+            android:layout_width="94dp"
+            android:layout_height="76dp"
+            android:layout_marginStart="13dp"
+            android:background="@color/red"
+            app:layout_constraintBottom_toBottomOf="parent"
+            app:layout_constraintEnd_toEndOf="parent"
+            app:layout_constraintHorizontal_bias="0.0"
+            app:layout_constraintStart_toStartOf="parent"
+            app:layout_constraintTop_toTopOf="parent"></ImageView>
+
+        <TextView
+            android:id="@+id/cusview_model_view_e_name"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:text="春夏秋冬"
+            android:textSize="26dp"
+            app:layout_constraintBottom_toBottomOf="parent"
+            app:layout_constraintEnd_toEndOf="parent"
+            app:layout_constraintHorizontal_bias="0.05"
+            app:layout_constraintStart_toEndOf="@+id/cusview_model_view_e_icon"
+            app:layout_constraintTop_toTopOf="parent"
+            app:layout_constraintVertical_bias="0.19"></TextView>
+
+        <com.edufound.reader.cusview.RoundFrameLayout
+            android:id="@+id/cusview_model_view_e_enter_match"
+            android:layout_width="111dp"
+            android:layout_height="31dp"
+            android:background="#32C965"
+            app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_e_name"
+            app:layout_constraintEnd_toEndOf="parent"
+            app:layout_constraintHorizontal_bias="0.62"
+            app:layout_constraintStart_toEndOf="@+id/cusview_model_view_e_name"
+            app:layout_constraintTop_toTopOf="@+id/cusview_model_view_e_name"
+            app:radio="30">
+
+            <TextView
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"
+                android:gravity="center"
+                android:text="立即参赛"
+                android:textColor="#FFFFFF"
+                android:textSize="17dp"></TextView>
+        </com.edufound.reader.cusview.RoundFrameLayout>
+
+
+        <LinearLayout
+
+            android:id="@+id/linearLayout3"
+            android:layout_width="265dp"
+            android:layout_height="30dp"
+            android:gravity="left|center"
+            android:orientation="horizontal"
+            app:layout_constraintBottom_toBottomOf="parent"
+            app:layout_constraintEnd_toEndOf="parent"
+            app:layout_constraintHorizontal_bias="1.0"
+            app:layout_constraintStart_toEndOf="@+id/cusview_model_view_e_icon"
+            app:layout_constraintTop_toBottomOf="@+id/cusview_model_view_e_name"
+            app:layout_constraintVertical_bias="0.32999998">
+
+            <LinearLayout
+                android:layout_width="0dp"
+                android:layout_height="match_parent"
+                android:layout_gravity="center"
+                android:layout_weight="1"
+                android:gravity="center"
+                android:orientation="horizontal">
+
+
+                <ImageView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_gravity="center"
+                    android:layout_weight="1"
+                    android:scaleType="center"
+                    android:src="@drawable/adapter_item_record_authority_allcount"></ImageView>
+
+                <TextView
+                    android:id="@+id/cusview_model_view_e_allcount_num"
+                    android:layout_width="0dp"
+                    android:layout_height="match_parent"
+                    android:layout_gravity="center|left"
+                    android:layout_weight="2"
+                    android:gravity="center|left"
+                    android:text="1234"
+                    android:textColor="#96A3B4"
+                    android:textSize="20dp"></TextView>
+            </LinearLayout>
+
+            <LinearLayout
+                android:layout_width="0dp"
+                android:layout_height="match_parent"
+                android:layout_weight="1"
+                android:orientation="horizontal">
+
+                <ImageView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_gravity="center"
+                    android:layout_weight="1"
+                    android:scaleType="center"
+                    android:src="@drawable/adapter_item_record_thumb"></ImageView>
+
+                <TextView
+                    android:id="@+id/cusview_model_view_e_thumb_num"
+                    android:layout_width="0dp"
+                    android:layout_height="match_parent"
+                    android:layout_gravity="center|left"
+                    android:layout_weight="2"
+                    android:gravity="center|left"
+                    android:text="1234"
+                    android:textColor="#96A3B4"
+                    android:textSize="20dp"></TextView>
+            </LinearLayout>
+
+            <LinearLayout
+                android:layout_width="0dp"
+                android:layout_height="match_parent"
+                android:layout_weight="1"
+                android:orientation="horizontal">
+
+                <ImageView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_gravity="center"
+                    android:layout_weight="1"
+                    android:scaleType="center"
+                    android:src="@drawable/adapter_item_record_stars"></ImageView>
+
+                <TextView
+                    android:id="@+id/cusview_model_view_e_start_num"
+                    android:layout_width="0dp"
+                    android:layout_height="match_parent"
+                    android:layout_gravity="center|left"
+                    android:layout_weight="2"
+                    android:gravity="center|left"
+                    android:text="1234"
+                    android:textColor="#96A3B4"
+                    android:textSize="20dp"></TextView>
+            </LinearLayout>
+
+        </LinearLayout>
+    </androidx.constraintlayout.widget.ConstraintLayout>
+
+
+    <FrameLayout
+        android:layout_width="match_parent"
+        android:layout_height="335dp"
+        android:layout_marginLeft="30dp"
+        android:layout_marginRight="30dp"
+        android:layout_marginBottom="10dp"
+        app:layout_constraintBottom_toBottomOf="@+id/cusview_model_view_e_background"
+        app:layout_constraintEnd_toEndOf="parent"
+        app:layout_constraintStart_toStartOf="parent"
+        app:layout_constraintTop_toTopOf="@+id/cusview_model_view_e_background"
+        app:layout_constraintVertical_bias="1.0">
+
+
+        <androidx.recyclerview.widget.RecyclerView
+            android:id="@+id/cusview_model_view_e_recyclerview"
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:paddingBottom="5dp"></androidx.recyclerview.widget.RecyclerView>
+
+    </FrameLayout>
+</androidx.constraintlayout.widget.ConstraintLayout>

+ 38 - 0
app/src/main/res/layout/cusview_model_view_f.xml

@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="utf-8"?>
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    android:layout_width="428dp"
+    android:layout_height="598dp"
+    android:layout_gravity="center">
+
+    <ImageView
+        android:id="@+id/cusview_model_view_f_background"
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"></ImageView>
+
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:orientation="vertical">
+
+        <FrameLayout
+            android:id="@+id/cusview_model_view_f_rule"
+            android:layout_width="match_parent"
+            android:layout_height="0dp"
+            android:layout_weight="1"></FrameLayout>
+
+        <LinearLayout
+            android:id="@+id/cusview_model_view_f_item_layout"
+            android:layout_width="match_parent"
+            android:layout_height="0dp"
+            android:layout_gravity="center"
+            android:layout_weight="4"
+            android:gravity="center|top"
+            android:orientation="vertical"
+            android:paddingTop="15dp"
+            android:paddingBottom="15dp">
+
+
+        </LinearLayout>
+    </LinearLayout>
+</FrameLayout>

BIN
app/src/testimg/drawable/test_double_btn_bg.png


BIN
app/src/testimg/drawable/test_four_img.png


BIN
app/src/testimg/drawable/test_lijicansai.png


BIN
app/src/testimg/drawable/test_view_f_bg.png


BIN
app/src/testimg/drawable/test_youxiuzuopin.png