
My goal is to get the layout like the sample about. However, I can't get the small line above the button bar.
What I get is like this.

my xml code is :
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:layout_marginLeft="18dp"
    android:layout_marginRight="18dp"
    android:layout_marginTop="24dp"
    >
  <LinearLayout
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:orientation="vertical"
      android:layout_alignParentTop="true"
      android:layout_above="@+id/buttonBarLayout"
      android:showDividers="middle"
      android:divider="?android:dividerHorizontal">
    <TextView
        style="?android:listSeparatorTextViewStyle"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:text="Section header"/>
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:orientation="horizontal"
        android:baselineAligned="false"
        android:showDividers="middle"
        android:divider="?android:dividerVertical"
        android:dividerPadding="8dp">
      <TextView
          android:layout_width="0dp"
          android:layout_height="wrap_content"
          android:layout_weight="1"
          android:textAppearance="?android:textAppearanceMedium"
          android:text="Sample item 1"
          android:layout_gravity="center_vertical"/>
      <ImageButton
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:src="@drawable/ic_action_discard"
          style="?android:borderlessButtonStyle"/>
    </LinearLayout>
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:orientation="horizontal"
        android:baselineAligned="false"
        android:showDividers="middle"
        android:divider="?android:dividerVertical"
        android:dividerPadding="8dp">
      <TextView
          android:layout_width="0dp"
          android:layout_height="wrap_content"
          android:layout_weight="1"
          android:textAppearance="?android:textAppearanceMedium"
          android:text="Sample item 2"
          android:layout_gravity="center_vertical"/>
      <ImageButton
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:src="@drawable/ic_action_discard"
          style="?android:borderlessButtonStyle"/>
    </LinearLayout>
  </LinearLayout>
  <LinearLayout
      android:id="@+id/buttonBarLayout"
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:layout_alignParentBottom="true"
      android:orientation="horizontal"
      style="?android:buttonBarStyle"
      >
    <Button
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:text="Discard"
        style="?android:buttonBarButtonStyle"/>
    <Button
        android:layout_width="0dp"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:text="Save"
        style="?android:buttonBarButtonStyle"/>
  </LinearLayout>
</RelativeLayout>
I believe that the line is the middle divider. However, if I use LinearLayout the divider will show right under Sample item 2, which is not what I want.
So how can I get what the sample shows?
