0
我在我的应用程序中有一个mapview。 我已经在相对布局中设置了294x322 imgage,并且在相关布局中,我添加了mapview和wrap_conten作为高度,并且wight认为地图视图还将包含helay的大小和weightlay的重量294x322。但是在运行时,我的mapview会去填充parent.one我发现的解决方案是给背景图像的相对布局的静态高度宽度,但问题是我有两个同名的图像,我已经在hdpi和mdpi文件夹中输入,所以它不适用于多屏幕资源。mapview去填充父代而不是换行内容
这里I M加入我的XML文件
<!-- MapView -->
<RelativeLayout
android:id="@+id/layout_mapRestaurant"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/rlBtnView"
android:layout_centerHorizontal="true"
android:paddingLeft="15dip"
android:paddingTop="15dip"
android:paddingRight="15dip"
android:paddingBottom="40dip"
android:layout_marginTop="-25dip"
android:background="@drawable/mapbg"
>
<com.google.android.maps.MapView
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/mapview_SearchResult"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:clickable="true"
android:background="@drawable/bg_border"
/>
</RelativeLayout>
以下是我如我设计
以下是其中I M在运行时显示实际布局图形布局。
谁能告诉我如何从这个问题出来?????