I am using ?android:attr/buttonBarStyle and ?android:attr/buttonBarButtonStyle for my button bar.
Here is my code:
<LinearLayout
android:id="@+id/label_edit_dialog_buttonbar"
style="?android:attr/buttonBarStyle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/label_edit_dialog_name_edittext"
android:layout_marginTop="8dp"
android:orientation="horizontal" >
<Button
android:id="@+id/label_edit_dialog_save_button"
style="?android:attr/buttonBarButtonStyle"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/save" />
<Button
android:id="@+id/label_edit_dialog_cancel_button"
style="?android:attr/buttonBarButtonStyle"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/cancel" />
</LinearLayout>
Here is result I get:
I expected to see a Divider between my button bar and other views but I didn't see it. I see top Divider when I am using AlertDialog - I checked AlertDialog xml layout and saw that AlertDialog also use buttonBarStyle. Anyone has any ideas? Thanks!
Here is dev settings: Eclipse + Nexus 4 Simulator + Min API is 14+