Tom*_*omb 9 user-interface android viewflipper android-mapview
我有一个布局大小问题...
我有一个布局,包括一个ViewFlipper,一个LinearLayout(包含一个MapView)和一个垂直行中的第二个LinearLayout.
<LinearLayout
android:width="match_parent"
android:height="match_parent" >
<ViewFlipper
android:width="match_parent"
android:height="wrap_content" >
// Top elements
</ViewFlipper>
<LinearLayout
android:width="match_parent"
android:height="match_parent" >
// MapView
</LinearLayout>
<LinearLayout
android:width="match_parent"
android:height="wrap_content" >
// Bottom elements
</LinearLayout>
</LinearLayout>
Run Code Online (Sandbox Code Playgroud)
我看到的问题是当我更改ViewFlipper以显示带有showNext()或showPrevious()的较短视图时,中间的LinearLayout不会展开以填充空间.此外,当我更改为较短的视图时,我看到上一个ViewFlipper视图遗留的黑色/空白空间.
是否有一种灵活的方式来动态调整这些元素的大小,以便MapView布局将扩展以填充ViewFlipper和底部LinearLayout未占用的所有空间?
| 归档时间: |
|
| 查看次数: |
1328 次 |
| 最近记录: |