layout_empty_conent.xml 1.4 KB

123456789101112131415161718192021222324252627282930313233343536
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3. xmlns:app="http://schemas.android.com/apk/res-auto"
  4. android:layout_width="match_parent"
  5. android:orientation="vertical"
  6. android:gravity="center"
  7. android:layout_height="match_parent">
  8. <ImageView
  9. android:id="@+id/im_empty_logo"
  10. android:layout_width="wrap_content"
  11. android:layout_height="wrap_content"
  12. android:layout_marginTop="8dp"
  13. android:background="@drawable/icon_empty_content"
  14. app:layout_constraintLeft_toLeftOf="parent"
  15. app:layout_constraintBottom_toTopOf="@+id/tv_empty_hint"
  16. app:layout_constraintRight_toRightOf="parent"
  17. app:layout_constraintTop_toTopOf="parent" />
  18. <TextView
  19. android:id="@+id/tv_empty_hint"
  20. android:layout_width="wrap_content"
  21. android:layout_height="wrap_content"
  22. android:layout_marginTop="14dp"
  23. android:gravity="center"
  24. android:lineSpacingExtra="4dp"
  25. android:textSize="@dimen/sp_16"
  26. android:textColor="@color/color_999999"
  27. android:text="暂无内容"
  28. app:layout_constraintBottom_toBottomOf="parent"
  29. app:layout_constraintLeft_toLeftOf="parent"
  30. app:layout_constraintRight_toRightOf="parent"
  31. app:layout_constraintTop_toBottomOf="@+id/im_empty_logo" />
  32. </LinearLayout>