我有两个片段,片段2下的片段1和片段1小于片段2。
首先我使片段 2 可见,而不是当我使片段 1 可见时,我想禁用片段 2 中的所有按钮和列表,因此用户只能控制片段 1。我该怎么做?
这是我的xml:
<FrameLayout
android:layout_width="0dip"
android:layout_height="match_parent"
android:layout_weight="1.0" >
<FrameLayout
android:id="@+id/fragment2"
android:layout_width="match_parent"
android:layout_height="match_parent" />
<FrameLayout
android:id="@+id/fragment1"
android:layout_width="200dip"
android:layout_height="200dip"
android:visibility="gone" />
</FrameLayout>