I'm currently having a problem with a seemingly simple layout. I have a static header (with logo and button), a WebView and then a static footer (with centre button). There seems to be a space between these 3 I cannot remove (I made the root background red so it's obvious where the space is).
Any idea how I can make the WebView fill this entire space so this red background is gone?
Also Eclipse is giving me the following warning for my RelativeLayout blocks:
This RelativeLayout layout or its LinearLayout parent is possibly useless; transfer the background attribute to the other view
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/commonlayout"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="#FF0000"
android:orientation="vertical"
android:padding="0dp"
android:weightSum="10" >
<LinearLayout
android:id="@+id/llheader"
android:layout_width="fill_parent"
android:layout_height="0dp"
android:layout_weight="1" >
<RelativeLayout
android:id="@+id/relativeLayout1"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_gravity="top"
android:background="@drawable/bgx" >
<Button
android:id="@+id/Button_logout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
android:layout_marginRight="2dp"
android:background="@drawable/ic_launcher" />
<Button
android:id="@+id/Button_playlist"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true"
android:layout_marginLeft="2dp"
android:background="@drawable/logo" />
</RelativeLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/lldata"
android:layout_width="fill_parent"
android:layout_height="0dp"
android:layout_weight="8"
android:background="#00FF00" >
<WebView
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/webview"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
</LinearLayout>
<LinearLayout
android:id="@+id/llfooter"
android:layout_width="fill_parent"
android:layout_height="0dp"
android:layout_margin="0dp"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal"
android:visibility="visible" >
<RelativeLayout
android:id="@+id/relativeLayout2"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:background="@drawable/bgx" >
<Button
android:id="@+id/issue"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:background="@drawable/ic_launcher"
android:textColor="#FFFFFF" />
</RelativeLayout>
</LinearLayout>
</LinearLayout>