Sfoglia il codice sorgente

下线话题处理

huyuguo 5 anni fa
parent
commit
67341aa295
26 ha cambiato i file con 166 aggiunte e 45 eliminazioni
  1. 1 1
      app/build.gradle
  2. 1 0
      app/gradle.properties
  3. 28 6
      app/src/main/java/com/electric/chargingpile/activity/TopicDetailActivity.java
  4. 9 7
      app/src/main/java/com/electric/chargingpile/activity/UserPageActivity.java
  5. 11 12
      app/src/main/java/com/electric/chargingpile/adapter/TopicDetailAdapter.java
  6. 3 13
      app/src/main/java/com/electric/chargingpile/adapter/UserPageAdapter.java
  7. 4 4
      app/src/main/java/com/electric/chargingpile/application/MainApplication.java
  8. BIN
      app/src/main/res/drawable-hdpi/loading_icon.png
  9. BIN
      app/src/main/res/drawable-hdpi/topic_offline_icon.png
  10. BIN
      app/src/main/res/drawable-mdpi/loading_icon.png
  11. BIN
      app/src/main/res/drawable-mdpi/no_net_icon.png
  12. BIN
      app/src/main/res/drawable-mdpi/topic_offline_icon.png
  13. BIN
      app/src/main/res/drawable-xhdpi/loading_icon.png
  14. BIN
      app/src/main/res/drawable-xhdpi/no_net_icon.png
  15. BIN
      app/src/main/res/drawable-xhdpi/topic_offline_icon.png
  16. BIN
      app/src/main/res/drawable-xxhdpi/loading_icon.png
  17. BIN
      app/src/main/res/drawable-xxhdpi/no_net_icon.png
  18. BIN
      app/src/main/res/drawable-xxhdpi/topic_offline_icon.png
  19. BIN
      app/src/main/res/drawable-xxxhdpi/loading_icon.png
  20. BIN
      app/src/main/res/drawable-xxxhdpi/no_net_icon.png
  21. BIN
      app/src/main/res/drawable-xxxhdpi/topic_offline_icon.png
  22. 3 2
      app/src/main/res/layout/activity_chat_footer.xml
  23. 51 0
      app/src/main/res/layout/activity_no_net_img.xml
  24. 19 0
      app/src/main/res/layout/activity_topic_detail.xml
  25. 35 0
      app/src/main/res/layout/activity_topic_offline.xml
  26. 1 0
      app/src/main/res/values/color.xml

+ 1 - 1
app/build.gradle

@ -122,7 +122,7 @@ android {
122 122
    }
123 123
124 124
    dexOptions {
125
        javaMaxHeapSize "4g"
125
        javaMaxHeapSize "5g"
126 126
    }
127 127
//    repositories {
128 128
//        mavenCentral()

+ 1 - 0
app/gradle.properties

@ -17,3 +17,4 @@
17 17
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
18 18
# org.gradle.parallel=true
19 19
#android.enableAapt2=false
20

+ 28 - 6
app/src/main/java/com/electric/chargingpile/activity/TopicDetailActivity.java

@ -3,6 +3,7 @@ package com.electric.chargingpile.activity;
3 3
import android.content.Intent;
4 4
import android.os.Bundle;
5 5
import android.support.annotation.Nullable;
6
import android.support.constraint.ConstraintLayout;
6 7
import android.support.v7.app.AppCompatActivity;
7 8
import android.support.v7.widget.RecyclerView;
8 9
import android.support.v7.widget.StaggeredGridLayoutManager;
@ -21,6 +22,7 @@ import com.electric.chargingpile.data.ChatRecommendBean;
21 22
import com.electric.chargingpile.data.TopicHomePageBean;
22 23
import com.electric.chargingpile.iview.RecyclerItemTypeClickListener;
23 24
import com.electric.chargingpile.manager.ProfileManager;
25
import com.electric.chargingpile.util.BarColorUtil;
24 26
import com.electric.chargingpile.util.CommonParams;
25 27
import com.electric.chargingpile.util.JsonUtils;
26 28
import com.electric.chargingpile.util.LoadingDialog;
@ -53,6 +55,8 @@ public class TopicDetailActivity extends AppCompatActivity implements View.OnCli
53 55
    public boolean isFirst = false;
