在android中,HorizontalScrollView和swipe在同一时间不起作用

在android中,HorizontalScrollView和swipe在同一时间不起作用,android,android-recyclerview,android-scrollview,Android,Android Recyclerview,Android Scrollview,我的片段中有4个不同的RecyclerViews。每个RecyclerView都包含一个项目列表。对于每个项目,我都实现了滑动功能。对于从右向左滑动,我显示共享和编辑选项 现在我无法访问“刷卡”选项。每次我滑动-水平滚动视图仅处于激活状态 谁能帮我解决这个问题 main.xml: <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/a

我的片段中有4个不同的RecyclerViews。每个RecyclerView都包含一个项目列表。对于每个项目,我都实现了滑动功能。对于从右向左滑动,我显示共享和编辑选项

现在我无法访问“刷卡”选项。每次我滑动-水平滚动视图仅处于激活状态

谁能帮我解决这个问题

main.xml:

  <?xml version="1.0" encoding="utf-8"?>
<RelativeLayout 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="match_parent"
    android:layout_height="match_parent"
    android:background="@color/back_blue"
    android:id="@+id/contact_card"
    app:layout_behavior="@string/appbar_scrolling_view_behavior">


    <FrameLayout
        android:id="@+id/frame_container1"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:layout_anchorGravity="center"
        app:layout_behavior="@string/appbar_scrolling_view_behavior" >

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            android:paddingBottom="30dp"
            android:layout_gravity="center"
            android:gravity="center"
            >

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="horizontal"
            android:layout_gravity="center"
            android:gravity="center"
            android:id="@+id/luminary_controll">

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:layout_weight="1"
                android:orientation="vertical">

                <TextView
                    android:id="@+id/sales_stage"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:gravity="center"
                    android:background="@color/tabs1"
                    android:padding="8dp"
                    android:text="SALES STAGE"
                    android:textAllCaps="true"
                    android:textColor="@color/White"
                    android:textSize="18sp"
                    android:layout_marginBottom="1dp"/>



            </LinearLayout>

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_weight="1"
                android:orientation="vertical">

                <TextView
                    android:id="@+id/support_required"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:gravity="center"
                    android:padding="8dp"
                    android:text="Support required"
                    android:textAllCaps="true"
                    android:textSize="18sp"
                    android:layout_marginBottom="1dp"/>
            </LinearLayout>

        </LinearLayout>


        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            android:background="@color/back_blue"
            android:id="@+id/sales_stagelist">


            <HorizontalScrollView
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:id="@+id/horizontalscroll">

            <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="horizontal"
                android:layout_marginTop="5dp">
        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            android:background="@drawable/border"
            android:padding="1dp">
            <RelativeLayout
                android:id="@+id/header"
                android:layout_width="match_parent"
                android:layout_height="48dp"
                android:layout_alignParentTop="true"
                android:background="@color/tabs1"
                android:gravity="center" >

                <TextView
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:layout_margin="5dp"
                    android:gravity="center"
                    android:textAllCaps="true"
                    android:text="@string/opportunity"
                    android:textAppearance="?android:attr/textAppearanceLarge"
                    android:textColor="@color/White"
                    android:textSize="16sp"/>
            </RelativeLayout>

            <view class="androidx.recyclerview.widget.RecyclerView"
                android:id="@+id/recyclerOpportunity"
                android:layout_width="match_parent"
                android:layout_height="wrap_content" />
        </LinearLayout>
            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="vertical"
                android:padding="1dp"
                android:background="@drawable/border"
                android:layout_marginLeft="10dp">
                <RelativeLayout
                    android:id="@+id/header1"
                    android:layout_width="match_parent"
                    android:layout_height="48dp"
                    android:layout_alignParentTop="true"
                    android:background="@color/tabs1"
                    android:gravity="center" >

                    <TextView
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:layout_margin="5dp"
                        android:text="@string/price_quote"
                        android:textSize="16sp"
                        android:textAllCaps="true"
                        android:textAppearance="?android:attr/textAppearanceLarge"
                        android:textColor="@color/White" />
                </RelativeLayout>

                <view class="androidx.recyclerview.widget.RecyclerView"
                    android:id="@+id/recyclerProposal"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content" />

        </LinearLayout>
                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:orientation="vertical"
                    android:padding="1dp"
                    android:background="@drawable/border"
                    android:layout_marginLeft="10dp">
                    <RelativeLayout
                        android:id="@+id/header2"
                        android:layout_width="match_parent"
                        android:layout_height="48dp"
                        android:layout_alignParentTop="true"
                        android:background="@color/tabs1"
                        android:gravity="center" >

                        <TextView
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_margin="5dp"
                            android:textSize="16sp"
                            android:textAllCaps="true"
                            android:text="@string/nagotiation_review"
                            android:textAppearance="?android:attr/textAppearanceLarge"
                            android:textColor="@color/White" />
                    </RelativeLayout>

                    <androidx.recyclerview.widget.RecyclerView
                        android:id="@+id/recyclerNegotiation"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content" />

                </LinearLayout>
                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:orientation="vertical"
                    android:padding="1dp"
                    android:background="@drawable/border"
                    android:layout_marginLeft="10dp">
                    <RelativeLayout
                        android:id="@+id/header3"
                        android:layout_width="match_parent"
                        android:layout_height="48dp"
                        android:layout_alignParentTop="true"
                        android:background="@color/tabs1"
                        android:gravity="center" >

                        <TextView
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_margin="5dp"
                            android:textSize="16sp"
                            android:textAllCaps="true"
                            android:text="@string/closed_won"
                            android:textAppearance="?android:attr/textAppearanceLarge"
                            android:textColor="@color/White" />
                    </RelativeLayout>

                    <androidx.recyclerview.widget.RecyclerView
                        android:id="@+id/recyclerClosedWon"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:layout_marginTop="10dp"/>

                </LinearLayout>
                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:orientation="vertical"
                    android:padding="1dp"
                    android:background="@drawable/border"
                    android:layout_marginLeft="10dp">
                    <RelativeLayout
                        android:id="@+id/header4"
                        android:layout_width="match_parent"
                        android:layout_height="48dp"
                        android:layout_alignParentTop="true"
                        android:background="@color/tabs1"
                        android:gravity="center" >

                        <TextView
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_margin="5dp"
                            android:textAllCaps="true"
                            android:text="@string/closed_lost"
                            android:textAppearance="?android:attr/textAppearanceLarge"
                            android:textColor="@color/White"
                            android:textSize="16sp"/>
                    </RelativeLayout>

                    <view class="androidx.recyclerview.widget.RecyclerView"
                        android:id="@+id/recyclerClosedLost"
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content" />

                </LinearLayout>
        </LinearLayout>
            </HorizontalScrollView>
            </LinearLayout>

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:orientation="vertical"
            android:visibility="gone"
            android:background="@color/back_blue"
            android:id="@+id/suppport_requirdlist">

            <!--            <androidx.coordinatorlayout.widget.CoordinatorLayout-->
            <!--                android:layout_width="match_parent"-->
            <!--                android:layout_height="wrap_content">-->

            <!--                <com.google.android.material.appbar.AppBarLayout-->
            <!--                    android:layout_width="match_parent"-->
            <!--                    android:layout_height="wrap_content"-->
            <!--                    android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"/>-->

            <!--                <androidx.appcompat.widget.Toolbar-->
            <!--                    android:layout_width="match_parent"-->
            <!--                    android:id="@+id/tabanim_toolbar"-->
            <!--                    android:layout_height="48dp"-->
            <!--                    android:background="@color/tabs"-->
            <!--                    android:minHeight="48dp"-->
            <!--                    app:layout_scrollFlags="scroll|enterAlways"-->
            <!--                    app:popupTheme="@style/ThemeOverlay.AppCompat.Light" />-->

            <!--                <com.google.android.material.tabs.TabLayout-->
            <!--                    android:id="@+id/sliding_tabs"-->
            <!--                    android:layout_width="match_parent"-->
            <!--                    android:layout_height="wrap_content"-->
            <!--                    app:tabMaxWidth="0dp"-->
            <!--                    app:tabGravity="fill"-->
            <!--                    app:tabIndicatorHeight="5dp"-->
            <!--                    app:tabTextColor="@color/White"-->
            <!--                    app:tabMode="fixed" />-->

            <!--                <androidx.viewpager.widget.ViewPager-->
            <!--                    android:id="@+id/viewpager"-->
            <!--                    android:layout_width="match_parent"-->
            <!--                    android:layout_height="0dp"-->
            <!--                    android:layout_weight="1"-->
            <!--                    android:background="@android:color/white" />-->
            <!--            </androidx.coordinatorlayout.widget.CoordinatorLayout>-->

            <HorizontalScrollView
                android:layout_width="match_parent"
                android:layout_height="match_parent">

                <LinearLayout
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:orientation="horizontal"
                    android:layout_marginTop="5dp">
                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:orientation="vertical"
                        android:background="@drawable/border"
                        android:padding="1dp">
                        <RelativeLayout
                            android:id="@+id/header111"
                            android:layout_width="match_parent"
                            android:layout_height="48dp"
                            android:layout_alignParentTop="true"
                            android:background="@color/tabs1"
                            android:gravity="center" >

                            <TextView
                                android:layout_width="match_parent"
                                android:layout_height="wrap_content"
                                android:layout_margin="5dp"
                                android:gravity="center"
                                android:textAllCaps="true"
                                android:text="@string/no_support"
                                android:textAppearance="?android:attr/textAppearanceLarge"
                                android:textColor="@color/White"
                                android:textSize="16sp"/>
                        </RelativeLayout>

                        <view class="androidx.recyclerview.widget.RecyclerView"
                            android:id="@+id/recyclerNoSupport"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content" />
                    </LinearLayout>
                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:orientation="vertical"
                        android:padding="1dp"
                        android:background="@drawable/border"
                        android:layout_marginLeft="10dp">
                        <RelativeLayout
                            android:id="@+id/header11"
                            android:layout_width="match_parent"
                            android:layout_height="48dp"
                            android:layout_alignParentTop="true"
                            android:background="@color/tabs1"
                            android:gravity="center" >

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_margin="5dp"
                                android:text="@string/product_valid"
                                android:textSize="16sp"
                                android:textAllCaps="true"
                                android:textAppearance="?android:attr/textAppearanceLarge"
                                android:textColor="@color/White" />
                        </RelativeLayout>

                        <view class="androidx.recyclerview.widget.RecyclerView"
                            android:id="@+id/recyclerPriceValid"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content" />

                    </LinearLayout>
                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:orientation="vertical"
                        android:padding="1dp"
                        android:background="@drawable/border"
                        android:layout_marginLeft="10dp">
                        <RelativeLayout
                            android:id="@+id/header21"
                            android:layout_width="match_parent"
                            android:layout_height="48dp"
                            android:layout_alignParentTop="true"
                            android:background="@color/tabs1"
                            android:gravity="center" >

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_margin="5dp"
                                android:textSize="16sp"
                                android:textAllCaps="true"
                                android:text="@string/price_sup"
                                android:textAppearance="?android:attr/textAppearanceLarge"
                                android:textColor="@color/White" />
                        </RelativeLayout>

                        <view class="androidx.recyclerview.widget.RecyclerView"
                            android:id="@+id/recyclerPriceSupport"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content" />

                    </LinearLayout>
                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:orientation="vertical"
                        android:padding="1dp"
                        android:background="@drawable/border"
                        android:layout_marginLeft="10dp">
                        <RelativeLayout
                            android:id="@+id/header31"
                            android:layout_width="match_parent"
                            android:layout_height="48dp"
                            android:layout_alignParentTop="true"
                            android:background="@color/tabs1"
                            android:gravity="center" >

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_margin="5dp"
                                android:textSize="16sp"
                                android:textAllCaps="true"
                                android:text="@string/demo_req"
                                android:textAppearance="?android:attr/textAppearanceLarge"
                                android:textColor="@color/White" />
                        </RelativeLayout>

                        <view class="androidx.recyclerview.widget.RecyclerView"
                            android:id="@+id/recyclerDemoReq"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content" />

                    </LinearLayout>
                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:orientation="vertical"
                        android:padding="1dp"
                        android:background="@drawable/border"
                        android:layout_marginLeft="10dp">
                        <RelativeLayout
                            android:id="@+id/header41"
                            android:layout_width="match_parent"
                            android:layout_height="48dp"
                            android:layout_alignParentTop="true"
                            android:background="@color/tabs1"
                            android:gravity="center" >

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_margin="5dp"
                                android:textAllCaps="true"
                                android:text="@string/travel_sup"
                                android:textAppearance="?android:attr/textAppearanceLarge"
                                android:textColor="@color/White"
                                android:textSize="16sp"/>
                        </RelativeLayout>

                        <view class="androidx.recyclerview.widget.RecyclerView"
                            android:id="@+id/recyclerTravelSupport"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content" />

                    </LinearLayout>

                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:orientation="vertical"
                        android:padding="1dp"
                        android:background="@drawable/border"
                        android:layout_marginLeft="10dp">
                        <RelativeLayout
                            android:id="@+id/header5"
                            android:layout_width="match_parent"
                            android:layout_height="48dp"
                            android:layout_alignParentTop="true"
                            android:background="@color/tabs1"
                            android:gravity="center" >

                            <TextView
                                android:layout_width="wrap_content"
                                android:layout_height="wrap_content"
                                android:layout_margin="5dp"
                                android:textAllCaps="true"
                                android:text="@string/fund_req"
                                android:textAppearance="?android:attr/textAppearanceLarge"
                                android:textColor="@color/White"
                                android:textSize="16sp"/>
                        </RelativeLayout>

                        <view class="androidx.recyclerview.widget.RecyclerView"
                            android:id="@+id/recyclerFundingReq"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content" />

                        <TextView
                            android:id="@+id/textEmptyList"
                            android:layout_width="match_parent"
                            android:layout_height="200dp"
                            android:layout_gravity="center"
                            android:gravity="center"
                            android:text="List is Empty!"
                            android:visibility="gone"
                            tools:visibility="visible" />

                    </LinearLayout>
                </LinearLayout>
            </HorizontalScrollView>
        </LinearLayout>
        </LinearLayout>
    </FrameLayout>
    <com.google.android.material.floatingactionbutton.FloatingActionButton
        android:id="@+id/fab"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:clickable="true"
        android:src="@drawable/ic_add_circle_black_24dp"
        android:layout_marginBottom="70dp"
        android:layout_marginRight="20dp"
        app:elevation="6dp"
        app:backgroundTint="@color/colorPrimary"
        android:layout_alignParentBottom="true"
        android:layout_alignParentRight="true"/>

</RelativeLayout>

你说的“激活”是什么意思?你能更具体地说明问题吗?你说的“激活”是什么意思?你能更具体地说明问题吗?