FrameLayout z-order not behaving as expected on Gingerbread?

倖福魔咒の 提交于 2019-12-11 19:41:57

问题


I have a layout as follows:

<FrameLayout
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  android:background="@android:color/black" >

<View
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  android:background="@android:color/white" >

<LinearLayout
  android:layout_width="match_parent"
  android:layout_height="match_parent" >
  <!-- children -->
</LinearLayout>

</FrameLayout>

The LinearLayout has no background and neither do any of its children. I can see the white View beneath the LinearLayout on Ice Cream Sandwich devices but not on Gingerbread devices. Anyone know why this might be and what I can do about it??

Note: I'm not setting the background of the LinearLayout to be white as what I really need to do is perform some animations on the View object.

来源:https://stackoverflow.com/questions/17590776/framelayout-z-order-not-behaving-as-expected-on-gingerbread

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!