54 56
    private ImageView chatPublishTips;
55 57
    private ImageView chatPublishIcon;
58
    private ConstraintLayout noNetView;
59
    private ConstraintLayout topicOfflineView;
56 60
57 61
    @Override
58 62
    protected void onCreate(@Nullable Bundle savedInstanceState) {
@ -62,19 +66,23 @@ public class TopicDetailActivity extends AppCompatActivity implements View.OnCli
62 66
        initListener();
63 67
64 68
        if (NetUtil.CheckNetwork(this)) {
65
            xRefreshView.startRefresh();
69
            loadingDialog.show();
66 70
            requestData("1");
67 71
        } else {
68
            // TODO by hyg
72
            noNetView.setVisibility(View.VISIBLE);
69 73
        }
70 74
    }
71 75
72 76
    private void initView() {
77
        BarColorUtil.initStatusBarColor(TopicDetailActivity.this);
73 78
        topicId = getIntent().getLongExtra("topicId", 0);
74 79
        loadingDialog = new LoadingDialog(TopicDetailActivity.this);
75 80
        loadingDialog.setCanceledOnTouchOutside(false);
76 81
77 82
        titleTextView = findViewById(R.id.titleTextView);
83
        noNetView = findViewById(R.id.noNetView);
84
        topicOfflineView = findViewById(R.id.topicOfflineView);
85
78 86
        xRefreshView = findViewById(R.id.xRefreshView);
79 87
        xRefreshView.setPullLoadEnable(true); // 允许加载更多
80 88
        xRefreshView.setPinnedTime(0);
@ -161,6 +169,7 @@ public class TopicDetailActivity extends AppCompatActivity implements View.OnCli
161 169
    private void initListener() {
162 170
        findViewById(R.id.backImageView).setOnClickListener(this);
163 171
        findViewById(R.id.shareTextView).setOnClickListener(this);
172
        findViewById(R.id.noNetTry).setOnClickListener(this);
164 173
    }
165 174
166 175
    @Override
@ -180,6 +189,15 @@ public class TopicDetailActivity extends AppCompatActivity implements View.OnCli
180 189
                    ToastUtil.showToast(getApplicationContext().getApplicationContext(), "请先登录", Toast.LENGTH_SHORT);
181 190
                }
182 191
                break;
192
            case R.id.noNetTry:
193
                if (NetUtil.CheckNetwork(TopicDetailActivity.this)) {
194
                    noNetView.setVisibility(View.GONE);
195
                    xRefreshView.startRefresh();
196
                    requestData("1");
197
                } else {
198
                    noNetView.setVisibility(View.VISIBLE);
199
                }
200
                break;
183 201
        }
184 202
185 203
    }
@ -229,7 +247,7 @@ public class TopicDetailActivity extends AppCompatActivity implements View.OnCli
229 247
        Map<String, String> map = new HashMap<>();
230 248
        map.put("topicId", topicId + "");
231 249
        map.put("sort", sort + "");              //   1:最新发布 2:最后回复 3:最热
232
        map.put("init", init);                   //   0:只返回话题下内容列表 1:返回话题名等信息
250
        map.put("init", init);                      //   0:只返回话题下内容列表 1:返回话题名等信息
233 251
        map.put("page", page + "");
234 252
        map.put("limit", "20");
235 253
        CommonParams.addCommonParams(map);
