daimajia / AndroidSwipeLayout

The Most Powerful Swipe Layout!
MIT License
12.37k stars 2.67k forks source link

自动收回问题 #535

Open Born-alone opened 5 years ago

Born-alone commented 5 years ago

左滑自动收回去了 试了两个设备 一台MX4 和 一台小米ipad Demo在两台设备上都没问题 我写了一个简单的布局 在MX4上会自动收回 小米ipad没问题 把Demo中的布局拷贝到我项目中 也是同样的问题: 在MX4上会自动回收 在小米ipad上正常 我新建一个项目 把我写的布局拷贝进去 也是一样的现象 请问这个是什么问题导致的 和设备有关系嘛?

以下是我的布局!

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="match_parent">

<com.daimajia.swipe.SwipeLayout
    android:layout_width="match_parent"
    android:layout_height="@dimen/dp_150"
    android:fitsSystemWindows="true"
    app:clickToClose="true"
    app:show_mode="lay_down">

    <LinearLayout
        android:layout_width="@dimen/dp_70"
        android:layout_height="match_parent"
        android:orientation="vertical"
        app:drag_edge="right">

        <TextView
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:background="#ED0000"
            android:gravity="center"
            android:text="删除"
            android:textColor="@color/white" />
    </LinearLayout>

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="horizontal">

        <CheckBox
            android:id="@+id/ck_chose"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_gravity="center_vertical"
            android:gravity="center" />

        <ImageView
            android:layout_width="@dimen/dp_100"
            android:layout_height="match_parent"
            android:src="@mipmap/ic_launcher" />
    </LinearLayout>
</com.daimajia.swipe.SwipeLayout>