trong giao diện người dùng sau đây, tôi có điều này bên dưới có thể phủ lên toàn bộ màn hình. LinearLayout là trong suốt và cho phép các điều khiển bên dưới nó có thể nhấp hoặc có thể chạm được. Về cơ bản tôi có thể cuộn một danh sách bên dưới LinearLayout này cũng như các điều khiển nhấp chuột. Làm cách nào để tắt tính năng này?bố cục quá tải android cho phép chạm qua LinearLayout
Xem ví dụ được đính kèm.
Cảm ơn bạn
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/rlExtNavbar"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="fill_vertical"
android:layout_gravity="fill_vertical"
android:background="@color/transparent" xmlns:tools="http://schemas.android.com/tools" tools:ignore="Overdraw">
<RelativeLayout
android:id="@+id/expandedNavbarLayout"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="wrap_content" >
</RelativeLayout>
<LinearLayout
android:id="@+id/transparentLayout"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/expandedNavbarLayout"
android:focusableInTouchMode="false"
android:focusable="false"
android:background="@color/fulltransparent">
</LinearLayout>
</RelativeLayout>
Câu trả lời này phải được chấp nhận! –
vấn đề duy nhất với điều đó là trạng thái nhấn truyền đến tất cả các điều khiển con của chế độ xem có thể nhấp được đặt thành true. ví dụ. các nút nhấp vào hoạt ảnh khi bạn nhấp vào nền. –
không may, nó không hiệu quả với tôi. – NarendraJi