@ -237,7 +255,7 @@ public class TopicDetailActivity extends AppCompatActivity implements View.OnCli
237 255
        OkHttpUtils.get().url(url).params(map).build().connTimeOut(6000).readTimeOut(6000).execute(new StringCallback() {
238 256
            @Override
239 257
            public void onError(Call call, Exception e) {
240
258
                loadingDialog.dismiss();
241 259
                ToastUtil.showToast(getApplicationContext(), "数据获取失败:" + e.getMessage(), Toast.LENGTH_SHORT);
242 260
                if (page == 1) {
243 261
                    xRefreshView.stopRefresh();
@ -249,19 +267,23 @@ public class TopicDetailActivity extends AppCompatActivity implements View.OnCli
249 267
250 268
            @Override
251 269
            public void onResponse(String res) {
252
                // TODO by hyg no network
270
                loadingDialog.dismiss();
253 271
                String code = JsonUtils.getKeyResult(res, "code");
254 272
                String desc = JsonUtils.getKeyResult(res, "desc");
255 273
                if ("1000".equals(code)) {
256 274
                    String data = JsonUtils.getKeyResult(res, "data");
275
                    if ("{}".equals(data)) {
276
                        topicOfflineView.setVisibility(View.VISIBLE);
277
                        return;
278
                    }
257 279
                    TopicHomePageBean homePageBean = (TopicHomePageBean) JsonUtils.parseToObjectBean(data, TopicHomePageBean.class);
258 280
                    if (page == 1) {
259 281
                        xRefreshView.stopRefresh();
260 282
                        xRefreshView.setLoadComplete(false);
261 283
                        topicDetailAdapter.setHeaderData(homePageBean.topicVo);
262 284
                        topicDetailAdapter.setContentData(homePageBean.list);
263
264 285
                        if (homePageBean.list.size() == 0) {
286
                            xRefreshView.setLoadComplete(true);
265 287
                            topicDetailAdapter.setFooterData(true);
266 288
                        } else {
267 289
                            topicDetailAdapter.setFooterData(false);

+ 9 - 7
app/src/main/java/com/electric/chargingpile/activity/UserPageActivity.java

@ -22,6 +22,7 @@ import com.electric.chargingpile.adapter.UserPageAdapter;
22 22
import com.electric.chargingpile.application.MainApplication;
23 23
import com.electric.chargingpile.data.UserHomePageBean;
24 24
import com.electric.chargingpile.data.UserPageBeanLab;
25
import com.electric.chargingpile.util.BarColorUtil;
25 26
import com.electric.chargingpile.util.CommonParams;
26 27
import com.electric.chargingpile.util.JsonUtils;
27 28
import com.electric.chargingpile.util.LoadingDialog;
@ -72,7 +73,7 @@ public class UserPageActivity extends AppCompatActivity implements View.OnClickL
72 73
73 74
    private void initView() {
74 75
        UserPageBeanLab.get(UserPageActivity.this).clear();
75
76
        BarColorUtil.setStatusBarColor(UserPageActivity.this, getResources().getColor(R.color.color_1bb637), 1);
76 77
        loadingDialog = new LoadingDialog(UserPageActivity.this);
77 78
        loadingDialog.setCanceledOnTouchOutside(false);
78 79
@ -227,12 +228,6 @@ public class UserPageActivity extends AppCompatActivity implements View.OnClickL
227 228
            @Override
228 229
            public void onResponse(String s) {
229 230
                loadingDialog.dismiss();
230
                if (page == 1) {
231
                    xRefreshView.stopRefresh();
232
                } else {
233
                    xRefreshView.stopLoadMore();
234
                }
235
236 231
                String code = JsonUtils.getKeyResult(s, "code");
237 232
                if ("1000".equals(code)) {
238 233
                    String data = JsonUtils.getKeyResult(s, "data");
@ -249,6 +244,7 @@ public class UserPageActivity extends AppCompatActivity implements View.OnClickL
249 244
                            userPageAdapter.setContentData(userHomePageBean.list);
250 245
                        }
251 246
                        userPageAdapter.setFooterData(false);
247
                        xRefreshView.stopRefresh();
252 248
                    } else {
253 249
                        if (userHomePageBean.list.size() == 0) {
254 250
                            xRefreshView.setLoadComplete(true);
@ -257,10 +253,16 @@ public class UserPageActivity extends AppCompatActivity implements View.OnClickL
257 253
                            userPageAdapter.addContentData(userHomePageBean.list);
258 254
                            userPageAdapter.setFooterData(false);
259 255
                        }
256
                        xRefreshView.stopLoadMore();
260 257
                    }
261 258
                } else {
262 259
                    String desc = JsonUtils.getKeyResult(s, "desc");
263 260
                    ToastUtil.showToast(UserPageActivity.this, desc, Toast.LENGTH_SHORT);
261
                    if (page == 1) {
262
                        xRefreshView.stopRefresh();
263
                    } else {
264
                        xRefreshView.stopLoadMore();
265
                    }
264 266
                }
265 267
266 268
            }

+ 11 - 12
app/src/main/java/com/electric/chargingpile/adapter/TopicDetailAdapter.java

@ -2,6 +2,7 @@ package com.electric.chargingpile.adapter;
2 2
3 3
import android.app.Activity;
4 4
import android.content.Context;
5
import android.content.Intent;
5 6
import android.graphics.Rect;
6 7
import android.support.constraint.ConstraintLayout;
7 8
import android.support.v7.widget.RecyclerView;
@ -16,6 +17,7 @@ import android.widget.Toast;
16 17
17 18
import com.aspsine.irecyclerview.IViewHolder;
18 19
import com.electric.chargingpile.R;
20
import com.electric.chargingpile.activity.UserPageActivity;
19 21
import com.electric.chargingpile.application.MainApplication;
20 22
import com.electric.chargingpile.data.ChatRecommendBean;
21 23
import com.electric.chargingpile.data.TopicHomePageBean;
@ -290,26 +292,22 @@ public class TopicDetailAdapter extends RecyclerView.Adapter<IViewHolder> {
290 292
        footerViewHolder.footerContainer.setVisibility(showFooter ? View.VISIBLE : View.GONE);
291 293
292 294
        ConstraintLayout.LayoutParams params = (ConstraintLayout.LayoutParams) footerViewHolder.footerView.getLayoutParams();
293
        if (TopicDetailBeanLab.get(context).beans().size() == 0) {
294
            footerViewHolder.footTextView.setText("还没有任何内容哦,快来抢沙发~");
295
            params.height = DensityUtil.dip2px(context, (screenHeight - headerHeight - statusHeight) / 4);
296
            params.bottomMargin = 0;
295
296
        if (beanLab.beans().size() == 0) {
297
            params.height = DensityUtil.dip2px(context, 230);
298
            footerViewHolder.footTextView.setText("还没有任何内容哦,快来抢沙发~");
297 299
        } else {
298 300
            footerViewHolder.footTextView.setText("已经全部加载完毕");
299 301
            params.height = DensityUtil.dip2px(context, 20);
300
            params.bottomMargin = DensityUtil.dip2px(context, 10);
301
        }
302
303
        if (showFooter == false) {
304
            params.height = 0;
305
            params.bottomMargin = DensityUtil.dip2px(context, 10);
306 302
        }
307
308 303
        footerViewHolder.footTextView.setLayoutParams(params);
309 304
    }
310 305
311 306
    private void showAuthorInfo(int position) {
312
        // TODO
307
        ChatRecommendBean bean = beanLab.beans().get(position - 1);
308
        Intent intent = new Intent(context, UserPageActivity.class);
309
        intent.putExtra("targetUserId", bean.addUserId + "");
310
        context.startActivity(intent);
313 311
    }
314 312
315 313
@ -327,6 +325,7 @@ public class TopicDetailAdapter extends RecyclerView.Adapter<IViewHolder> {
327 325
328 326
    public void setHeaderData(TopicHomePageBean.TopicVo bean) {
329 327
        topicVo = bean;
328
        notifyItemChanged(0);
330 329
    }
331 330
332 331
    public void setFooterData(Boolean showFooter) {

+ 3 - 13
app/src/main/java/com/electric/chargingpile/adapter/UserPageAdapter.java

@ -2,7 +2,6 @@ package com.electric.chargingpile.adapter;
2 2
3 3
import android.app.Activity;
4 4
import android.content.Context;
5
import android.graphics.Color;
6 5
import android.support.constraint.ConstraintLayout;
7 6
import android.support.v7.widget.RecyclerView;
8 7
import android.support.v7.widget.StaggeredGridLayoutManager;
@ -94,7 +93,7 @@ public class UserPageAdapter extends RecyclerView.Adapter<IViewHolder> {
94 93
95 94
    @Override
96 95
    public int getItemCount() {
97
        return beanLab.beans().size() + 1 ;
96
        return beanLab.beans().size() + 1;
98 97
    }
99 98
100 99
    private void bindContentViewHolder(IViewHolder viewHolder, final int position) {
@ -165,16 +164,7 @@ public class UserPageAdapter extends RecyclerView.Adapter<IViewHolder> {
165 164
        StaggeredGridLayoutManager.LayoutParams layoutParams = (StaggeredGridLayoutManager.LayoutParams) footerViewHolder.footerContainer.getLayoutParams();
166 165
        layoutParams.setFullSpan(true);
167 166
        footerViewHolder.footerContainer.setVisibility(showFooter ? View.VISIBLE : View.GONE);
168
169
        ConstraintLayout.LayoutParams params = (ConstraintLayout.LayoutParams)footerViewHolder.footerView.getLayoutParams();
170
        if (showFooter) {
171
            footerViewHolder.footTextView.setText("已经全部加载完毕");
172
            params.height = DensityUtil.dip2px(context, 20);
173
        } else {
174
            footerViewHolder.footTextView.setText("");
175
            params.height = 1;
176
        }
177
        footerViewHolder.footerView.setLayoutParams(params);
167
        footerViewHolder.footTextView.setText("已经全部加载完毕");
178 168
    }
179 169
180 170
    /**
@ -227,6 +217,6 @@ public class UserPageAdapter extends RecyclerView.Adapter<IViewHolder> {
227 217
228 218
    public void setFooterData(Boolean showFooter) {
229 219
        this.showFooter = showFooter;
230
        notifyItemRangeChanged(beanLab.beans().size(), 1);
220
        notifyItemRangeChanged(getItemCount() - 1, 1);
231 221
    }
232 222
}

+ 4 - 4
app/src/main/java/com/electric/chargingpile/application/MainApplication.java

@ -73,10 +73,10 @@ public class MainApplication extends MultiDexApplication {
73 73
    public static String firstPoint = "";
74 74
    public static Boolean firstSsyd;
75 75
    public static String password = "";
76
//    public static String url = "http://59.110.68.162";// 充电桩测试环境
77
    public static String url = "http://cdz.evcharge.cc";// 充电桩正式环境
78
//    public static String urlNew = "http://123.56.67.7:83/api/0200";// 一电测试环境
79
    public static String urlNew = "https://api.touchev.com:83/api/0200";// 一电正式环境
76
    public static String url = "http://59.110.68.162";// 充电桩测试环境
77
//    public static String url = "http://cdz.evcharge.cc";// 充电桩正式环境
78
    public static String urlNew = "http://123.56.67.7:83/api/0200";// 一电测试环境
79
//    public static String urlNew = "https://api.touchev.com:83/api/0200";// 一电正式环境
80 80
    public static String pic_url = "http:/s/cdz.evcharge.cc/zhannew/uploadfile/";
81 81
    //	public static String url = "https://cdz.d1ev.com";
82 82
    public static String build_flag = "0";

BIN
app/src/main/res/drawable-hdpi/loading_icon.png


BIN
app/src/main/res/drawable-hdpi/topic_offline_icon.png


BIN
app/src/main/res/drawable-mdpi/loading_icon.png


BIN
app/src/main/res/drawable-mdpi/no_net_icon.png


BIN
app/src/main/res/drawable-mdpi/topic_offline_icon.png


BIN
app/src/main/res/drawable-xhdpi/loading_icon.png


BIN
app/src/main/res/drawable-xhdpi/no_net_icon.png


BIN
app/src/main/res/drawable-xhdpi/topic_offline_icon.png


BIN
app/src/main/res/drawable-xxhdpi/loading_icon.png


BIN
app/src/main/res/drawable-xxhdpi/no_net_icon.png


BIN
app/src/main/res/drawable-xxhdpi/topic_offline_icon.png


BIN
app/src/main/res/drawable-xxxhdpi/loading_icon.png


BIN
app/src/main/res/drawable-xxxhdpi/no_net_icon.png


BIN
app/src/main/res/drawable-xxxhdpi/topic_offline_icon.png


+ 3 - 2
app/src/main/res/layout/activity_chat_footer.xml

@ -10,6 +10,7 @@
10 10
        android:id="@+id/footerView"
11 11
        android:layout_width="match_parent"
12 12
        android:layout_height="20dp"
13
        android:layout_marginBottom="10dp"
13 14
        app:layout_constraintBottom_toBottomOf="parent"
14 15
        app:layout_constraintEnd_toEndOf="parent"
15 16
        app:layout_constraintStart_toStartOf="parent"
@ -17,8 +18,8 @@
17 18
18 19
        <TextView
19 20
            android:id="@+id/footTextView"
20
            android:layout_width="match_parent"
21
            android:layout_height="match_parent"
21
            android:layout_width="wrap_content"
22
            android:layout_height="wrap_content"
22 23
            android:gravity="center"
23 24
            android:paddingLeft="30dp"
24 25
            android:paddingRight="30dp"

+ 51 - 0
app/src/main/res/layout/activity_no_net_img.xml

@ -0,0 +1,51 @@
1
<?xml version="1.0" encoding="utf-8"?>
2
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
3
    xmlns:app="http://schemas.android.com/apk/res-auto"
4
    xmlns:tools="http://schemas.android.com/tools"
5
    android:id="@+id/noNetView"
6
    android:layout_width="match_parent"
7
    android:layout_height="match_parent"
8
    android:background="#f4f4f4">
9
10
    <ImageView
11
        android:id="@+id/noNetIcon"
12
        android:layout_width="wrap_content"
13
        android:layout_height="wrap_content"
14
        android:layout_marginTop="90dp"
15
        android:src="@drawable/no_net_icon"
16
        app:layout_constraintEnd_toEndOf="parent"
17
        app:layout_constraintStart_toStartOf="parent"
18
        app:layout_constraintTop_toTopOf="parent" />
19
20
    <TextView
21
        android:id="@+id/noNetLabel"
22
        android:layout_width="wrap_content"
23
        android:layout_height="wrap_content"
24
        android:layout_marginStart="15dp"
25
        android:layout_marginTop="10dp"
26
        android:layout_marginEnd="15dp"
27
        android:text="小主网络跑掉了,请检查网络~"
28
        android:textColor="#555555"
29
        android:textSize="14sp"
30
        app:layout_constraintEnd_toEndOf="parent"
31
        app:layout_constraintStart_toStartOf="parent"
32
        app:layout_constraintTop_toBottomOf="@+id/noNetIcon" />
33
34
    <TextView
35
        android:id="@+id/noNetTry"
36
        android:layout_width="144dp"
37
        android:layout_height="40dp"
38
        android:layout_marginStart="15dp"
39
        android:layout_marginTop="20dp"
40
        android:layout_marginEnd="15dp"
41
        android:background="@drawable/bg_route_line_818181"
42
        android:gravity="center"
43
        android:text="点击重新尝试"
44
        android:textColor="#555555"
45
46
        android:textSize="14sp"
47
        app:layout_constraintEnd_toEndOf="parent"
48
        app:layout_constraintStart_toStartOf="parent"
49
        app:layout_constraintTop_toBottomOf="@+id/noNetLabel" />
50
51
</android.support.constraint.ConstraintLayout>

+ 19 - 0
app/src/main/res/layout/activity_topic_detail.xml

@ -96,5 +96,24 @@
96 96
        app:layout_constraintRight_toLeftOf="@+id/chatPublishIcon"
97 97
        app:layout_constraintTop_toTopOf="@+id/chatPublishIcon" />
98 98
99
    <include
100
        layout="@layout/activity_no_net_img"
101
        android:layout_width="0dp"
102
        android:layout_height="0dp"
103
        android:visibility="gone"
104
        app:layout_constraintBottom_toBottomOf="parent"
105
        app:layout_constraintLeft_toLeftOf="parent"
106
        app:layout_constraintRight_toRightOf="parent"
107
        app:layout_constraintTop_toBottomOf="@+id/navBar" />
108
109
    <include
110
        layout="@layout/activity_topic_offline"
111
        android:layout_width="0dp"
112
        android:layout_height="0dp"
113
        android:visibility="gone"
114
        app:layout_constraintBottom_toBottomOf="parent"
115
        app:layout_constraintLeft_toLeftOf="parent"
116
        app:layout_constraintRight_toRightOf="parent"
117
        app:layout_constraintTop_toBottomOf="@+id/navBar" />
99 118
100 119
</android.support.constraint.ConstraintLayout>

+ 35 - 0
app/src/main/res/layout/activity_topic_offline.xml

@ -0,0 +1,35 @@
1
<?xml version="1.0" encoding="utf-8"?>
2
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
3
    xmlns:app="http://schemas.android.com/apk/res-auto"
4
    xmlns:tools="http://schemas.android.com/tools"
5
    android:layout_width="match_parent"
6
    android:layout_height="match_parent"
7
    android:id="@+id/topicOfflineView"
8
    android:background="#f4f4f4">
9
10
    <ImageView
11
        android:id="@+id/imageView6"
12
        android:layout_width="wrap_content"
13
        android:layout_height="wrap_content"
14
        android:layout_marginStart="15dp"
15
        android:layout_marginTop="115dp"
16
        android:layout_marginEnd="15dp"
17
        app:layout_constraintEnd_toEndOf="parent"
18
        app:layout_constraintStart_toStartOf="parent"
19
        app:layout_constraintTop_toTopOf="parent"
20
        app:srcCompat="@drawable/topic_offline_icon" />
21
22
    <TextView
23
        android:id="@+id/textView26"
24
        android:layout_width="wrap_content"
25
        android:layout_height="wrap_content"
26
        android:layout_marginStart="15dp"
27
        android:layout_marginTop="10dp"
28
        android:layout_marginEnd="15dp"
29
        android:text="该话题已经下线,别处转转,有更多惊喜"
30
        android:textColor="#555555"
31
        android:textSize="14sp"
32
        app:layout_constraintEnd_toEndOf="parent"
33
        app:layout_constraintStart_toStartOf="parent"
34
        app:layout_constraintTop_toBottomOf="@+id/imageView6" />
35
</android.support.constraint.ConstraintLayout>

+ 1 - 0
app/src/main/res/values/color.xml

@ -169,6 +169,7 @@
169 169
    <color name="color_ff6600">#ff6600</color>
170 170
    <color name="color_888888">#888888</color>
171 171
    <color name="color_fb9349">#fb9349</color>
172
    <color name="color_1bb637">#1bb637</color>
172 173

173 174
    <color name="sv_black">#FF000000</color>
174 175
    <color name="sv_white">#FFFFFF</color>