Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ################################# main.xml #################################
- <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:tools="http://schemas.android.com/tools"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- tools:context=".MainActivity" >
- <ListView
- android:id="@+id/mainlist"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_alignParentLeft="true"
- android:layout_alignParentTop="true" >
- </ListView>
- </RelativeLayout>
- ################################# mainlistdata.xml #################################
- <?xml version="1.0" encoding="UTF-8"?>
- <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="fill_parent"
- android:layout_height="fill_parent" >
- <LinearLayout
- xmlns:android="http://schemas.android.com/apk/res/android"
- android:id="@+id/dataLayout"
- android:layout_width="fill_parent"
- android:layout_height="wrap_content"
- android:layout_alignParentLeft="true"
- android:layout_alignParentTop="true" >
- <TextView
- android:id="@+id/dataTitle"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:layout_weight="2"
- android:gravity="center|left"
- android:paddingBottom="4dp"
- android:paddingLeft="4dp"
- android:paddingRight="4dp"
- android:paddingTop="4dp" />
- <TextView
- android:id="@+id/dataValue"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:layout_weight="1.1"
- android:gravity="right|center"
- android:paddingBottom="4dp"
- android:paddingLeft="4dp"
- android:paddingRight="4dp"
- android:paddingTop="4dp" />
- <TextView
- android:id="@+id/dataValueString"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:layout_weight="0.9"
- android:gravity="right|center"
- android:paddingBottom="4dp"
- android:paddingLeft="4dp"
- android:paddingRight="4dp"
- android:paddingTop="4dp" />
- </LinearLayout>
- <View
- android:id="@+id/dSep"
- android:layout_width="fill_parent"
- android:layout_height="2dp"
- android:layout_alignParentLeft="true"
- android:layout_below="@+id/dataLayout"
- android:background="@android:color/darker_gray" />
- </RelativeLayout>
- ################################# tabslayout.xml#################################
- <?xml version="1.0" encoding="UTF-8"?>
- <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="fill_parent"
- android:layout_height="fill_parent" >
- <LinearLayout
- xmlns:android="http://schemas.android.com/apk/res/android"
- android:id="@+id/dataLayout"
- android:layout_width="fill_parent"
- android:layout_height="wrap_content" >
- <TextView
- android:id="@+id/dataTitle"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:layout_weight="2"
- android:gravity="center|left"
- android:paddingBottom="4dp"
- android:paddingLeft="4dp"
- android:paddingRight="4dp"
- android:paddingTop="4dp" />
- <TextView
- android:id="@+id/dataValue"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:layout_weight="1.1"
- android:gravity="right|center"
- android:paddingBottom="4dp"
- android:paddingLeft="4dp"
- android:paddingRight="4dp"
- android:paddingTop="4dp" />
- <TextView
- android:id="@+id/dataValueString"
- android:layout_width="0dp"
- android:layout_height="wrap_content"
- android:layout_weight="0.9"
- android:gravity="right|center"
- android:paddingBottom="4dp"
- android:paddingLeft="4dp"
- android:paddingRight="4dp"
- android:paddingTop="4dp" />
- </LinearLayout>
- <TextView
- android:id="@+id/dataTabsTitle"
- android:layout_width="fill_parent"
- android:layout_height="wrap_content"
- android:layout_alignParentLeft="true"
- android:layout_alignParentTop="false"
- android:layout_below="@id/dataLayout"
- android:gravity="center_vertical|center_horizontal|center"
- android:padding="4dp"
- android:text="HERE GOES TWO TABS"
- android:textAppearance="?android:attr/textAppearanceMedium"
- android:textSize="16sp"
- android:textStyle="bold" />
- <TabHost
- android:id="@android:id/tabhost"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:layout_alignParentLeft="true"
- android:layout_below="@+id/dataTabsTitle" >
- <LinearLayout
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:orientation="vertical" >
- <TabWidget
- android:id="@android:id/tabs"
- android:layout_width="match_parent"
- android:layout_height="wrap_content" >
- </TabWidget>
- <FrameLayout
- android:id="@android:id/tabcontent"
- android:layout_width="match_parent"
- android:layout_height="match_parent" >
- <LinearLayout
- android:id="@+id/tabOne"
- android:layout_width="match_parent"
- android:layout_height="match_parent" >
- <ListView
- android:id="@+id/listOne"
- android:layout_width="0dip"
- android:layout_height="match_parent"
- android:layout_weight="1" >
- </ListView>
- </LinearLayout>
- <LinearLayout
- android:id="@+id/tabTwo"
- android:layout_width="match_parent"
- android:layout_height="match_parent" >
- <ListView
- android:id="@+id/listTwo"
- android:layout_width="0dip"
- android:layout_height="match_parent"
- android:layout_weight="1" >
- </ListView>
- </LinearLayout>
- </FrameLayout>
- </LinearLayout>
- </TabHost>
- </RelativeLayout>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement