feat: 优化代码

pull/164/head
kunfei 5 years ago
parent 91911b1505
commit 2352af7e48
  1. 53
      app/src/main/res/layout/popup_action_menu.xml

@ -1,36 +1,37 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:app="http://schemas.android.com/apk/res-auto"
android:background="@drawable/shape_card_view" android:background="@drawable/shape_card_view"
android:padding="5dp" android:padding="5dp"
android:orientation="horizontal"> android:orientation="vertical">
<androidx.recyclerview.widget.RecyclerView <LinearLayout
android:id="@+id/recycler_view"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center"
android:orientation="horizontal" android:orientation="horizontal"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" android:gravity="center_vertical">
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintTop_toTopOf="@+id/iv_menu_more"
app:layout_constraintRight_toLeftOf="@+id/iv_menu_more"
app:layout_constraintBottom_toBottomOf="@+id/iv_menu_more" />
<androidx.appcompat.widget.AppCompatImageView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/iv_menu_more" android:id="@+id/recycler_view"
android:layout_width="24dp" android:layout_width="wrap_content"
android:layout_height="24dp" android:layout_height="wrap_content"
android:background="?attr/selectableItemBackgroundBorderless" android:layout_gravity="center"
android:src="@drawable/ic_more_vert" android:orientation="horizontal"
android:tint="@color/tv_text_default" app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
android:visibility="gone"
android:contentDescription="@string/more_menu" <androidx.appcompat.widget.AppCompatImageView
android:layout_gravity="center_vertical" android:id="@+id/iv_menu_more"
app:layout_constraintTop_toTopOf="parent" android:layout_width="24dp"
app:layout_constraintRight_toRightOf="parent" /> android:layout_height="24dp"
android:background="?attr/selectableItemBackgroundBorderless"
android:src="@drawable/ic_more_vert"
android:tint="@color/tv_text_default"
android:visibility="gone"
android:contentDescription="@string/more_menu" />
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView <androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_view_more" android:id="@+id/recycler_view_more"
@ -38,10 +39,8 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center" android:layout_gravity="center"
android:visibility="gone" android:visibility="gone"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" android:orientation="vertical"
app:layout_constraintBottom_toBottomOf="parent" app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
app:layout_constraintTop_toBottomOf="@+id/iv_menu_more"
app:layout_constraintRight_toRightOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout> </LinearLayout>

Loading…
Cancel
Save